Exemplo n.º 1
0
 public MainForm()
 {
     InitializeComponent();
     this.BackColor = mainPanel.BackColor = Color.White;
     View           = new TextView("Hello world", mainPanel);
     this.KeyPress += (View as TextView).KeyPressEventHeandler;
     this.KeyDown  += (View as TextView).KeyDownEventHandler;
     this.KeyPress += MainForm_KeyPress;
     BorderDecor    = new BorderDecorator(View);
     ScrollDecor    = new ScrollDecorator(BorderDecor);
     (View as TextArea).TextChanged += MainForm_TextChanged;
     ScrollDecor.SetScrollHandler(ScrollHandler);
 }
Exemplo n.º 2
0
 public MainForm()
 {
     InitializeComponent();
     this.BackColor = mainPanel.BackColor = Color.White;
     View = new TextView("Hello world", mainPanel);
     this.KeyPress += (View as TextView).KeyPressEventHeandler;
     this.KeyDown += (View as TextView).KeyDownEventHandler;
     this.KeyPress += MainForm_KeyPress;
     BorderDecor = new BorderDecorator(View);
     ScrollDecor = new ScrollDecorator(BorderDecor);
     (View as TextArea).TextChanged += MainForm_TextChanged;
     ScrollDecor.SetScrollHandler(ScrollHandler);
 }