public TableEditor() : base(new TableLayoutList()) { toolInsert.Remove(); //toolInsertLine = new ToolMenuItem(OnToolInsertLineClick) { Name = "Insert Line", Glyph = GlyphType.ChevronCircleRight }; //toolAdd.DropDownItems.Add(toolInsertLine); toolReference = new ToolDropDown() { Name = "References", Visible = false, DisplayStyle = ToolItemDisplayStyle.Text, DropDown = new Menubar { Name = "References" } }; toolMerge = new ToolMenuItem(OnToolMergeClick) { Name = "Merge", Glyph = GlyphType.PaperPlane }; toolReport = new ToolMenuItem(ToolReportClick) { Name = "Report", Glyph = GlyphType.FileExcelO }; toolParam = new ToolDropDown(toolMerge, toolReport) { Name = "Parameters", Glyph = GlyphType.GearAlias }; loader = new TableLoader(); toolProgress = new ToolTableLoader { Loader = loader }; Bar.Items.Add(toolReference); Bar.Items.Add(toolParam); Bar.Items.Add(toolProgress); List.CellValueWrite += FieldsCellValueChanged; Name = "TableEditor"; question = new QuestionMessage { Text = "Checkout" }; question.Buttons.Add(Command.No); question.Buttons.Add(Command.Yes); }
public TableView() : base() { list = new TableLayoutList() { EditState = EditListState.ReadOnly, GenerateToString = false, Name = "list" }; list.PositionChanged += OnNotifyPositionChangedEV; list.SelectionChanged += OnSelectionChanged; list.CellDoubleClick += TableViewCellDoubleClick; lable = new ToolLabel { Name = "lable", Text = "_" }; toolLoad = new ToolItem(ToolLoadClick) { DisplayStyle = ToolItemDisplayStyle.Text, Name = "Load", Text = "Load" }; toolProgress = new ToolTableLoader { Loader = loader }; bar = new Toolsbar( lable, toolLoad, toolProgress) { Name = "Bar" }; Name = "TableView"; PackStart(bar, false, false); PackStart(list, true, true); }
public DataLogView() { toolModeDefault = new ToolMenuItem { Name = "Default", Tag = DataLogMode.Default }; toolModeDocument = new ToolMenuItem { Name = "Document", Tag = DataLogMode.Document }; toolModeTable = new ToolMenuItem { Name = "Table", Tag = DataLogMode.Table }; toolMode = new ToolDropDown( toolModeDefault, toolModeDocument, toolModeTable) { DisplayStyle = ToolItemDisplayStyle.Text, Name = "LogMode", Text = "Mode: Default" }; toolMode.ItemClick += ToolModeClick; toolRollback = new ToolItem(ToolRollbackClick) { Name = "Rollback", DisplayStyle = ToolItemDisplayStyle.Text }; toolAccept = new ToolItem(ToolAcceptClick) { Name = "Accept", DisplayStyle = ToolItemDisplayStyle.Text }; toolCheck = new ToolItem() { Name = "Check", DisplayStyle = ToolItemDisplayStyle.Text }; toolDetails = new ToolItem(ToolDetailsClick) { Name = "Details", DisplayStyle = ToolItemDisplayStyle.Text }; dateField = new ToolFieldEditor() { Editor = new CellEditorDate { TwoDate = true, DataType = typeof(DateInterval) }, Name = "Date", ContentMinWidth = 200 }; dateField.Field.BindData(this, nameof(Date)); dataField = new ToolFieldEditor() { Editor = new CellEditorDataTree { DataType = typeof(DBTable) }, Name = "Table", ContentMinWidth = 200 }; dataField.Field.BindData(this, nameof(Table)); toolProgress = new ToolTableLoader() { }; bar = new Toolsbar( toolRollback, toolMode, toolDetails, new ToolSeparator { FillWidth = true }, dateField, dataField, toolProgress) { Name = "BarLog" }; list = new LayoutList() { AllowEditColumn = false, EditMode = EditModes.None, EditState = EditListState.Edit, GenerateToString = false, Mode = LayoutListMode.List, Name = "list", ListSource = listSource = new SelectableList <DBLogItem>() }; list.GenerateColumns = true; list.CellMouseClick += ListCellMouseClick; list.CellDoubleClick += ListCellDoubleClick; list.SelectionChanged += ListSelectionChanged; //if (logs.Table != null) // logs.ApplySort(new DBRowComparer(logs.Table.DateKey, ListSortDirection.Ascending)); detailList = new TableLayoutList() { GenerateToString = false, GenerateColumns = false, ReadOnly = true, EditMode = EditModes.ByClick }; detailList.ListInfo.Columns.Add("Column", 120).Editable = false; detailList.ListInfo.Columns.Add("OldFormat", 100).FillWidth = true; detailList.ListInfo.Columns.Add("NewFormat", 100).FillWidth = true; detailList.ListInfo.StyleRowName = "ChangeRow"; detailList.ListInfo.HeaderVisible = false; detailRow = new TableLayoutList(); map = new GroupBox( new GroupBoxItem { Name = "Details", Widget = detailList, Column = 0, FillWidth = true, FillHeight = true }, //new GroupBoxItem { Name = "Difference", Widget = detailText, Col = 1, FillWidth = true, FillHeight = true }, new GroupBoxItem { Name = "Record", Widget = detailRow, Column = 2, FillWidth = true, FillHeight = true }); //list.ListInfo.Columns.Add(list.BuildColumn(null, "Text")); split = new VPaned(); split.Panel1.Content = list; //split.Panel2.Content = map; PackStart(bar, false, false); PackStart(split, true, true); Name = "DataLog"; }