public Window1() : base() { InitializeComponent(); //sub-class our textBox DisplayBox = new MyTextBox(); Grid.SetRow(DisplayBox, 0); Grid.SetColumn(DisplayBox, 0); Grid.SetColumnSpan(DisplayBox, 9); DisplayBox.Height = 30; MyGrid.Children.Add(DisplayBox); //sub-class our paper trail textBox PaperBox = new MyTextBox(); Grid.SetRow(PaperBox, 1); Grid.SetColumn(PaperBox, 0); Grid.SetColumnSpan(PaperBox, 3); Grid.SetRowSpan(PaperBox, 5); PaperBox.IsReadOnly = true; PaperBox.VerticalScrollBarVisibility = ScrollBarVisibility.Visible; PaperBox.Margin = new Thickness(3.0, 1.0, 1.0, 1.0); PaperBox.HorizontalScrollBarVisibility = ScrollBarVisibility.Auto; Paper = new PaperTrail(); MyGrid.Children.Add(PaperBox); ProcessKey('0'); EraseDisplay = true; }
public Window1() : base() { InitializeComponent(); //sub-class our textBox DisplayBox = new MyTextBox(); Grid.SetRow(DisplayBox, 0); Grid.SetColumn(DisplayBox, 0); Grid.SetColumnSpan(DisplayBox, 9); DisplayBox.Height = 30; MyGrid.Children.Add(DisplayBox); //sub-class our paper trail textBox PaperBox = new MyTextBox(); Grid.SetRow(PaperBox, 1); Grid.SetColumn(PaperBox, 0); Grid.SetColumnSpan(PaperBox, 3); Grid.SetRowSpan(PaperBox, 5); PaperBox.IsReadOnly = true; PaperBox.VerticalScrollBarVisibility = ScrollBarVisibility.Visible; PaperBox.Margin = new Thickness(3.0,1.0,1.0,1.0); PaperBox.HorizontalScrollBarVisibility = ScrollBarVisibility.Auto; Paper = new PaperTrail(); MyGrid.Children.Add(PaperBox); ProcessKey('0'); EraseDisplay = true; }