1 /* i_oview.h 2 * 3 * Copyright (c) 1994-1996, Marko Macek 4 * 5 * You may distribute under the terms of either the GNU General Public 6 * License or the Artistic License, as specified in the README file. 7 * 8 */ 9 10 #ifndef I_OVIEW_H 11 #define I_OVIEW_H 12 13 #include "console.h" 14 #include "c_commands.h" 15 16 class GxView; 17 class EEventMap; 18 class ExState; 19 20 class ExView { 21 protected: 22 public: 23 GxView *Win; 24 ExView *Next; 25 26 ExView(); 27 virtual ~ExView(); 28 29 virtual EEventMap *GetEventMap(); 30 virtual int ExecCommand(ExCommands Command, ExState &State); 31 32 virtual void Activate(int gotfocus); 33 virtual int GetContext(); 34 virtual ExView *GetViewContext(); 35 virtual ExView *GetStatusContext(); 36 virtual int BeginMacro(); 37 virtual void EndExec(int NewResult); 38 virtual void HandleEvent(TEvent &Event); 39 virtual int IsModelView(); 40 virtual void RepaintView(); 41 virtual void RepaintStatus(); 42 virtual void Resize(int width, int height); 43 virtual void UpdateView(); 44 virtual void UpdateStatus(); 45 46 int IsActive(); 47 void Repaint(); 48 void Update(); 49 50 int ConPutBox(int X, int Y, int W, int H, PCell Cell); 51 int ConScroll(int Way, int X, int Y, int W, int H, TAttr Fill, int Count); 52 int ConQuerySize(int *X, int *Y); 53 int ConSetCursorPos(int X, int Y); 54 int ConShowCursor(); 55 int ConHideCursor(); 56 int ConSetCursorSize(int Start, int End); 57 }; 58 59 /* Implement most common used methods for ExView *Next */ 60 class ExViewNext: public ExView { 61 public: 62 virtual ExView *GetViewContext(); 63 virtual void RepaintView(); 64 virtual void UpdateStatus(); 65 virtual void UpdateView(); 66 }; 67 68 #endif // I_OVIEW_H 69