private void SetupConsoleTab() { Log.Verbose("Debugger", "Setup debugger console tab..."); float totalHPadding = tabContainerPadding.left + tabContainerPadding.right; ct_txtCommand = new AutocompleteTextField("CommandField", String.Empty); tabPageConsole.AttachControl(disposingManager.R(ct_txtCommand)); ct_txtCommand.Anchor = Anchor.Bottom | Anchor.Left | Anchor.Right; ct_txtCommand.Size = new Vector2(tabContainer.Width - (totalHPadding + 24), ct_txtCommand.Height); ct_txtCommand.Pivot = PivotPoint.BottomLeft; ct_txtCommand.RelativePosition = new Vector3(tabContainerPadding.left, tabContainer.Height - (ct_txtCommand.Height + tabContainerPadding.bottom)); float consoleLogHeight = tabContainer.Height - (ct_txtCommand.Height + tabContainerPadding.bottom + 5); ct_consoleLogScrollbar = new ScrollbarControl("ConsoleLogScrollbar"); tabPageConsole.AttachControl(disposingManager.R(ct_consoleLogScrollbar).Control); ct_consoleLogScrollbar.Anchor = Anchor.Top | Anchor.Bottom | Anchor.Right; ct_consoleLogScrollbar.Size = new Vector2(ct_consoleLogScrollbar.Width, consoleLogHeight); ct_consoleLogScrollbar.RelativePosition = new Vector3(tabContainer.Width - (ct_consoleLogScrollbar.Width + tabContainerPadding.left), tabContainerPadding.top); ct_consoleLog = new ScrollablePanel("ConsoleLog"); tabPageConsole.AttachControl(disposingManager.R(ct_consoleLog)); ct_consoleLog.Anchor = Anchor.All; ct_consoleLog.Size = new Vector2(tabContainer.Width - (totalHPadding + ct_consoleLogScrollbar.Width), consoleLogHeight); ct_consoleLog.Pivot = PivotPoint.TopLeft; ct_consoleLog.RelativePosition = new Vector3(tabContainerPadding.left, tabContainerPadding.top); ct_consoleLog.Color = new Color32(30, 30, 30, 150); ct_consoleLog.VerticalScrollbar = ct_consoleLogScrollbar.Control; Button test = new Button("test", "testbutton", Vector3.one, new Vector2(100, 800)); ct_consoleLog.AttachControl(test); }
private void SetupLogTab() { Log.Verbose("Debugger", "Setup debugger log tab..."); float totalHPadding = tabContainerPadding.left + tabContainerPadding.right; float logPanelHeight = tabContainer.Height - tabContainerPadding.bottom; lt_panelScrollbar = new ScrollbarControl("LogPanelScrollbar"); tabPageLog.AttachControl(disposingManager.R(lt_panelScrollbar).Control); lt_panelScrollbar.Anchor = Anchor.Top | Anchor.Bottom | Anchor.Right; lt_panelScrollbar.Size = new Vector2(lt_panelScrollbar.Width, logPanelHeight); lt_panelScrollbar.RelativePosition = new Vector3(tabContainer.Width - (lt_panelScrollbar.Width + tabContainerPadding.left), tabContainerPadding.top); lt_panel = new ScrollablePanel("LogPanel"); tabPageLog.AttachControl(disposingManager.R(lt_panel)); lt_panel.Anchor = Anchor.All; lt_panel.Size = new Vector2(tabContainer.Width - (totalHPadding + ct_consoleLogScrollbar.Width), logPanelHeight); lt_panel.Pivot = PivotPoint.TopLeft; lt_panel.RelativePosition = new Vector3(tabContainerPadding.left, tabContainerPadding.top); lt_panel.Color = new Color32(30, 30, 30, 150); lt_panel.VerticalScrollbar = ct_consoleLogScrollbar.Control; }