public PanelColumn(PanelWidget panel) { this.panel = panel; }
public PanelCell(int row, int col, PanelWidget panel) { this.row = row; this.col = col; this.panel = panel; }
public PanelRow(PanelWidget panel) { this.panel = panel; }
public SimpleListViewWidget(string name, List <string> columns, float width = 0, float height = 0, float left = 0, float top = 0, bool hasBorder = true) { this.columns = columns; OverlayManager overlayMgr = OverlayManager.Singleton; if (hasBorder) { element = OverlayManager.Singleton.CreateOverlayElementFromTemplate("EditorPanel", "BorderPanel", name); } else { element = OverlayManager.Singleton.CreateOverlayElementFromTemplate("EditorPanelNoBorder", "BorderPanel", name); } element.MetricsMode = GuiMetricsMode.GMM_RELATIVE; if (width <= 0) { element.Width = 1.0f; } else { element.Width = width; } if (height <= 0) { element.Height = 1.0f; } else { element.Height = height; } element.Top = top; element.Left = left; items = new List <ListViewItem>(); rows = new List <ListViewPanelRow>(); cols = new List <ListViewPanelColumn>(); widgets = new List <Widget>(); ListViewPanelColumn col = new ListViewPanelColumn(this); col.Type = ValueType.Percent; col.Width = 100; cols.Add(col); ListViewPanelRow row = new ListViewPanelRow(this); row.Type = ValueType.Abosulte; row.Height = LISTVIEW_ROW_HEIGHT; rows.Add(row); row = new ListViewPanelRow(this); row.Type = ValueType.Percent; row.Height = 100; rows.Add(row); header = new PanelWidget("listview_" + name + "_header_" + Guid.NewGuid().ToString(), 0, 0, 0, 0, 1, columns.Count, false); content = new SimplePanelScrollableWidget("listview_" + name + "_header_" + Guid.NewGuid().ToString(), 0, 0, 0, 0, LISTVIEW_ROW_HEIGHT, columns.Count, false); content.Material = "SdkTrays/MiniTray"; AddWidget(1, 1, header, AlignMode.Center, AlignMode.Center, DockMode.Fill); AddWidget(2, 1, content, AlignMode.Center, AlignMode.Center, DockMode.Fill); content.ChangeEachRowHeight(LISTVIEW_ROW_HEIGHT); AddColumn(); }