Phase 3: regenerate .fdj and generator fixtures from the fixed C++ saver/generator (ToggleButton, new props, case 04 enum loops)
This commit is contained in:
1 parent
bef3233260
commit
f59303ed28
12 files changed
+741
-158
No files matched your search
+5
-1
@@ -7,7 +7,11 @@
|
||||
"width": 800,
|
||||
"height": 600,
|
||||
"background": "",
|
||||
"menubar": ""
|
||||
"menubar": "",
|
||||
"border_style": 0,
|
||||
"icon": "",
|
||||
"position": 0,
|
||||
"window_state": 0
|
||||
},
|
||||
"widgets": [
|
||||
{
|
||||
|
||||
+5
-1
@@ -7,7 +7,11 @@
|
||||
"width": 800,
|
||||
"height": 600,
|
||||
"background": "",
|
||||
"menubar": ""
|
||||
"menubar": "",
|
||||
"border_style": 0,
|
||||
"icon": "",
|
||||
"position": 0,
|
||||
"window_state": 0
|
||||
},
|
||||
"widgets": []
|
||||
}
|
||||
+5
-1
@@ -7,7 +7,11 @@
|
||||
"width": 1024,
|
||||
"height": 768,
|
||||
"background": "#102030",
|
||||
"menubar": "File: New | Open | - | Quit\nHelp: About"
|
||||
"menubar": "File: New | Open | - | Quit\nHelp: About",
|
||||
"border_style": 0,
|
||||
"icon": "",
|
||||
"position": 0,
|
||||
"window_state": 0
|
||||
},
|
||||
"widgets": [
|
||||
{
|
||||
|
||||
@@ -30,7 +30,7 @@ Close the window (or its close button) to quit.
|
||||
|
||||
## Notes
|
||||
|
||||
- Widgets: 37 placed. Each is constructed
|
||||
- Widgets: 38 placed. Each is constructed
|
||||
as its XFrame class (e.g. `GtkButton`) with the geometry and
|
||||
properties from the design; colours and state use the widgets'
|
||||
getter/setter API where one exists, otherwise a per-widget
|
||||
|
||||
+106
-37
@@ -4,7 +4,7 @@
|
||||
// or the generated Makefile (make). Both need the XFrame widget
|
||||
// sources; see LIGHTGUI_WIDGETS_DIR in CMakeLists.txt / Makefile.
|
||||
//
|
||||
// The window is "Main Window" (800x600) with 37 widget(s).
|
||||
// The window is "Main Window" (800x600) with 38 widget(s).
|
||||
|
||||
#include "common/registry.h"
|
||||
|
||||
@@ -49,108 +49,177 @@ int main() {
|
||||
Checkbutton_001.w.set_text("Checkbutton_001");
|
||||
Checkbutton_001.w.set_active(false);
|
||||
Checkbutton_001.w.set_inconsistent(false);
|
||||
lg::Holder<GtkRadioButton> Radiobutton_001(display, screen, window, gc, &styles, 10, 140, 120, 26);
|
||||
lg::Holder<GtkToggleButton> ToggleButton_001(display, screen, window, gc, &styles, 10, 140, 110, 30);
|
||||
ToggleButton_001.w.set_active(false);
|
||||
ToggleButton_001.w.set_allow_all_up(false);
|
||||
ToggleButton_001.w.set_flat(false);
|
||||
lg::Holder<GtkRadioButton> Radiobutton_001(display, screen, window, gc, &styles, 200, 140, 120, 26);
|
||||
Radiobutton_001.w.set_text("Radiobutton_001");
|
||||
Radiobutton_001.w.set_active(false);
|
||||
lg::Holder<GtkFrame> Frame_001(display, screen, window, gc, &styles, 200, 140, 200, 120);
|
||||
lg::Holder<GtkFrame> Frame_001(display, screen, window, gc, &styles, 390, 140, 200, 120);
|
||||
Frame_001.w.set_label("Frame_001");
|
||||
lg::Holder<GtkComboBoxText> Combobox_001(display, screen, window, gc, &styles, 390, 140, 160, 28);
|
||||
Frame_001.w.set_label_xalign(0.0);
|
||||
Frame_001.w.set_inset(8);
|
||||
Frame_001.w.set_top_inset(14);
|
||||
lg::Holder<GtkComboBoxText> Combobox_001(display, screen, window, gc, &styles, 580, 140, 160, 28);
|
||||
Combobox_001.w.append_text("Item 1");
|
||||
Combobox_001.w.append_text("Item 2");
|
||||
Combobox_001.w.append_text("Item 3");
|
||||
Combobox_001.w.set_active(0);
|
||||
lg::Holder<GtkListBox> Listbox_001(display, screen, window, gc, &styles, 580, 140, 180, 110);
|
||||
lg::Holder<GtkListBox> Listbox_001(display, screen, window, gc, &styles, 10, 270, 180, 110);
|
||||
Listbox_001.w.add_row("Item 1");
|
||||
Listbox_001.w.add_row("Item 2");
|
||||
Listbox_001.w.add_row("Item 3");
|
||||
lg::Holder<TCheckListBox> CheckListBox_001(display, screen, window, gc, &styles, 10, 270, 180, 110);
|
||||
lg::Holder<TCheckListBox> CheckListBox_001(display, screen, window, gc, &styles, 200, 270, 180, 110);
|
||||
CheckListBox_001.w.add_item("Item 1");
|
||||
CheckListBox_001.w.add_item("Item 2");
|
||||
CheckListBox_001.w.add_item("Item 3");
|
||||
lg::Holder<GtkMenuButton> Menubutton_001(display, screen, window, gc, &styles, 200, 270, 110, 30);
|
||||
lg::Holder<GtkMenuButton> Menubutton_001(display, screen, window, gc, &styles, 390, 270, 110, 30);
|
||||
Menubutton_001.w.set_text("Menubutton_001");
|
||||
lg::Holder<GtkDrawingArea> Canvas_001(display, screen, window, gc, &styles, 390, 270, 200, 140);
|
||||
lg::Holder<GtkDrawingArea> Canvas_001(display, screen, window, gc, &styles, 580, 270, 200, 140);
|
||||
// NOTE: Canvas has no XFrame counterpart; drawn as a plain area.
|
||||
lg::Holder<GtkScale> Scale_001(display, screen, window, gc, &styles, 580, 270, 160, 28);
|
||||
lg::Holder<GtkScale> Scale_001(display, screen, window, gc, &styles, 10, 400, 160, 28);
|
||||
Scale_001.w.set_range(0.0, 100.0);
|
||||
Scale_001.w.set_value(0.0);
|
||||
Scale_001.w.set_draw_value(true);
|
||||
lg::Holder<GtkScrollbar> Scrollbar_001(display, screen, window, gc, &styles, 10, 400, 160, 18);
|
||||
lg::Holder<GtkScrollbar> Scrollbar_001(display, screen, window, gc, &styles, 200, 400, 160, 18);
|
||||
Scrollbar_001.w.set_upper(100.0);
|
||||
Scrollbar_001.w.set_page_size(10.0);
|
||||
Scrollbar_001.w.set_step(1.0);
|
||||
Scrollbar_001.w.set_value(0.0);
|
||||
lg::Holder<GtkTextView> Text_001(display, screen, window, gc, &styles, 200, 400, 220, 120);
|
||||
lg::Holder<GtkTextView> Text_001(display, screen, window, gc, &styles, 390, 400, 220, 120);
|
||||
Text_001.w.set_editable(true);
|
||||
Text_001.w.set_wrap_mode(false);
|
||||
lg::Holder<GtkWindow> Toplevel_001(display, screen, window, gc, &styles, 390, 400, 300, 200);
|
||||
lg::Holder<GtkWindow> Toplevel_001(display, screen, window, gc, &styles, 580, 400, 300, 200);
|
||||
Toplevel_001.w.set_title("Toplevel_001");
|
||||
Toplevel_001.w.set_resizable(true);
|
||||
lg::Holder<XSpreadsheet> Spreadsheet_001(display, screen, window, gc, &styles, 580, 400, 320, 180);
|
||||
Toplevel_001.w.set_border_style(0);
|
||||
Toplevel_001.w.set_position(0);
|
||||
Toplevel_001.w.set_window_state(0);
|
||||
lg::Holder<XSpreadsheet> Spreadsheet_001(display, screen, window, gc, &styles, 10, 530, 320, 180);
|
||||
Spreadsheet_001.w.set_size(4, 5);
|
||||
Spreadsheet_001.w.set_default_col_width(84);
|
||||
Spreadsheet_001.w.set_row_height(20);
|
||||
Spreadsheet_001.w.set_grid_line_width(1);
|
||||
// NOTE (model-only, no XFrame setter): columns=4
|
||||
lg::Holder<StockCandlestickChart> StockChart_001(display, screen, window, gc, &styles, 10, 530, 320, 200);
|
||||
lg::Holder<StockCandlestickChart> StockChart_001(display, screen, window, gc, &styles, 200, 530, 320, 200);
|
||||
StockChart_001.w.set_up_color(Srgb{0, 200, 0});
|
||||
StockChart_001.w.set_down_color(Srgb{220, 0, 0});
|
||||
// NOTE: StockChart design data not representable through the StockCandlestickChart API:
|
||||
// scale-mode: 0 (0 = price, 1 = percent)
|
||||
lg::Holder<TMemo> Memo_001(display, screen, window, gc, &styles, 200, 530, 220, 120);
|
||||
lg::Holder<TMemo> Memo_001(display, screen, window, gc, &styles, 390, 530, 220, 120);
|
||||
Memo_001.w.set_editable(true);
|
||||
Memo_001.w.set_wordwrap(false);
|
||||
lg::Holder<GtkFrame> GroupBox_001(display, screen, window, gc, &styles, 390, 530, 200, 120);
|
||||
lg::Holder<GtkFrame> GroupBox_001(display, screen, window, gc, &styles, 580, 530, 200, 120);
|
||||
GroupBox_001.w.set_label("GroupBox_001");
|
||||
lg::Holder<GtkFrame> Panel_001(display, screen, window, gc, &styles, 580, 530, 200, 120);
|
||||
GroupBox_001.w.set_label_xalign(0.0);
|
||||
GroupBox_001.w.set_inset(8);
|
||||
GroupBox_001.w.set_top_inset(14);
|
||||
lg::Holder<GtkFrame> Panel_001(display, screen, window, gc, &styles, 10, 660, 200, 120);
|
||||
Panel_001.w.set_label("Panel_001");
|
||||
lg::Holder<GtkImage> Image_001(display, screen, window, gc, &styles, 10, 660, 160, 120);
|
||||
Panel_001.w.set_label_xalign(0.0);
|
||||
Panel_001.w.set_inset(8);
|
||||
Panel_001.w.set_top_inset(14);
|
||||
lg::Holder<GtkImage> Image_001(display, screen, window, gc, &styles, 200, 660, 160, 120);
|
||||
Image_001.w.set_pixel_size(-1);
|
||||
lg::Holder<GtkDrawingArea> Shape_001(display, screen, window, gc, &styles, 200, 660, 160, 120);
|
||||
// NOTE: Shape ("0", fill "rgb(53,132,228)") has no XFrame counterpart; drawn as a plain area.
|
||||
lg::Holder<GtkNotebook> Notebook_001(display, screen, window, gc, &styles, 390, 660, 320, 200);
|
||||
Image_001.w.set_stretch(false);
|
||||
Image_001.w.set_proportional(true);
|
||||
Image_001.w.set_center(true);
|
||||
Image_001.w.set_transparent(false);
|
||||
lg::Holder<TShape> Shape_001(display, screen, window, gc, &styles, 390, 660, 160, 120);
|
||||
Shape_001.w.set_shape(0);
|
||||
Shape_001.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shape_001.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shape_001.w.set_pen_width(2);
|
||||
lg::Holder<GtkNotebook> Notebook_001(display, screen, window, gc, &styles, 580, 660, 320, 200);
|
||||
Notebook_001.w.append_page("Tab 1");
|
||||
Notebook_001.w.append_page("Tab 2");
|
||||
Notebook_001.w.append_page("Tab 3");
|
||||
Notebook_001.w.set_current_page(0);
|
||||
lg::Holder<GtkScrolledWindow> ScrollBox_001(display, screen, window, gc, &styles, 580, 660, 240, 160);
|
||||
Notebook_001.w.set_tab_height(26);
|
||||
Notebook_001.w.set_tab_position(0);
|
||||
lg::Holder<GtkScrolledWindow> ScrollBox_001(display, screen, window, gc, &styles, 10, 790, 240, 160);
|
||||
ScrollBox_001.w.set_text("ScrollBox_001");
|
||||
lg::Holder<GtkPaned> Splitter_001(display, screen, window, gc, &styles, 10, 790, 280, 160);
|
||||
lg::Holder<GtkPaned> Splitter_001(display, screen, window, gc, &styles, 200, 790, 280, 160);
|
||||
Splitter_001.w.set_position(100);
|
||||
Splitter_001.w.set_orientation(0);
|
||||
lg::Holder<GtkStatusbar> StatusBar_001(display, screen, window, gc, &styles, 200, 790, 320, 24);
|
||||
lg::Holder<GtkToolbar> ToolBar_001(display, screen, window, gc, &styles, 390, 790, 320, 36);
|
||||
Splitter_001.w.set_resize_style(0);
|
||||
Splitter_001.w.set_auto_snap(false);
|
||||
lg::Holder<GtkStatusbar> StatusBar_001(display, screen, window, gc, &styles, 390, 790, 320, 24);
|
||||
StatusBar_001.w.set_size_grip(true);
|
||||
lg::Holder<GtkToolbar> ToolBar_001(display, screen, window, gc, &styles, 580, 790, 320, 36);
|
||||
ToolBar_001.w.set_items({"New", "Open", "Save"});
|
||||
lg::Holder<GtkMenuBar> MenuBar_001(display, screen, window, gc, &styles, 580, 790, 320, 28);
|
||||
ToolBar_001.w.set_show_captions(true);
|
||||
ToolBar_001.w.set_flat(false);
|
||||
lg::Holder<GtkMenuBar> MenuBar_001(display, screen, window, gc, &styles, 10, 920, 320, 28);
|
||||
MenuBar_001.w.set_items({"File", "Edit", "Help"});
|
||||
lg::Holder<GtkSpinButton> SpinEdit_001(display, screen, window, gc, &styles, 10, 920, 120, 28);
|
||||
lg::Holder<GtkSpinButton> SpinEdit_001(display, screen, window, gc, &styles, 200, 920, 120, 28);
|
||||
SpinEdit_001.w.set_range(0.0, 100.0);
|
||||
SpinEdit_001.w.set_increments(1.0, 10.0);
|
||||
SpinEdit_001.w.set_value(0.0);
|
||||
SpinEdit_001.w.set_digits(0);
|
||||
SpinEdit_001.w.set_wrap(false);
|
||||
lg::Holder<GtkScale> TrackBar_001(display, screen, window, gc, &styles, 200, 920, 160, 28);
|
||||
SpinEdit_001.w.set_editable(true);
|
||||
lg::Holder<GtkScale> TrackBar_001(display, screen, window, gc, &styles, 390, 920, 160, 28);
|
||||
TrackBar_001.w.set_range(0.0, 100.0);
|
||||
TrackBar_001.w.set_step(1.0);
|
||||
TrackBar_001.w.set_value(0.0);
|
||||
TrackBar_001.w.set_draw_value(true);
|
||||
TrackBar_001.w.set_orientation_vertical(false);
|
||||
lg::Holder<GtkProgressBar> ProgressBar_001(display, screen, window, gc, &styles, 390, 920, 200, 24);
|
||||
ProgressBar_001.w.set_fraction(0.0);
|
||||
lg::Holder<GtkProgressBar> ProgressBar_001(display, screen, window, gc, &styles, 580, 920, 200, 24);
|
||||
ProgressBar_001.w.set_min(0.0);
|
||||
ProgressBar_001.w.set_max(100.0);
|
||||
ProgressBar_001.w.set_position(45.0);
|
||||
ProgressBar_001.w.set_show_text(false);
|
||||
lg::Holder<GtkCalendar> DateTimePicker_001(display, screen, window, gc, &styles, 580, 920, 240, 200);
|
||||
ProgressBar_001.w.set_pulsing(false);
|
||||
ProgressBar_001.w.set_inverted(false);
|
||||
ProgressBar_001.w.set_bar_color_rgb(52, 101, 164);
|
||||
ProgressBar_001.w.set_trough_color_rgb(225, 225, 225);
|
||||
lg::Holder<GtkCalendar> DateTimePicker_001(display, screen, window, gc, &styles, 10, 1050, 240, 200);
|
||||
DateTimePicker_001.w.set_show_heading(true);
|
||||
DateTimePicker_001.w.set_show_day_names(true);
|
||||
lg::Holder<GtkColorButton> ColorBox_001(display, screen, window, gc, &styles, 10, 1050, 120, 28);
|
||||
DateTimePicker_001.w.set_show_week_numbers(false);
|
||||
DateTimePicker_001.w.set_grid_color_rgb(205, 205, 205);
|
||||
DateTimePicker_001.w.set_selected_fill_color_rgb(52, 101, 164);
|
||||
DateTimePicker_001.w.set_selected_text_color_rgb(255, 255, 255);
|
||||
DateTimePicker_001.w.set_today_color_rgb(200, 50, 50);
|
||||
DateTimePicker_001.w.set_dim_text_color_rgb(110, 110, 110);
|
||||
DateTimePicker_001.w.set_weekends_color_rgb(170, 60, 60);
|
||||
DateTimePicker_001.w.set_disabled_color_rgb(150, 150, 150);
|
||||
lg::Holder<GtkColorButton> ColorBox_001(display, screen, window, gc, &styles, 200, 1050, 120, 28);
|
||||
ColorBox_001.w.set_color_rgb(53, 132, 228);
|
||||
lg::Holder<GtkListView> ListView_001(display, screen, window, gc, &styles, 200, 1050, 240, 140);
|
||||
ColorBox_001.w.set_style(0);
|
||||
ColorBox_001.w.set_default_color_rgb(255, 255, 255);
|
||||
ColorBox_001.w.set_none_color_rgb(0, 0, 0);
|
||||
lg::Holder<GtkListView> ListView_001(display, screen, window, gc, &styles, 390, 1050, 240, 140);
|
||||
ListView_001.w.add_item("Row 1,Value 1");
|
||||
ListView_001.w.add_item("Row 2,Value 2");
|
||||
lg::Holder<GtkTreeView> TreeView_001(display, screen, window, gc, &styles, 390, 1050, 240, 140);
|
||||
ListView_001.w.set_view_style(0);
|
||||
ListView_001.w.set_grid_lines(false);
|
||||
ListView_001.w.set_row_select(true);
|
||||
ListView_001.w.set_multi_select(false);
|
||||
ListView_001.w.set_sort_type(0);
|
||||
lg::Holder<GtkTreeView> TreeView_001(display, screen, window, gc, &styles, 580, 1050, 240, 140);
|
||||
TreeView_001.w.set_roots({GtkTreeView::Node{{"Root"}, {GtkTreeView::Node{{"Child 1"}, {}, true}}, true}, GtkTreeView::Node{{"Root"}, {GtkTreeView::Node{{"Child 2"}, {}, true}}, true}, GtkTreeView::Node{{"Other"}, {}, true}});
|
||||
lg::Holder<XSpreadsheet> StringGrid_001(display, screen, window, gc, &styles, 580, 1050, 280, 160);
|
||||
TreeView_001.w.set_header_height(22);
|
||||
TreeView_001.w.set_headers_visible(true);
|
||||
TreeView_001.w.set_grid_lines(false);
|
||||
TreeView_001.w.set_row_select(true);
|
||||
TreeView_001.w.set_multi_select(false);
|
||||
TreeView_001.w.set_sort_type(0);
|
||||
TreeView_001.w.set_indent(16);
|
||||
TreeView_001.w.set_show_buttons(true);
|
||||
TreeView_001.w.set_show_lines(true);
|
||||
TreeView_001.w.set_show_root(true);
|
||||
lg::Holder<XSpreadsheet> StringGrid_001(display, screen, window, gc, &styles, 10, 1180, 280, 160);
|
||||
StringGrid_001.w.set_size(4, 5);
|
||||
StringGrid_001.w.set_default_col_width(84);
|
||||
StringGrid_001.w.set_row_height(20);
|
||||
StringGrid_001.w.set_grid_line_width(1);
|
||||
// NOTE (model-only, no XFrame setter): columns=4
|
||||
lg::Holder<XGraph> Plot_001(display, screen, window, gc, &styles, 10, 1180, 280, 180);
|
||||
lg::Holder<XGraph> Plot_001(display, screen, window, gc, &styles, 200, 1180, 280, 180);
|
||||
// NOTE: Plot line colour "rgb(220,0,0)" is not representable through the XGraph API.
|
||||
std::vector<lg::IWidget*> widgets = { &Button_001, &Label_001, &Entry_001, &Checkbutton_001, &Radiobutton_001, &Frame_001, &Combobox_001, &Listbox_001, &CheckListBox_001, &Menubutton_001, &Canvas_001, &Scale_001, &Scrollbar_001, &Text_001, &Toplevel_001, &Spreadsheet_001, &StockChart_001, &Memo_001, &GroupBox_001, &Panel_001, &Image_001, &Shape_001, &Notebook_001, &ScrollBox_001, &Splitter_001, &StatusBar_001, &ToolBar_001, &MenuBar_001, &SpinEdit_001, &TrackBar_001, &ProgressBar_001, &DateTimePicker_001, &ColorBox_001, &ListView_001, &TreeView_001, &StringGrid_001, &Plot_001 };
|
||||
std::vector<lg::IWidget*> widgets = { &Button_001, &Label_001, &Entry_001, &Checkbutton_001, &ToggleButton_001, &Radiobutton_001, &Frame_001, &Combobox_001, &Listbox_001, &CheckListBox_001, &Menubutton_001, &Canvas_001, &Scale_001, &Scrollbar_001, &Text_001, &Toplevel_001, &Spreadsheet_001, &StockChart_001, &Memo_001, &GroupBox_001, &Panel_001, &Image_001, &Shape_001, &Notebook_001, &ScrollBox_001, &Splitter_001, &StatusBar_001, &ToolBar_001, &MenuBar_001, &SpinEdit_001, &TrackBar_001, &ProgressBar_001, &DateTimePicker_001, &ColorBox_001, &ListView_001, &TreeView_001, &StringGrid_001, &Plot_001 };
|
||||
auto redraw_all = [&]() {
|
||||
XClearWindow(display, window);
|
||||
for (lg::IWidget* wd : widgets) wd->draw();
|
||||
|
||||
@@ -30,7 +30,7 @@ Close the window (or its close button) to quit.
|
||||
|
||||
## Notes
|
||||
|
||||
- Widgets: 37 placed. Each is constructed
|
||||
- Widgets: 38 placed. Each is constructed
|
||||
as its XFrame class (e.g. `GtkButton`) with the geometry and
|
||||
properties from the design; colours and state use the widgets'
|
||||
getter/setter API where one exists, otherwise a per-widget
|
||||
|
||||
+201
-113
@@ -4,7 +4,7 @@
|
||||
// or the generated Makefile (make). Both need the XFrame widget
|
||||
// sources; see LIGHTGUI_WIDGETS_DIR in CMakeLists.txt / Makefile.
|
||||
//
|
||||
// The window is "Main Window" (800x600) with 37 widget(s).
|
||||
// The window is "Main Window" (800x600) with 38 widget(s).
|
||||
|
||||
#include "common/registry.h"
|
||||
|
||||
@@ -119,6 +119,7 @@ int main() {
|
||||
styles.add_style_ex("Label_001_style", Srgb{225, 225, 225}, Srgb{120, 120, 120}, Srgb{51, 102, 153}, Srgb{255, 255, 255}, 6, 1, lightgui_pick_font(display, "Test value", 13, true, true));
|
||||
styles.add_style_ex("Entry_001_style", Srgb{225, 225, 225}, Srgb{120, 120, 120}, Srgb{51, 102, 153}, Srgb{255, 255, 255}, 6, 1, lightgui_pick_font(display, "Test value", 13, true, true));
|
||||
styles.add_style_ex("Checkbutton_001_style", Srgb{51, 102, 153}, Srgb{120, 120, 120}, Srgb{51, 102, 153}, Srgb{255, 255, 255}, 6, 1, lightgui_pick_font(display, "Test value", 13, true, true));
|
||||
styles.add_style_ex("ToggleButton_001_style", Srgb{51, 102, 153}, Srgb{120, 120, 120}, Srgb{51, 102, 153}, Srgb{255, 255, 255}, 6, 1, lightgui_pick_font(display, "Test value", 13, true, true));
|
||||
styles.add_style_ex("Radiobutton_001_style", Srgb{51, 102, 153}, Srgb{120, 120, 120}, Srgb{51, 102, 153}, Srgb{255, 255, 255}, 6, 1, lightgui_pick_font(display, "Test value", 13, true, true));
|
||||
styles.add_style_ex("Frame_001_style", Srgb{51, 102, 153}, Srgb{120, 120, 120}, Srgb{51, 102, 153}, Srgb{255, 255, 255}, 6, 1, lightgui_pick_font(display, "Test value", 13, true, true));
|
||||
styles.add_style_ex("Combobox_001_style", Srgb{51, 102, 153}, Srgb{120, 120, 120}, Srgb{51, 102, 153}, Srgb{255, 255, 255}, 6, 1, lightgui_pick_font(display, "Test value", 13, true, true));
|
||||
@@ -208,22 +209,35 @@ int main() {
|
||||
Checkbutton_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Checkbutton_001, styles, "Checkbutton_001_style", 580, 10, 0, 0, 0, 0);
|
||||
lg::Holder<GtkRadioButton> Radiobutton_001(display, screen, window, gc, &styles, 10, 140, 120, 26);
|
||||
lg::Holder<GtkToggleButton> ToggleButton_001(display, screen, window, gc, &styles, 10, 140, 110, 30);
|
||||
ToggleButton_001.w.set_text("Test value");
|
||||
ToggleButton_001.w.set_active(true);
|
||||
ToggleButton_001.w.set_allow_all_up(true);
|
||||
ToggleButton_001.w.set_flat(true);
|
||||
ToggleButton_001.w.set_style_name("ToggleButton_001_style");
|
||||
ToggleButton_001.set_enabled(false);
|
||||
ToggleButton_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true, glyph="Test value"
|
||||
apply_autosize(&ToggleButton_001, styles, "ToggleButton_001_style", 10, 140, 0, 0, 0, 0);
|
||||
lg::Holder<GtkRadioButton> Radiobutton_001(display, screen, window, gc, &styles, 200, 140, 120, 26);
|
||||
Radiobutton_001.w.set_text("Test value");
|
||||
Radiobutton_001.w.set_active(true);
|
||||
Radiobutton_001.w.set_style_name("Radiobutton_001_style");
|
||||
Radiobutton_001.set_enabled(false);
|
||||
Radiobutton_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Radiobutton_001, styles, "Radiobutton_001_style", 10, 140, 0, 0, 0, 0);
|
||||
lg::Holder<GtkFrame> Frame_001(display, screen, window, gc, &styles, 200, 140, 200, 120);
|
||||
apply_autosize(&Radiobutton_001, styles, "Radiobutton_001_style", 200, 140, 0, 0, 0, 0);
|
||||
lg::Holder<GtkFrame> Frame_001(display, screen, window, gc, &styles, 390, 140, 200, 120);
|
||||
Frame_001.w.set_label("Test value");
|
||||
Frame_001.w.set_label_xalign(1.0);
|
||||
Frame_001.w.set_inset(8);
|
||||
Frame_001.w.set_top_inset(14);
|
||||
Frame_001.w.set_style_name("Frame_001_style");
|
||||
Frame_001.set_enabled(false);
|
||||
Frame_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Frame_001, styles, "Frame_001_style", 200, 140, 0, 0, 0, 0);
|
||||
lg::Holder<GtkComboBoxText> Combobox_001(display, screen, window, gc, &styles, 390, 140, 160, 28);
|
||||
apply_autosize(&Frame_001, styles, "Frame_001_style", 390, 140, 0, 0, 0, 0);
|
||||
lg::Holder<GtkComboBoxText> Combobox_001(display, screen, window, gc, &styles, 580, 140, 160, 28);
|
||||
Combobox_001.w.set_text("Test value");
|
||||
Combobox_001.w.append_text("Test value");
|
||||
Combobox_001.w.set_active(0);
|
||||
@@ -236,8 +250,8 @@ int main() {
|
||||
Combobox_001.set_enabled(false);
|
||||
Combobox_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Combobox_001, styles, "Combobox_001_style", 390, 140, 0, 0, 0, 0);
|
||||
lg::Holder<GtkListBox> Listbox_001(display, screen, window, gc, &styles, 580, 140, 180, 110);
|
||||
apply_autosize(&Combobox_001, styles, "Combobox_001_style", 580, 140, 0, 0, 0, 0);
|
||||
lg::Holder<GtkListBox> Listbox_001(display, screen, window, gc, &styles, 10, 270, 180, 110);
|
||||
Listbox_001.w.add_row("Test value");
|
||||
Listbox_001.w.set_multi_select(true);
|
||||
Listbox_001.w.set_sorted(true);
|
||||
@@ -246,8 +260,8 @@ int main() {
|
||||
Listbox_001.set_enabled(false);
|
||||
Listbox_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true, integral-height=true
|
||||
apply_autosize(&Listbox_001, styles, "Listbox_001_style", 580, 140, 0, 0, 0, 0);
|
||||
lg::Holder<TCheckListBox> CheckListBox_001(display, screen, window, gc, &styles, 10, 270, 180, 110);
|
||||
apply_autosize(&Listbox_001, styles, "Listbox_001_style", 10, 270, 0, 0, 0, 0);
|
||||
lg::Holder<TCheckListBox> CheckListBox_001(display, screen, window, gc, &styles, 200, 270, 180, 110);
|
||||
CheckListBox_001.w.add_item("Test value");
|
||||
CheckListBox_001.w.set_sorted(true);
|
||||
CheckListBox_001.w.set_checked_items("Test value");
|
||||
@@ -255,23 +269,23 @@ int main() {
|
||||
CheckListBox_001.set_enabled(false);
|
||||
CheckListBox_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&CheckListBox_001, styles, "CheckListBox_001_style", 10, 270, 0, 0, 0, 0);
|
||||
lg::Holder<GtkMenuButton> Menubutton_001(display, screen, window, gc, &styles, 200, 270, 110, 30);
|
||||
apply_autosize(&CheckListBox_001, styles, "CheckListBox_001_style", 200, 270, 0, 0, 0, 0);
|
||||
lg::Holder<GtkMenuButton> Menubutton_001(display, screen, window, gc, &styles, 390, 270, 110, 30);
|
||||
Menubutton_001.w.set_text("Test value");
|
||||
Menubutton_001.w.set_direction(4);
|
||||
Menubutton_001.w.set_style_name("Menubutton_001_style");
|
||||
Menubutton_001.set_enabled(false);
|
||||
Menubutton_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Menubutton_001, styles, "Menubutton_001_style", 200, 270, 0, 0, 0, 0);
|
||||
lg::Holder<GtkDrawingArea> Canvas_001(display, screen, window, gc, &styles, 390, 270, 200, 140);
|
||||
apply_autosize(&Menubutton_001, styles, "Menubutton_001_style", 390, 270, 0, 0, 0, 0);
|
||||
lg::Holder<GtkDrawingArea> Canvas_001(display, screen, window, gc, &styles, 580, 270, 200, 140);
|
||||
// NOTE: Canvas has no XFrame counterpart; drawn as a plain area.
|
||||
Canvas_001.w.set_style_name("Canvas_001_style");
|
||||
Canvas_001.set_enabled(false);
|
||||
Canvas_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Canvas_001, styles, "Canvas_001_style", 390, 270, 0, 0, 0, 0);
|
||||
lg::Holder<GtkScale> Scale_001(display, screen, window, gc, &styles, 580, 270, 160, 28);
|
||||
apply_autosize(&Canvas_001, styles, "Canvas_001_style", 580, 270, 0, 0, 0, 0);
|
||||
lg::Holder<GtkScale> Scale_001(display, screen, window, gc, &styles, 10, 400, 160, 28);
|
||||
Scale_001.w.set_range(42.5, 42.5);
|
||||
Scale_001.w.set_value(42.5);
|
||||
Scale_001.w.set_draw_value(false);
|
||||
@@ -283,8 +297,8 @@ int main() {
|
||||
Scale_001.set_enabled(false);
|
||||
Scale_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Scale_001, styles, "Scale_001_style", 580, 270, 0, 0, 0, 0);
|
||||
lg::Holder<GtkScrollbar> Scrollbar_001(display, screen, window, gc, &styles, 10, 400, 160, 18);
|
||||
apply_autosize(&Scale_001, styles, "Scale_001_style", 10, 400, 0, 0, 0, 0);
|
||||
lg::Holder<GtkScrollbar> Scrollbar_001(display, screen, window, gc, &styles, 200, 400, 160, 18);
|
||||
Scrollbar_001.w.set_lower(42.5);
|
||||
Scrollbar_001.w.set_upper(42.5);
|
||||
Scrollbar_001.w.set_page_size(42.5);
|
||||
@@ -297,8 +311,8 @@ int main() {
|
||||
Scrollbar_001.set_enabled(false);
|
||||
Scrollbar_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Scrollbar_001, styles, "Scrollbar_001_style", 10, 400, 0, 0, 0, 0);
|
||||
lg::Holder<GtkTextView> Text_001(display, screen, window, gc, &styles, 200, 400, 220, 120);
|
||||
apply_autosize(&Scrollbar_001, styles, "Scrollbar_001_style", 200, 400, 0, 0, 0, 0);
|
||||
lg::Holder<GtkTextView> Text_001(display, screen, window, gc, &styles, 390, 400, 220, 120);
|
||||
Text_001.w.set_text("Test value");
|
||||
Text_001.w.set_editable(false);
|
||||
Text_001.w.set_wrap_mode(true);
|
||||
@@ -313,24 +327,31 @@ int main() {
|
||||
Text_001.set_enabled(false);
|
||||
Text_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Text_001, styles, "Text_001_style", 200, 400, 0, 0, 0, 0);
|
||||
lg::Holder<GtkWindow> Toplevel_001(display, screen, window, gc, &styles, 390, 400, 300, 200);
|
||||
apply_autosize(&Text_001, styles, "Text_001_style", 390, 400, 0, 0, 0, 0);
|
||||
lg::Holder<GtkWindow> Toplevel_001(display, screen, window, gc, &styles, 580, 400, 300, 200);
|
||||
Toplevel_001.w.set_title("Test value");
|
||||
Toplevel_001.w.set_resizable(false);
|
||||
Toplevel_001.w.set_border_style(3);
|
||||
// NOTE: icon "Test value" is not loaded by the generated app.
|
||||
Toplevel_001.w.set_position(4);
|
||||
Toplevel_001.w.set_window_state(3);
|
||||
Toplevel_001.w.set_style_name("Toplevel_001_style");
|
||||
Toplevel_001.set_enabled(false);
|
||||
Toplevel_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Toplevel_001, styles, "Toplevel_001_style", 390, 400, 0, 0, 0, 0);
|
||||
lg::Holder<XSpreadsheet> Spreadsheet_001(display, screen, window, gc, &styles, 580, 400, 320, 180);
|
||||
apply_autosize(&Toplevel_001, styles, "Toplevel_001_style", 580, 400, 0, 0, 0, 0);
|
||||
lg::Holder<XSpreadsheet> Spreadsheet_001(display, screen, window, gc, &styles, 10, 530, 320, 180);
|
||||
Spreadsheet_001.w.set_size(4, 5);
|
||||
Spreadsheet_001.w.set_default_col_width(84);
|
||||
Spreadsheet_001.w.set_row_height(20);
|
||||
Spreadsheet_001.w.set_grid_line_width(1);
|
||||
Spreadsheet_001.w.set_white_color_rgb(51, 102, 153);
|
||||
Spreadsheet_001.w.set_style_name("Spreadsheet_001_style");
|
||||
Spreadsheet_001.set_enabled(false);
|
||||
Spreadsheet_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true, columns=4
|
||||
apply_autosize(&Spreadsheet_001, styles, "Spreadsheet_001_style", 580, 400, 0, 0, 0, 0);
|
||||
lg::Holder<StockCandlestickChart> StockChart_001(display, screen, window, gc, &styles, 10, 530, 320, 200);
|
||||
apply_autosize(&Spreadsheet_001, styles, "Spreadsheet_001_style", 10, 530, 0, 0, 0, 0);
|
||||
lg::Holder<StockCandlestickChart> StockChart_001(display, screen, window, gc, &styles, 200, 530, 320, 200);
|
||||
StockChart_001.w.set_up_color(Srgb{51, 102, 153});
|
||||
StockChart_001.w.set_down_color(Srgb{51, 102, 153});
|
||||
// NOTE: StockChart design data not representable through the StockCandlestickChart API:
|
||||
@@ -344,8 +365,8 @@ int main() {
|
||||
StockChart_001.set_enabled(false);
|
||||
StockChart_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&StockChart_001, styles, "StockChart_001_style", 10, 530, 0, 0, 0, 0);
|
||||
lg::Holder<TMemo> Memo_001(display, screen, window, gc, &styles, 200, 530, 220, 120);
|
||||
apply_autosize(&StockChart_001, styles, "StockChart_001_style", 200, 530, 0, 0, 0, 0);
|
||||
lg::Holder<TMemo> Memo_001(display, screen, window, gc, &styles, 390, 530, 220, 120);
|
||||
Memo_001.w.set_text("Test value");
|
||||
Memo_001.w.set_editable(false);
|
||||
Memo_001.w.set_cursor_visible(false);
|
||||
@@ -359,94 +380,116 @@ int main() {
|
||||
Memo_001.set_enabled(false);
|
||||
Memo_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Memo_001, styles, "Memo_001_style", 200, 530, 0, 0, 0, 0);
|
||||
lg::Holder<GtkFrame> GroupBox_001(display, screen, window, gc, &styles, 390, 530, 200, 120);
|
||||
apply_autosize(&Memo_001, styles, "Memo_001_style", 390, 530, 0, 0, 0, 0);
|
||||
lg::Holder<GtkFrame> GroupBox_001(display, screen, window, gc, &styles, 580, 530, 200, 120);
|
||||
GroupBox_001.w.set_label("Test value");
|
||||
GroupBox_001.w.set_label_xalign(1.0);
|
||||
GroupBox_001.w.set_inset(8);
|
||||
GroupBox_001.w.set_top_inset(14);
|
||||
GroupBox_001.w.set_style_name("GroupBox_001_style");
|
||||
GroupBox_001.set_enabled(false);
|
||||
GroupBox_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&GroupBox_001, styles, "GroupBox_001_style", 390, 530, 0, 0, 0, 0);
|
||||
lg::Holder<GtkFrame> Panel_001(display, screen, window, gc, &styles, 580, 530, 200, 120);
|
||||
apply_autosize(&GroupBox_001, styles, "GroupBox_001_style", 580, 530, 0, 0, 0, 0);
|
||||
lg::Holder<GtkFrame> Panel_001(display, screen, window, gc, &styles, 10, 660, 200, 120);
|
||||
Panel_001.w.set_label("Test value");
|
||||
Panel_001.w.set_label_xalign(1.0);
|
||||
Panel_001.w.set_inset(8);
|
||||
Panel_001.w.set_top_inset(14);
|
||||
Panel_001.w.set_style_name("Panel_001_style");
|
||||
Panel_001.set_enabled(false);
|
||||
Panel_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Panel_001, styles, "Panel_001_style", 580, 530, 0, 0, 0, 0);
|
||||
lg::Holder<GtkImage> Image_001(display, screen, window, gc, &styles, 10, 660, 160, 120);
|
||||
apply_autosize(&Panel_001, styles, "Panel_001_style", 10, 660, 0, 0, 0, 0);
|
||||
lg::Holder<GtkImage> Image_001(display, screen, window, gc, &styles, 200, 660, 160, 120);
|
||||
Image_001.w.set_filename("Test value");
|
||||
Image_001.w.set_pixel_size(-1);
|
||||
Image_001.w.set_stretch(true);
|
||||
Image_001.w.set_proportional(false);
|
||||
Image_001.w.set_center(false);
|
||||
Image_001.w.set_transparent(true);
|
||||
Image_001.w.set_style_name("Image_001_style");
|
||||
Image_001.set_enabled(false);
|
||||
Image_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Image_001, styles, "Image_001_style", 10, 660, 0, 0, 0, 0);
|
||||
lg::Holder<GtkDrawingArea> Shape_001(display, screen, window, gc, &styles, 200, 660, 160, 120);
|
||||
// NOTE: Shape ("3", fill "#336699") has no XFrame counterpart; drawn as a plain area.
|
||||
apply_autosize(&Image_001, styles, "Image_001_style", 200, 660, 0, 0, 0, 0);
|
||||
lg::Holder<TShape> Shape_001(display, screen, window, gc, &styles, 390, 660, 160, 120);
|
||||
Shape_001.w.set_shape(9);
|
||||
Shape_001.w.set_fill_color(Srgb{51, 102, 153});
|
||||
Shape_001.w.set_pen_color(Srgb{51, 102, 153});
|
||||
Shape_001.w.set_pen_width(2);
|
||||
Shape_001.w.set_style_name("Shape_001_style");
|
||||
Shape_001.set_enabled(false);
|
||||
Shape_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Shape_001, styles, "Shape_001_style", 200, 660, 0, 0, 0, 0);
|
||||
lg::Holder<GtkNotebook> Notebook_001(display, screen, window, gc, &styles, 390, 660, 320, 200);
|
||||
apply_autosize(&Shape_001, styles, "Shape_001_style", 390, 660, 0, 0, 0, 0);
|
||||
lg::Holder<GtkNotebook> Notebook_001(display, screen, window, gc, &styles, 580, 660, 320, 200);
|
||||
Notebook_001.w.append_page("Test value");
|
||||
Notebook_001.w.set_current_page(0);
|
||||
Notebook_001.w.set_tab_height(26);
|
||||
Notebook_001.w.set_tab_position(3);
|
||||
Notebook_001.w.set_style_name("Notebook_001_style");
|
||||
Notebook_001.set_enabled(false);
|
||||
Notebook_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Notebook_001, styles, "Notebook_001_style", 390, 660, 0, 0, 0, 0);
|
||||
lg::Holder<GtkScrolledWindow> ScrollBox_001(display, screen, window, gc, &styles, 580, 660, 240, 160);
|
||||
apply_autosize(&Notebook_001, styles, "Notebook_001_style", 580, 660, 0, 0, 0, 0);
|
||||
lg::Holder<GtkScrolledWindow> ScrollBox_001(display, screen, window, gc, &styles, 10, 790, 240, 160);
|
||||
ScrollBox_001.w.set_text("Test value");
|
||||
ScrollBox_001.w.set_viewport_background_color_rgb(51, 102, 153);
|
||||
ScrollBox_001.w.set_style_name("ScrollBox_001_style");
|
||||
ScrollBox_001.set_enabled(false);
|
||||
ScrollBox_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&ScrollBox_001, styles, "ScrollBox_001_style", 580, 660, 0, 0, 0, 0);
|
||||
lg::Holder<GtkPaned> Splitter_001(display, screen, window, gc, &styles, 10, 790, 280, 160);
|
||||
apply_autosize(&ScrollBox_001, styles, "ScrollBox_001_style", 10, 790, 0, 0, 0, 0);
|
||||
lg::Holder<GtkPaned> Splitter_001(display, screen, window, gc, &styles, 200, 790, 280, 160);
|
||||
Splitter_001.w.set_position(100);
|
||||
Splitter_001.w.set_orientation(1);
|
||||
Splitter_001.w.set_resize_style(1);
|
||||
Splitter_001.w.set_auto_snap(true);
|
||||
Splitter_001.w.set_style_name("Splitter_001_style");
|
||||
Splitter_001.set_enabled(false);
|
||||
Splitter_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Splitter_001, styles, "Splitter_001_style", 10, 790, 0, 0, 0, 0);
|
||||
lg::Holder<GtkStatusbar> StatusBar_001(display, screen, window, gc, &styles, 200, 790, 320, 24);
|
||||
apply_autosize(&Splitter_001, styles, "Splitter_001_style", 200, 790, 0, 0, 0, 0);
|
||||
lg::Holder<GtkStatusbar> StatusBar_001(display, screen, window, gc, &styles, 390, 790, 320, 24);
|
||||
StatusBar_001.w.set_text("Test value");
|
||||
StatusBar_001.w.set_items("Test value");
|
||||
StatusBar_001.w.set_size_grip(false);
|
||||
StatusBar_001.w.set_style_name("StatusBar_001_style");
|
||||
StatusBar_001.set_enabled(false);
|
||||
StatusBar_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&StatusBar_001, styles, "StatusBar_001_style", 200, 790, 0, 0, 0, 0);
|
||||
lg::Holder<GtkToolbar> ToolBar_001(display, screen, window, gc, &styles, 390, 790, 320, 36);
|
||||
apply_autosize(&StatusBar_001, styles, "StatusBar_001_style", 390, 790, 0, 0, 0, 0);
|
||||
lg::Holder<GtkToolbar> ToolBar_001(display, screen, window, gc, &styles, 580, 790, 320, 36);
|
||||
ToolBar_001.w.set_items({"Test value"});
|
||||
ToolBar_001.w.set_show_captions(false);
|
||||
ToolBar_001.w.set_flat(true);
|
||||
ToolBar_001.w.set_style_name("ToolBar_001_style");
|
||||
ToolBar_001.set_enabled(false);
|
||||
ToolBar_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&ToolBar_001, styles, "ToolBar_001_style", 390, 790, 0, 0, 0, 0);
|
||||
lg::Holder<GtkMenuBar> MenuBar_001(display, screen, window, gc, &styles, 580, 790, 320, 28);
|
||||
apply_autosize(&ToolBar_001, styles, "ToolBar_001_style", 580, 790, 0, 0, 0, 0);
|
||||
lg::Holder<GtkMenuBar> MenuBar_001(display, screen, window, gc, &styles, 10, 920, 320, 28);
|
||||
MenuBar_001.w.set_items({"Test value"});
|
||||
MenuBar_001.w.set_style_name("MenuBar_001_style");
|
||||
MenuBar_001.set_enabled(false);
|
||||
MenuBar_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&MenuBar_001, styles, "MenuBar_001_style", 580, 790, 0, 0, 0, 0);
|
||||
lg::Holder<GtkSpinButton> SpinEdit_001(display, screen, window, gc, &styles, 10, 920, 120, 28);
|
||||
apply_autosize(&MenuBar_001, styles, "MenuBar_001_style", 10, 920, 0, 0, 0, 0);
|
||||
lg::Holder<GtkSpinButton> SpinEdit_001(display, screen, window, gc, &styles, 200, 920, 120, 28);
|
||||
SpinEdit_001.w.set_range(0.0, 100.0);
|
||||
SpinEdit_001.w.set_increments(1.0, 10.0);
|
||||
SpinEdit_001.w.set_value(42.5);
|
||||
SpinEdit_001.w.set_digits(0);
|
||||
SpinEdit_001.w.set_wrap(true);
|
||||
SpinEdit_001.w.set_editable(false);
|
||||
SpinEdit_001.w.set_fill_color_rgb(51, 102, 153);
|
||||
SpinEdit_001.w.set_style_name("SpinEdit_001_style");
|
||||
SpinEdit_001.set_enabled(false);
|
||||
SpinEdit_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&SpinEdit_001, styles, "SpinEdit_001_style", 10, 920, 0, 0, 0, 0);
|
||||
lg::Holder<GtkScale> TrackBar_001(display, screen, window, gc, &styles, 200, 920, 160, 28);
|
||||
apply_autosize(&SpinEdit_001, styles, "SpinEdit_001_style", 200, 920, 0, 0, 0, 0);
|
||||
lg::Holder<GtkScale> TrackBar_001(display, screen, window, gc, &styles, 390, 920, 160, 28);
|
||||
TrackBar_001.w.set_range(0.0, 100.0);
|
||||
TrackBar_001.w.set_step(1.0);
|
||||
TrackBar_001.w.set_value(42.5);
|
||||
@@ -461,62 +504,98 @@ int main() {
|
||||
TrackBar_001.set_enabled(false);
|
||||
TrackBar_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&TrackBar_001, styles, "TrackBar_001_style", 200, 920, 0, 0, 0, 0);
|
||||
lg::Holder<GtkProgressBar> ProgressBar_001(display, screen, window, gc, &styles, 390, 920, 200, 24);
|
||||
apply_autosize(&TrackBar_001, styles, "TrackBar_001_style", 390, 920, 0, 0, 0, 0);
|
||||
lg::Holder<GtkProgressBar> ProgressBar_001(display, screen, window, gc, &styles, 580, 920, 200, 24);
|
||||
ProgressBar_001.w.set_text("Test value");
|
||||
ProgressBar_001.w.set_fraction(1.0);
|
||||
ProgressBar_001.w.set_min(42.5);
|
||||
ProgressBar_001.w.set_max(42.5);
|
||||
ProgressBar_001.w.set_position(42.5);
|
||||
ProgressBar_001.w.set_step(42.5);
|
||||
ProgressBar_001.w.set_show_text(true);
|
||||
ProgressBar_001.w.set_pulsing(true);
|
||||
ProgressBar_001.w.set_inverted(true);
|
||||
ProgressBar_001.w.set_bar_color_rgb(51, 102, 153);
|
||||
ProgressBar_001.w.set_trough_color_rgb(51, 102, 153);
|
||||
ProgressBar_001.w.set_style_name("ProgressBar_001_style");
|
||||
ProgressBar_001.set_enabled(false);
|
||||
ProgressBar_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&ProgressBar_001, styles, "ProgressBar_001_style", 390, 920, 0, 0, 0, 0);
|
||||
lg::Holder<GtkCalendar> DateTimePicker_001(display, screen, window, gc, &styles, 580, 920, 240, 200);
|
||||
apply_autosize(&ProgressBar_001, styles, "ProgressBar_001_style", 580, 920, 0, 0, 0, 0);
|
||||
lg::Holder<GtkCalendar> DateTimePicker_001(display, screen, window, gc, &styles, 10, 1050, 240, 200);
|
||||
DateTimePicker_001.w.set_show_heading(false);
|
||||
DateTimePicker_001.w.set_show_day_names(false);
|
||||
DateTimePicker_001.w.set_show_week_numbers(true);
|
||||
DateTimePicker_001.w.set_grid_color_rgb(51, 102, 153);
|
||||
DateTimePicker_001.w.set_selected_fill_color_rgb(51, 102, 153);
|
||||
DateTimePicker_001.w.set_selected_text_color_rgb(51, 102, 153);
|
||||
DateTimePicker_001.w.set_today_color_rgb(51, 102, 153);
|
||||
DateTimePicker_001.w.set_dim_text_color_rgb(51, 102, 153);
|
||||
DateTimePicker_001.w.set_weekends_color_rgb(51, 102, 153);
|
||||
DateTimePicker_001.w.set_disabled_color_rgb(51, 102, 153);
|
||||
DateTimePicker_001.w.set_style_name("DateTimePicker_001_style");
|
||||
DateTimePicker_001.set_enabled(false);
|
||||
DateTimePicker_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&DateTimePicker_001, styles, "DateTimePicker_001_style", 580, 920, 0, 0, 0, 0);
|
||||
lg::Holder<GtkColorButton> ColorBox_001(display, screen, window, gc, &styles, 10, 1050, 120, 28);
|
||||
apply_autosize(&DateTimePicker_001, styles, "DateTimePicker_001_style", 10, 1050, 0, 0, 0, 0);
|
||||
lg::Holder<GtkColorButton> ColorBox_001(display, screen, window, gc, &styles, 200, 1050, 120, 28);
|
||||
ColorBox_001.w.set_color_rgb(51, 102, 153);
|
||||
ColorBox_001.w.set_style(3);
|
||||
ColorBox_001.w.set_default_color_rgb(51, 102, 153);
|
||||
ColorBox_001.w.set_none_color_rgb(51, 102, 153);
|
||||
ColorBox_001.w.set_style_name("ColorBox_001_style");
|
||||
ColorBox_001.set_enabled(false);
|
||||
ColorBox_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&ColorBox_001, styles, "ColorBox_001_style", 10, 1050, 0, 0, 0, 0);
|
||||
lg::Holder<GtkListView> ListView_001(display, screen, window, gc, &styles, 200, 1050, 240, 140);
|
||||
apply_autosize(&ColorBox_001, styles, "ColorBox_001_style", 200, 1050, 0, 0, 0, 0);
|
||||
lg::Holder<GtkListView> ListView_001(display, screen, window, gc, &styles, 390, 1050, 240, 140);
|
||||
ListView_001.w.add_item("Test value");
|
||||
ListView_001.w.set_view_style(3);
|
||||
ListView_001.w.set_grid_lines(true);
|
||||
ListView_001.w.set_row_select(false);
|
||||
ListView_001.w.set_multi_select(true);
|
||||
ListView_001.w.set_sort_type(2);
|
||||
ListView_001.w.set_style_name("ListView_001_style");
|
||||
ListView_001.set_enabled(false);
|
||||
ListView_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&ListView_001, styles, "ListView_001_style", 200, 1050, 0, 0, 0, 0);
|
||||
lg::Holder<GtkTreeView> TreeView_001(display, screen, window, gc, &styles, 390, 1050, 240, 140);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true, headers-visible=false (no ListView header API)
|
||||
apply_autosize(&ListView_001, styles, "ListView_001_style", 390, 1050, 0, 0, 0, 0);
|
||||
lg::Holder<GtkTreeView> TreeView_001(display, screen, window, gc, &styles, 580, 1050, 240, 140);
|
||||
TreeView_001.w.set_roots({GtkTreeView::Node{{"Test value"}, {}, true}});
|
||||
TreeView_001.w.set_header_height(22);
|
||||
TreeView_001.w.set_headers_visible(false);
|
||||
TreeView_001.w.set_grid_lines(true);
|
||||
TreeView_001.w.set_row_select(false);
|
||||
TreeView_001.w.set_multi_select(true);
|
||||
TreeView_001.w.set_sort_type(2);
|
||||
TreeView_001.w.set_indent(16);
|
||||
TreeView_001.w.set_show_buttons(false);
|
||||
TreeView_001.w.set_show_lines(false);
|
||||
TreeView_001.w.set_show_root(false);
|
||||
TreeView_001.w.set_style_name("TreeView_001_style");
|
||||
TreeView_001.set_enabled(false);
|
||||
TreeView_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&TreeView_001, styles, "TreeView_001_style", 390, 1050, 0, 0, 0, 0);
|
||||
lg::Holder<XSpreadsheet> StringGrid_001(display, screen, window, gc, &styles, 580, 1050, 280, 160);
|
||||
apply_autosize(&TreeView_001, styles, "TreeView_001_style", 580, 1050, 0, 0, 0, 0);
|
||||
lg::Holder<XSpreadsheet> StringGrid_001(display, screen, window, gc, &styles, 10, 1180, 280, 160);
|
||||
StringGrid_001.w.set_size(4, 5);
|
||||
StringGrid_001.w.set_default_col_width(84);
|
||||
StringGrid_001.w.set_row_height(20);
|
||||
StringGrid_001.w.set_grid_line_width(1);
|
||||
StringGrid_001.w.set_white_color_rgb(51, 102, 153);
|
||||
StringGrid_001.w.set_style_name("StringGrid_001_style");
|
||||
StringGrid_001.set_enabled(false);
|
||||
StringGrid_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true, columns=4
|
||||
apply_autosize(&StringGrid_001, styles, "StringGrid_001_style", 580, 1050, 0, 0, 0, 0);
|
||||
lg::Holder<XGraph> Plot_001(display, screen, window, gc, &styles, 10, 1180, 280, 180);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true, headers-visible=false (grid headers always shown), columns=4
|
||||
apply_autosize(&StringGrid_001, styles, "StringGrid_001_style", 10, 1180, 0, 0, 0, 0);
|
||||
lg::Holder<XGraph> Plot_001(display, screen, window, gc, &styles, 200, 1180, 280, 180);
|
||||
// NOTE: Plot line colour "#336699" is not representable through the XGraph API.
|
||||
Plot_001.w.set_white_color_rgb(51, 102, 153);
|
||||
Plot_001.w.set_style_name("Plot_001_style");
|
||||
Plot_001.set_enabled(false);
|
||||
Plot_001.set_visible(false);
|
||||
// NOTE (model-only, no XFrame setter): hint="Test value", tooltip-text="tip with \"quotes\" and \\ slash", cursor="Test value", tab-stop=false, show-hint=true, font-underline=true, font-strikeout=true
|
||||
apply_autosize(&Plot_001, styles, "Plot_001_style", 10, 1180, 0, 0, 0, 0);
|
||||
std::vector<lg::IWidget*> widgets = { &Button_001, &Label_001, &Entry_001, &Checkbutton_001, &Radiobutton_001, &Frame_001, &Combobox_001, &Listbox_001, &CheckListBox_001, &Menubutton_001, &Canvas_001, &Scale_001, &Scrollbar_001, &Text_001, &Toplevel_001, &Spreadsheet_001, &StockChart_001, &Memo_001, &GroupBox_001, &Panel_001, &Image_001, &Shape_001, &Notebook_001, &ScrollBox_001, &Splitter_001, &StatusBar_001, &ToolBar_001, &MenuBar_001, &SpinEdit_001, &TrackBar_001, &ProgressBar_001, &DateTimePicker_001, &ColorBox_001, &ListView_001, &TreeView_001, &StringGrid_001, &Plot_001 };
|
||||
apply_autosize(&Plot_001, styles, "Plot_001_style", 200, 1180, 0, 0, 0, 0);
|
||||
std::vector<lg::IWidget*> widgets = { &Button_001, &Label_001, &Entry_001, &Checkbutton_001, &ToggleButton_001, &Radiobutton_001, &Frame_001, &Combobox_001, &Listbox_001, &CheckListBox_001, &Menubutton_001, &Canvas_001, &Scale_001, &Scrollbar_001, &Text_001, &Toplevel_001, &Spreadsheet_001, &StockChart_001, &Memo_001, &GroupBox_001, &Panel_001, &Image_001, &Shape_001, &Notebook_001, &ScrollBox_001, &Splitter_001, &StatusBar_001, &ToolBar_001, &MenuBar_001, &SpinEdit_001, &TrackBar_001, &ProgressBar_001, &DateTimePicker_001, &ColorBox_001, &ListView_001, &TreeView_001, &StringGrid_001, &Plot_001 };
|
||||
// Anchors (Phase 1, Flag 1): minimal anchor layout. Each anchored widget is repositioned/resized from its design geometry when the window resizes; top+left alone is static and needs no code.
|
||||
auto apply_anchors = [&](int new_w, int new_h) {
|
||||
{ // Button_001: anchors top, left, right, bottom
|
||||
@@ -555,9 +634,18 @@ int main() {
|
||||
if (_h < 16) _h = 16;
|
||||
Checkbutton_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Radiobutton_001: anchors top, left, right, bottom
|
||||
{ // ToggleButton_001: anchors top, left, right, bottom
|
||||
int _x = 10;
|
||||
int _y = 140;
|
||||
int _w = 110 + (new_w - 800);
|
||||
int _h = 30 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
if (_h < 16) _h = 16;
|
||||
ToggleButton_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Radiobutton_001: anchors top, left, right, bottom
|
||||
int _x = 200;
|
||||
int _y = 140;
|
||||
int _w = 120 + (new_w - 800);
|
||||
int _h = 26 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
@@ -565,7 +653,7 @@ int main() {
|
||||
Radiobutton_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Frame_001: anchors top, left, right, bottom
|
||||
int _x = 200;
|
||||
int _x = 390;
|
||||
int _y = 140;
|
||||
int _w = 200 + (new_w - 800);
|
||||
int _h = 120 + (new_h - 600);
|
||||
@@ -574,7 +662,7 @@ int main() {
|
||||
Frame_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Combobox_001: anchors top, left, right, bottom
|
||||
int _x = 390;
|
||||
int _x = 580;
|
||||
int _y = 140;
|
||||
int _w = 160 + (new_w - 800);
|
||||
int _h = 28 + (new_h - 600);
|
||||
@@ -583,8 +671,8 @@ int main() {
|
||||
Combobox_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Listbox_001: anchors top, left, right, bottom
|
||||
int _x = 580;
|
||||
int _y = 140;
|
||||
int _x = 10;
|
||||
int _y = 270;
|
||||
int _w = 180 + (new_w - 800);
|
||||
int _h = 110 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
@@ -592,7 +680,7 @@ int main() {
|
||||
Listbox_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // CheckListBox_001: anchors top, left, right, bottom
|
||||
int _x = 10;
|
||||
int _x = 200;
|
||||
int _y = 270;
|
||||
int _w = 180 + (new_w - 800);
|
||||
int _h = 110 + (new_h - 600);
|
||||
@@ -601,7 +689,7 @@ int main() {
|
||||
CheckListBox_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Menubutton_001: anchors top, left, right, bottom
|
||||
int _x = 200;
|
||||
int _x = 390;
|
||||
int _y = 270;
|
||||
int _w = 110 + (new_w - 800);
|
||||
int _h = 30 + (new_h - 600);
|
||||
@@ -610,7 +698,7 @@ int main() {
|
||||
Menubutton_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Canvas_001: anchors top, left, right, bottom
|
||||
int _x = 390;
|
||||
int _x = 580;
|
||||
int _y = 270;
|
||||
int _w = 200 + (new_w - 800);
|
||||
int _h = 140 + (new_h - 600);
|
||||
@@ -619,8 +707,8 @@ int main() {
|
||||
Canvas_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Scale_001: anchors top, left, right, bottom
|
||||
int _x = 580;
|
||||
int _y = 270;
|
||||
int _x = 10;
|
||||
int _y = 400;
|
||||
int _w = 160 + (new_w - 800);
|
||||
int _h = 28 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
@@ -628,7 +716,7 @@ int main() {
|
||||
Scale_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Scrollbar_001: anchors top, left, right, bottom
|
||||
int _x = 10;
|
||||
int _x = 200;
|
||||
int _y = 400;
|
||||
int _w = 160 + (new_w - 800);
|
||||
int _h = 18 + (new_h - 600);
|
||||
@@ -637,7 +725,7 @@ int main() {
|
||||
Scrollbar_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Text_001: anchors top, left, right, bottom
|
||||
int _x = 200;
|
||||
int _x = 390;
|
||||
int _y = 400;
|
||||
int _w = 220 + (new_w - 800);
|
||||
int _h = 120 + (new_h - 600);
|
||||
@@ -646,7 +734,7 @@ int main() {
|
||||
Text_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Toplevel_001: anchors top, left, right, bottom
|
||||
int _x = 390;
|
||||
int _x = 580;
|
||||
int _y = 400;
|
||||
int _w = 300 + (new_w - 800);
|
||||
int _h = 200 + (new_h - 600);
|
||||
@@ -655,8 +743,8 @@ int main() {
|
||||
Toplevel_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Spreadsheet_001: anchors top, left, right, bottom
|
||||
int _x = 580;
|
||||
int _y = 400;
|
||||
int _x = 10;
|
||||
int _y = 530;
|
||||
int _w = 320 + (new_w - 800);
|
||||
int _h = 180 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
@@ -664,7 +752,7 @@ int main() {
|
||||
Spreadsheet_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // StockChart_001: anchors top, left, right, bottom
|
||||
int _x = 10;
|
||||
int _x = 200;
|
||||
int _y = 530;
|
||||
int _w = 320 + (new_w - 800);
|
||||
int _h = 200 + (new_h - 600);
|
||||
@@ -673,7 +761,7 @@ int main() {
|
||||
StockChart_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Memo_001: anchors top, left, right, bottom
|
||||
int _x = 200;
|
||||
int _x = 390;
|
||||
int _y = 530;
|
||||
int _w = 220 + (new_w - 800);
|
||||
int _h = 120 + (new_h - 600);
|
||||
@@ -682,7 +770,7 @@ int main() {
|
||||
Memo_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // GroupBox_001: anchors top, left, right, bottom
|
||||
int _x = 390;
|
||||
int _x = 580;
|
||||
int _y = 530;
|
||||
int _w = 200 + (new_w - 800);
|
||||
int _h = 120 + (new_h - 600);
|
||||
@@ -691,8 +779,8 @@ int main() {
|
||||
GroupBox_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Panel_001: anchors top, left, right, bottom
|
||||
int _x = 580;
|
||||
int _y = 530;
|
||||
int _x = 10;
|
||||
int _y = 660;
|
||||
int _w = 200 + (new_w - 800);
|
||||
int _h = 120 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
@@ -700,7 +788,7 @@ int main() {
|
||||
Panel_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Image_001: anchors top, left, right, bottom
|
||||
int _x = 10;
|
||||
int _x = 200;
|
||||
int _y = 660;
|
||||
int _w = 160 + (new_w - 800);
|
||||
int _h = 120 + (new_h - 600);
|
||||
@@ -709,7 +797,7 @@ int main() {
|
||||
Image_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Shape_001: anchors top, left, right, bottom
|
||||
int _x = 200;
|
||||
int _x = 390;
|
||||
int _y = 660;
|
||||
int _w = 160 + (new_w - 800);
|
||||
int _h = 120 + (new_h - 600);
|
||||
@@ -718,7 +806,7 @@ int main() {
|
||||
Shape_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Notebook_001: anchors top, left, right, bottom
|
||||
int _x = 390;
|
||||
int _x = 580;
|
||||
int _y = 660;
|
||||
int _w = 320 + (new_w - 800);
|
||||
int _h = 200 + (new_h - 600);
|
||||
@@ -727,8 +815,8 @@ int main() {
|
||||
Notebook_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // ScrollBox_001: anchors top, left, right, bottom
|
||||
int _x = 580;
|
||||
int _y = 660;
|
||||
int _x = 10;
|
||||
int _y = 790;
|
||||
int _w = 240 + (new_w - 800);
|
||||
int _h = 160 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
@@ -736,7 +824,7 @@ int main() {
|
||||
ScrollBox_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Splitter_001: anchors top, left, right, bottom
|
||||
int _x = 10;
|
||||
int _x = 200;
|
||||
int _y = 790;
|
||||
int _w = 280 + (new_w - 800);
|
||||
int _h = 160 + (new_h - 600);
|
||||
@@ -745,7 +833,7 @@ int main() {
|
||||
Splitter_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // StatusBar_001: anchors top, left, right, bottom
|
||||
int _x = 200;
|
||||
int _x = 390;
|
||||
int _y = 790;
|
||||
int _w = 320 + (new_w - 800);
|
||||
int _h = 24 + (new_h - 600);
|
||||
@@ -754,7 +842,7 @@ int main() {
|
||||
StatusBar_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // ToolBar_001: anchors top, left, right, bottom
|
||||
int _x = 390;
|
||||
int _x = 580;
|
||||
int _y = 790;
|
||||
int _w = 320 + (new_w - 800);
|
||||
int _h = 36 + (new_h - 600);
|
||||
@@ -763,8 +851,8 @@ int main() {
|
||||
ToolBar_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // MenuBar_001: anchors top, left, right, bottom
|
||||
int _x = 580;
|
||||
int _y = 790;
|
||||
int _x = 10;
|
||||
int _y = 920;
|
||||
int _w = 320 + (new_w - 800);
|
||||
int _h = 28 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
@@ -772,7 +860,7 @@ int main() {
|
||||
MenuBar_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // SpinEdit_001: anchors top, left, right, bottom
|
||||
int _x = 10;
|
||||
int _x = 200;
|
||||
int _y = 920;
|
||||
int _w = 120 + (new_w - 800);
|
||||
int _h = 28 + (new_h - 600);
|
||||
@@ -781,7 +869,7 @@ int main() {
|
||||
SpinEdit_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // TrackBar_001: anchors top, left, right, bottom
|
||||
int _x = 200;
|
||||
int _x = 390;
|
||||
int _y = 920;
|
||||
int _w = 160 + (new_w - 800);
|
||||
int _h = 28 + (new_h - 600);
|
||||
@@ -790,7 +878,7 @@ int main() {
|
||||
TrackBar_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // ProgressBar_001: anchors top, left, right, bottom
|
||||
int _x = 390;
|
||||
int _x = 580;
|
||||
int _y = 920;
|
||||
int _w = 200 + (new_w - 800);
|
||||
int _h = 24 + (new_h - 600);
|
||||
@@ -799,8 +887,8 @@ int main() {
|
||||
ProgressBar_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // DateTimePicker_001: anchors top, left, right, bottom
|
||||
int _x = 580;
|
||||
int _y = 920;
|
||||
int _x = 10;
|
||||
int _y = 1050;
|
||||
int _w = 240 + (new_w - 800);
|
||||
int _h = 200 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
@@ -808,7 +896,7 @@ int main() {
|
||||
DateTimePicker_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // ColorBox_001: anchors top, left, right, bottom
|
||||
int _x = 10;
|
||||
int _x = 200;
|
||||
int _y = 1050;
|
||||
int _w = 120 + (new_w - 800);
|
||||
int _h = 28 + (new_h - 600);
|
||||
@@ -817,7 +905,7 @@ int main() {
|
||||
ColorBox_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // ListView_001: anchors top, left, right, bottom
|
||||
int _x = 200;
|
||||
int _x = 390;
|
||||
int _y = 1050;
|
||||
int _w = 240 + (new_w - 800);
|
||||
int _h = 140 + (new_h - 600);
|
||||
@@ -826,7 +914,7 @@ int main() {
|
||||
ListView_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // TreeView_001: anchors top, left, right, bottom
|
||||
int _x = 390;
|
||||
int _x = 580;
|
||||
int _y = 1050;
|
||||
int _w = 240 + (new_w - 800);
|
||||
int _h = 140 + (new_h - 600);
|
||||
@@ -835,8 +923,8 @@ int main() {
|
||||
TreeView_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // StringGrid_001: anchors top, left, right, bottom
|
||||
int _x = 580;
|
||||
int _y = 1050;
|
||||
int _x = 10;
|
||||
int _y = 1180;
|
||||
int _w = 280 + (new_w - 800);
|
||||
int _h = 160 + (new_h - 600);
|
||||
if (_w < 24) _w = 24;
|
||||
@@ -844,7 +932,7 @@ int main() {
|
||||
StringGrid_001.set_bounds(_x, _y, _w, _h);
|
||||
}
|
||||
{ // Plot_001: anchors top, left, right, bottom
|
||||
int _x = 10;
|
||||
int _x = 200;
|
||||
int _y = 1180;
|
||||
int _w = 280 + (new_w - 800);
|
||||
int _h = 180 + (new_h - 600);
|
||||
|
||||
@@ -30,7 +30,7 @@ Close the window (or its close button) to quit.
|
||||
|
||||
## Notes
|
||||
|
||||
- Widgets: 64 placed. Each is constructed
|
||||
- Widgets: 107 placed. Each is constructed
|
||||
as its XFrame class (e.g. `GtkButton`) with the geometry and
|
||||
properties from the design; colours and state use the widgets'
|
||||
getter/setter API where one exists, otherwise a per-widget
|
||||
|
||||
+295
-2
@@ -4,7 +4,7 @@
|
||||
// or the generated Makefile (make). Both need the XFrame widget
|
||||
// sources; see LIGHTGUI_WIDGETS_DIR in CMakeLists.txt / Makefile.
|
||||
//
|
||||
// The window is "Main Window" (800x600) with 64 widget(s).
|
||||
// The window is "Main Window" (800x600) with 107 widget(s).
|
||||
|
||||
#include "common/registry.h"
|
||||
|
||||
@@ -41,14 +41,29 @@ int main() {
|
||||
Btn_relief_2.w.set_text("Btn_relief_2");
|
||||
lg::Holder<GtkFrame> Frm_shadow_0(display, screen, window, gc, &styles, 400, 10, 200, 120);
|
||||
Frm_shadow_0.w.set_label("Frm_shadow_0");
|
||||
Frm_shadow_0.w.set_label_xalign(0.0);
|
||||
Frm_shadow_0.w.set_inset(8);
|
||||
Frm_shadow_0.w.set_top_inset(14);
|
||||
lg::Holder<GtkFrame> Frm_shadow_1(display, screen, window, gc, &styles, 530, 10, 200, 120);
|
||||
Frm_shadow_1.w.set_label("Frm_shadow_1");
|
||||
Frm_shadow_1.w.set_label_xalign(0.0);
|
||||
Frm_shadow_1.w.set_inset(8);
|
||||
Frm_shadow_1.w.set_top_inset(14);
|
||||
lg::Holder<GtkFrame> Frm_shadow_2(display, screen, window, gc, &styles, 660, 10, 200, 120);
|
||||
Frm_shadow_2.w.set_label("Frm_shadow_2");
|
||||
Frm_shadow_2.w.set_label_xalign(0.0);
|
||||
Frm_shadow_2.w.set_inset(8);
|
||||
Frm_shadow_2.w.set_top_inset(14);
|
||||
lg::Holder<GtkFrame> Frm_shadow_3(display, screen, window, gc, &styles, 790, 10, 200, 120);
|
||||
Frm_shadow_3.w.set_label("Frm_shadow_3");
|
||||
Frm_shadow_3.w.set_label_xalign(0.0);
|
||||
Frm_shadow_3.w.set_inset(8);
|
||||
Frm_shadow_3.w.set_top_inset(14);
|
||||
lg::Holder<GtkFrame> Frm_shadow_4(display, screen, window, gc, &styles, 920, 10, 200, 120);
|
||||
Frm_shadow_4.w.set_label("Frm_shadow_4");
|
||||
Frm_shadow_4.w.set_label_xalign(0.0);
|
||||
Frm_shadow_4.w.set_inset(8);
|
||||
Frm_shadow_4.w.set_top_inset(14);
|
||||
lg::Holder<GtkListBox> Lst_sel_0(display, screen, window, gc, &styles, 1050, 10, 180, 110);
|
||||
Lst_sel_0.w.add_row("Item 1");
|
||||
Lst_sel_0.w.add_row("Item 2");
|
||||
@@ -267,7 +282,285 @@ int main() {
|
||||
Trk_ticks_3.w.set_draw_value(true);
|
||||
Trk_ticks_3.w.set_orientation_vertical(false);
|
||||
Trk_ticks_3.w.set_marks({0.0, 10.0, 20.0, 30.0, 40.0, 50.0, 60.0, 70.0, 80.0, 90.0, 100.0});
|
||||
std::vector<lg::IWidget*> widgets = { &Btn_relief_0, &Btn_relief_1, &Btn_relief_2, &Frm_shadow_0, &Frm_shadow_1, &Frm_shadow_2, &Frm_shadow_3, &Frm_shadow_4, &Lst_sel_0, &Lst_sel_1, &Lst_sel_2, &Lst_sel_3, &Mnu_dir_0, &Mnu_dir_1, &Mnu_dir_2, &Mnu_dir_3, &Mnu_dir_4, &Txt_wrap_0, &Txt_wrap_1, &Txt_wrap_2, &Txt_wrap_3, &Btn_kind_0, &Btn_kind_1, &Btn_kind_2, &Btn_kind_3, &Btn_kind_4, &Btn_kind_5, &Btn_kind_6, &Btn_kind_7, &Btn_kind_8, &Btn_kind_9, &Btn_layout_0, &Btn_layout_1, &Btn_layout_2, &Btn_layout_3, &Ent_align_0, &Ent_align_1, &Ent_align_2, &Ent_case_0, &Ent_case_1, &Ent_case_2, &Chk_align_0, &Chk_align_1, &Cmb_style_0, &Cmb_style_1, &Cmb_style_2, &Scl_ticks_0, &Scl_ticks_1, &Scl_ticks_2, &Scl_ticks_3, &Scr_orient_0, &Scr_orient_1, &Txt_scroll_0, &Txt_scroll_1, &Txt_scroll_2, &Txt_scroll_3, &Mem_scroll_0, &Mem_scroll_1, &Mem_scroll_2, &Mem_scroll_3, &Trk_ticks_0, &Trk_ticks_1, &Trk_ticks_2, &Trk_ticks_3 };
|
||||
lg::Holder<GtkListView> Lst_view_0(display, screen, window, gc, &styles, 8330, 10, 240, 140);
|
||||
Lst_view_0.w.add_item("Row 1,Value 1");
|
||||
Lst_view_0.w.add_item("Row 2,Value 2");
|
||||
Lst_view_0.w.set_view_style(0);
|
||||
Lst_view_0.w.set_grid_lines(false);
|
||||
Lst_view_0.w.set_row_select(true);
|
||||
Lst_view_0.w.set_multi_select(false);
|
||||
Lst_view_0.w.set_sort_type(0);
|
||||
lg::Holder<GtkListView> Lst_view_1(display, screen, window, gc, &styles, 8460, 10, 240, 140);
|
||||
Lst_view_1.w.add_item("Row 1,Value 1");
|
||||
Lst_view_1.w.add_item("Row 2,Value 2");
|
||||
Lst_view_1.w.set_view_style(1);
|
||||
Lst_view_1.w.set_grid_lines(false);
|
||||
Lst_view_1.w.set_row_select(true);
|
||||
Lst_view_1.w.set_multi_select(false);
|
||||
Lst_view_1.w.set_sort_type(0);
|
||||
lg::Holder<GtkListView> Lst_view_2(display, screen, window, gc, &styles, 8590, 10, 240, 140);
|
||||
Lst_view_2.w.add_item("Row 1,Value 1");
|
||||
Lst_view_2.w.add_item("Row 2,Value 2");
|
||||
Lst_view_2.w.set_view_style(2);
|
||||
Lst_view_2.w.set_grid_lines(false);
|
||||
Lst_view_2.w.set_row_select(true);
|
||||
Lst_view_2.w.set_multi_select(false);
|
||||
Lst_view_2.w.set_sort_type(0);
|
||||
lg::Holder<GtkListView> Lst_view_3(display, screen, window, gc, &styles, 8720, 10, 240, 140);
|
||||
Lst_view_3.w.add_item("Row 1,Value 1");
|
||||
Lst_view_3.w.add_item("Row 2,Value 2");
|
||||
Lst_view_3.w.set_view_style(3);
|
||||
Lst_view_3.w.set_grid_lines(false);
|
||||
Lst_view_3.w.set_row_select(true);
|
||||
Lst_view_3.w.set_multi_select(false);
|
||||
Lst_view_3.w.set_sort_type(0);
|
||||
lg::Holder<GtkListView> Lst_sort_0(display, screen, window, gc, &styles, 8850, 10, 240, 140);
|
||||
Lst_sort_0.w.add_item("Row 1,Value 1");
|
||||
Lst_sort_0.w.add_item("Row 2,Value 2");
|
||||
Lst_sort_0.w.set_view_style(0);
|
||||
Lst_sort_0.w.set_grid_lines(false);
|
||||
Lst_sort_0.w.set_row_select(true);
|
||||
Lst_sort_0.w.set_multi_select(false);
|
||||
Lst_sort_0.w.set_sort_type(0);
|
||||
lg::Holder<GtkListView> Lst_sort_1(display, screen, window, gc, &styles, 8980, 10, 240, 140);
|
||||
Lst_sort_1.w.add_item("Row 1,Value 1");
|
||||
Lst_sort_1.w.add_item("Row 2,Value 2");
|
||||
Lst_sort_1.w.set_view_style(0);
|
||||
Lst_sort_1.w.set_grid_lines(false);
|
||||
Lst_sort_1.w.set_row_select(true);
|
||||
Lst_sort_1.w.set_multi_select(false);
|
||||
Lst_sort_1.w.set_sort_type(1);
|
||||
lg::Holder<GtkListView> Lst_sort_2(display, screen, window, gc, &styles, 9110, 10, 240, 140);
|
||||
Lst_sort_2.w.add_item("Row 1,Value 1");
|
||||
Lst_sort_2.w.add_item("Row 2,Value 2");
|
||||
Lst_sort_2.w.set_view_style(0);
|
||||
Lst_sort_2.w.set_grid_lines(false);
|
||||
Lst_sort_2.w.set_row_select(true);
|
||||
Lst_sort_2.w.set_multi_select(false);
|
||||
Lst_sort_2.w.set_sort_type(2);
|
||||
lg::Holder<GtkTreeView> Tre_sort_0(display, screen, window, gc, &styles, 9240, 10, 240, 140);
|
||||
Tre_sort_0.w.set_roots({GtkTreeView::Node{{"Root"}, {GtkTreeView::Node{{"Child 1"}, {}, true}}, true}, GtkTreeView::Node{{"Root"}, {GtkTreeView::Node{{"Child 2"}, {}, true}}, true}, GtkTreeView::Node{{"Other"}, {}, true}});
|
||||
Tre_sort_0.w.set_header_height(22);
|
||||
Tre_sort_0.w.set_headers_visible(true);
|
||||
Tre_sort_0.w.set_grid_lines(false);
|
||||
Tre_sort_0.w.set_row_select(true);
|
||||
Tre_sort_0.w.set_multi_select(false);
|
||||
Tre_sort_0.w.set_sort_type(0);
|
||||
Tre_sort_0.w.set_indent(16);
|
||||
Tre_sort_0.w.set_show_buttons(true);
|
||||
Tre_sort_0.w.set_show_lines(true);
|
||||
Tre_sort_0.w.set_show_root(true);
|
||||
lg::Holder<GtkTreeView> Tre_sort_1(display, screen, window, gc, &styles, 9370, 10, 240, 140);
|
||||
Tre_sort_1.w.set_roots({GtkTreeView::Node{{"Root"}, {GtkTreeView::Node{{"Child 1"}, {}, true}}, true}, GtkTreeView::Node{{"Root"}, {GtkTreeView::Node{{"Child 2"}, {}, true}}, true}, GtkTreeView::Node{{"Other"}, {}, true}});
|
||||
Tre_sort_1.w.set_header_height(22);
|
||||
Tre_sort_1.w.set_headers_visible(true);
|
||||
Tre_sort_1.w.set_grid_lines(false);
|
||||
Tre_sort_1.w.set_row_select(true);
|
||||
Tre_sort_1.w.set_multi_select(false);
|
||||
Tre_sort_1.w.set_sort_type(1);
|
||||
Tre_sort_1.w.set_indent(16);
|
||||
Tre_sort_1.w.set_show_buttons(true);
|
||||
Tre_sort_1.w.set_show_lines(true);
|
||||
Tre_sort_1.w.set_show_root(true);
|
||||
lg::Holder<GtkTreeView> Tre_sort_2(display, screen, window, gc, &styles, 9500, 10, 240, 140);
|
||||
Tre_sort_2.w.set_roots({GtkTreeView::Node{{"Root"}, {GtkTreeView::Node{{"Child 1"}, {}, true}}, true}, GtkTreeView::Node{{"Root"}, {GtkTreeView::Node{{"Child 2"}, {}, true}}, true}, GtkTreeView::Node{{"Other"}, {}, true}});
|
||||
Tre_sort_2.w.set_header_height(22);
|
||||
Tre_sort_2.w.set_headers_visible(true);
|
||||
Tre_sort_2.w.set_grid_lines(false);
|
||||
Tre_sort_2.w.set_row_select(true);
|
||||
Tre_sort_2.w.set_multi_select(false);
|
||||
Tre_sort_2.w.set_sort_type(2);
|
||||
Tre_sort_2.w.set_indent(16);
|
||||
Tre_sort_2.w.set_show_buttons(true);
|
||||
Tre_sort_2.w.set_show_lines(true);
|
||||
Tre_sort_2.w.set_show_root(true);
|
||||
lg::Holder<GtkNotebook> Nbk_pos_0(display, screen, window, gc, &styles, 9630, 10, 320, 200);
|
||||
Nbk_pos_0.w.append_page("Tab 1");
|
||||
Nbk_pos_0.w.append_page("Tab 2");
|
||||
Nbk_pos_0.w.append_page("Tab 3");
|
||||
Nbk_pos_0.w.set_current_page(0);
|
||||
Nbk_pos_0.w.set_tab_height(26);
|
||||
Nbk_pos_0.w.set_tab_position(0);
|
||||
lg::Holder<GtkNotebook> Nbk_pos_1(display, screen, window, gc, &styles, 9760, 10, 320, 200);
|
||||
Nbk_pos_1.w.append_page("Tab 1");
|
||||
Nbk_pos_1.w.append_page("Tab 2");
|
||||
Nbk_pos_1.w.append_page("Tab 3");
|
||||
Nbk_pos_1.w.set_current_page(0);
|
||||
Nbk_pos_1.w.set_tab_height(26);
|
||||
Nbk_pos_1.w.set_tab_position(1);
|
||||
lg::Holder<GtkNotebook> Nbk_pos_2(display, screen, window, gc, &styles, 9890, 10, 320, 200);
|
||||
Nbk_pos_2.w.append_page("Tab 1");
|
||||
Nbk_pos_2.w.append_page("Tab 2");
|
||||
Nbk_pos_2.w.append_page("Tab 3");
|
||||
Nbk_pos_2.w.set_current_page(0);
|
||||
Nbk_pos_2.w.set_tab_height(26);
|
||||
Nbk_pos_2.w.set_tab_position(2);
|
||||
lg::Holder<GtkNotebook> Nbk_pos_3(display, screen, window, gc, &styles, 10020, 10, 320, 200);
|
||||
Nbk_pos_3.w.append_page("Tab 1");
|
||||
Nbk_pos_3.w.append_page("Tab 2");
|
||||
Nbk_pos_3.w.append_page("Tab 3");
|
||||
Nbk_pos_3.w.set_current_page(0);
|
||||
Nbk_pos_3.w.set_tab_height(26);
|
||||
Nbk_pos_3.w.set_tab_position(3);
|
||||
lg::Holder<GtkPaned> Spl_rs_0(display, screen, window, gc, &styles, 10150, 10, 280, 160);
|
||||
Spl_rs_0.w.set_position(100);
|
||||
Spl_rs_0.w.set_orientation(0);
|
||||
Spl_rs_0.w.set_resize_style(0);
|
||||
Spl_rs_0.w.set_auto_snap(false);
|
||||
lg::Holder<GtkPaned> Spl_rs_1(display, screen, window, gc, &styles, 10280, 10, 280, 160);
|
||||
Spl_rs_1.w.set_position(100);
|
||||
Spl_rs_1.w.set_orientation(0);
|
||||
Spl_rs_1.w.set_resize_style(1);
|
||||
Spl_rs_1.w.set_auto_snap(false);
|
||||
lg::Holder<GtkColorButton> Clr_style_0(display, screen, window, gc, &styles, 10410, 10, 120, 28);
|
||||
Clr_style_0.w.set_color_rgb(53, 132, 228);
|
||||
Clr_style_0.w.set_style(0);
|
||||
Clr_style_0.w.set_default_color_rgb(255, 255, 255);
|
||||
Clr_style_0.w.set_none_color_rgb(0, 0, 0);
|
||||
lg::Holder<GtkColorButton> Clr_style_1(display, screen, window, gc, &styles, 10540, 10, 120, 28);
|
||||
Clr_style_1.w.set_color_rgb(53, 132, 228);
|
||||
Clr_style_1.w.set_style(1);
|
||||
Clr_style_1.w.set_default_color_rgb(255, 255, 255);
|
||||
Clr_style_1.w.set_none_color_rgb(0, 0, 0);
|
||||
lg::Holder<GtkColorButton> Clr_style_2(display, screen, window, gc, &styles, 10670, 10, 120, 28);
|
||||
Clr_style_2.w.set_color_rgb(53, 132, 228);
|
||||
Clr_style_2.w.set_style(2);
|
||||
Clr_style_2.w.set_default_color_rgb(255, 255, 255);
|
||||
Clr_style_2.w.set_none_color_rgb(0, 0, 0);
|
||||
lg::Holder<GtkColorButton> Clr_style_3(display, screen, window, gc, &styles, 10800, 10, 120, 28);
|
||||
Clr_style_3.w.set_color_rgb(53, 132, 228);
|
||||
Clr_style_3.w.set_style(3);
|
||||
Clr_style_3.w.set_default_color_rgb(255, 255, 255);
|
||||
Clr_style_3.w.set_none_color_rgb(0, 0, 0);
|
||||
lg::Holder<TShape> Shp_shape_0(display, screen, window, gc, &styles, 10930, 10, 160, 120);
|
||||
Shp_shape_0.w.set_shape(0);
|
||||
Shp_shape_0.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_0.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_0.w.set_pen_width(2);
|
||||
lg::Holder<TShape> Shp_shape_1(display, screen, window, gc, &styles, 11060, 10, 160, 120);
|
||||
Shp_shape_1.w.set_shape(1);
|
||||
Shp_shape_1.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_1.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_1.w.set_pen_width(2);
|
||||
lg::Holder<TShape> Shp_shape_2(display, screen, window, gc, &styles, 11190, 10, 160, 120);
|
||||
Shp_shape_2.w.set_shape(2);
|
||||
Shp_shape_2.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_2.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_2.w.set_pen_width(2);
|
||||
lg::Holder<TShape> Shp_shape_3(display, screen, window, gc, &styles, 11320, 10, 160, 120);
|
||||
Shp_shape_3.w.set_shape(3);
|
||||
Shp_shape_3.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_3.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_3.w.set_pen_width(2);
|
||||
lg::Holder<TShape> Shp_shape_4(display, screen, window, gc, &styles, 11450, 10, 160, 120);
|
||||
Shp_shape_4.w.set_shape(4);
|
||||
Shp_shape_4.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_4.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_4.w.set_pen_width(2);
|
||||
lg::Holder<TShape> Shp_shape_5(display, screen, window, gc, &styles, 11580, 10, 160, 120);
|
||||
Shp_shape_5.w.set_shape(5);
|
||||
Shp_shape_5.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_5.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_5.w.set_pen_width(2);
|
||||
lg::Holder<TShape> Shp_shape_6(display, screen, window, gc, &styles, 11710, 10, 160, 120);
|
||||
Shp_shape_6.w.set_shape(6);
|
||||
Shp_shape_6.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_6.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_6.w.set_pen_width(2);
|
||||
lg::Holder<TShape> Shp_shape_7(display, screen, window, gc, &styles, 11840, 10, 160, 120);
|
||||
Shp_shape_7.w.set_shape(7);
|
||||
Shp_shape_7.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_7.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_7.w.set_pen_width(2);
|
||||
lg::Holder<TShape> Shp_shape_8(display, screen, window, gc, &styles, 11970, 10, 160, 120);
|
||||
Shp_shape_8.w.set_shape(8);
|
||||
Shp_shape_8.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_8.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_8.w.set_pen_width(2);
|
||||
lg::Holder<TShape> Shp_shape_9(display, screen, window, gc, &styles, 12100, 10, 160, 120);
|
||||
Shp_shape_9.w.set_shape(9);
|
||||
Shp_shape_9.w.set_fill_color(Srgb{70, 130, 200});
|
||||
Shp_shape_9.w.set_pen_color(Srgb{20, 40, 80});
|
||||
Shp_shape_9.w.set_pen_width(2);
|
||||
lg::Holder<GtkWindow> Top_border_0(display, screen, window, gc, &styles, 12230, 10, 300, 200);
|
||||
Top_border_0.w.set_title("Top_border_0");
|
||||
Top_border_0.w.set_resizable(true);
|
||||
Top_border_0.w.set_border_style(0);
|
||||
Top_border_0.w.set_position(0);
|
||||
Top_border_0.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_border_1(display, screen, window, gc, &styles, 12360, 10, 300, 200);
|
||||
Top_border_1.w.set_title("Top_border_1");
|
||||
Top_border_1.w.set_resizable(true);
|
||||
Top_border_1.w.set_border_style(1);
|
||||
Top_border_1.w.set_position(0);
|
||||
Top_border_1.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_border_2(display, screen, window, gc, &styles, 12490, 10, 300, 200);
|
||||
Top_border_2.w.set_title("Top_border_2");
|
||||
Top_border_2.w.set_resizable(true);
|
||||
Top_border_2.w.set_border_style(2);
|
||||
Top_border_2.w.set_position(0);
|
||||
Top_border_2.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_border_3(display, screen, window, gc, &styles, 12620, 10, 300, 200);
|
||||
Top_border_3.w.set_title("Top_border_3");
|
||||
Top_border_3.w.set_resizable(true);
|
||||
Top_border_3.w.set_border_style(3);
|
||||
Top_border_3.w.set_position(0);
|
||||
Top_border_3.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_pos_0(display, screen, window, gc, &styles, 12750, 10, 300, 200);
|
||||
Top_pos_0.w.set_title("Top_pos_0");
|
||||
Top_pos_0.w.set_resizable(true);
|
||||
Top_pos_0.w.set_border_style(0);
|
||||
Top_pos_0.w.set_position(0);
|
||||
Top_pos_0.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_pos_1(display, screen, window, gc, &styles, 12880, 10, 300, 200);
|
||||
Top_pos_1.w.set_title("Top_pos_1");
|
||||
Top_pos_1.w.set_resizable(true);
|
||||
Top_pos_1.w.set_border_style(0);
|
||||
Top_pos_1.w.set_position(1);
|
||||
Top_pos_1.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_pos_2(display, screen, window, gc, &styles, 13010, 10, 300, 200);
|
||||
Top_pos_2.w.set_title("Top_pos_2");
|
||||
Top_pos_2.w.set_resizable(true);
|
||||
Top_pos_2.w.set_border_style(0);
|
||||
Top_pos_2.w.set_position(2);
|
||||
Top_pos_2.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_pos_3(display, screen, window, gc, &styles, 13140, 10, 300, 200);
|
||||
Top_pos_3.w.set_title("Top_pos_3");
|
||||
Top_pos_3.w.set_resizable(true);
|
||||
Top_pos_3.w.set_border_style(0);
|
||||
Top_pos_3.w.set_position(3);
|
||||
Top_pos_3.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_pos_4(display, screen, window, gc, &styles, 13270, 10, 300, 200);
|
||||
Top_pos_4.w.set_title("Top_pos_4");
|
||||
Top_pos_4.w.set_resizable(true);
|
||||
Top_pos_4.w.set_border_style(0);
|
||||
Top_pos_4.w.set_position(4);
|
||||
Top_pos_4.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_state_0(display, screen, window, gc, &styles, 13400, 10, 300, 200);
|
||||
Top_state_0.w.set_title("Top_state_0");
|
||||
Top_state_0.w.set_resizable(true);
|
||||
Top_state_0.w.set_border_style(0);
|
||||
Top_state_0.w.set_position(0);
|
||||
Top_state_0.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Top_state_1(display, screen, window, gc, &styles, 13530, 10, 300, 200);
|
||||
Top_state_1.w.set_title("Top_state_1");
|
||||
Top_state_1.w.set_resizable(true);
|
||||
Top_state_1.w.set_border_style(0);
|
||||
Top_state_1.w.set_position(0);
|
||||
Top_state_1.w.set_window_state(1);
|
||||
lg::Holder<GtkWindow> Top_state_2(display, screen, window, gc, &styles, 13660, 10, 300, 200);
|
||||
Top_state_2.w.set_title("Top_state_2");
|
||||
Top_state_2.w.set_resizable(true);
|
||||
Top_state_2.w.set_border_style(0);
|
||||
Top_state_2.w.set_position(0);
|
||||
Top_state_2.w.set_window_state(2);
|
||||
lg::Holder<GtkWindow> Top_state_3(display, screen, window, gc, &styles, 13790, 10, 300, 200);
|
||||
Top_state_3.w.set_title("Top_state_3");
|
||||
Top_state_3.w.set_resizable(true);
|
||||
Top_state_3.w.set_border_style(0);
|
||||
Top_state_3.w.set_position(0);
|
||||
Top_state_3.w.set_window_state(3);
|
||||
std::vector<lg::IWidget*> widgets = { &Btn_relief_0, &Btn_relief_1, &Btn_relief_2, &Frm_shadow_0, &Frm_shadow_1, &Frm_shadow_2, &Frm_shadow_3, &Frm_shadow_4, &Lst_sel_0, &Lst_sel_1, &Lst_sel_2, &Lst_sel_3, &Mnu_dir_0, &Mnu_dir_1, &Mnu_dir_2, &Mnu_dir_3, &Mnu_dir_4, &Txt_wrap_0, &Txt_wrap_1, &Txt_wrap_2, &Txt_wrap_3, &Btn_kind_0, &Btn_kind_1, &Btn_kind_2, &Btn_kind_3, &Btn_kind_4, &Btn_kind_5, &Btn_kind_6, &Btn_kind_7, &Btn_kind_8, &Btn_kind_9, &Btn_layout_0, &Btn_layout_1, &Btn_layout_2, &Btn_layout_3, &Ent_align_0, &Ent_align_1, &Ent_align_2, &Ent_case_0, &Ent_case_1, &Ent_case_2, &Chk_align_0, &Chk_align_1, &Cmb_style_0, &Cmb_style_1, &Cmb_style_2, &Scl_ticks_0, &Scl_ticks_1, &Scl_ticks_2, &Scl_ticks_3, &Scr_orient_0, &Scr_orient_1, &Txt_scroll_0, &Txt_scroll_1, &Txt_scroll_2, &Txt_scroll_3, &Mem_scroll_0, &Mem_scroll_1, &Mem_scroll_2, &Mem_scroll_3, &Trk_ticks_0, &Trk_ticks_1, &Trk_ticks_2, &Trk_ticks_3, &Lst_view_0, &Lst_view_1, &Lst_view_2, &Lst_view_3, &Lst_sort_0, &Lst_sort_1, &Lst_sort_2, &Tre_sort_0, &Tre_sort_1, &Tre_sort_2, &Nbk_pos_0, &Nbk_pos_1, &Nbk_pos_2, &Nbk_pos_3, &Spl_rs_0, &Spl_rs_1, &Clr_style_0, &Clr_style_1, &Clr_style_2, &Clr_style_3, &Shp_shape_0, &Shp_shape_1, &Shp_shape_2, &Shp_shape_3, &Shp_shape_4, &Shp_shape_5, &Shp_shape_6, &Shp_shape_7, &Shp_shape_8, &Shp_shape_9, &Top_border_0, &Top_border_1, &Top_border_2, &Top_border_3, &Top_pos_0, &Top_pos_1, &Top_pos_2, &Top_pos_3, &Top_pos_4, &Top_state_0, &Top_state_1, &Top_state_2, &Top_state_3 };
|
||||
auto redraw_all = [&]() {
|
||||
XClearWindow(display, window);
|
||||
for (lg::IWidget* wd : widgets) wd->draw();
|
||||
|
||||
@@ -35,18 +35,33 @@ int main() {
|
||||
styles.set_active_style_byName("default");
|
||||
lg::Holder<XSpreadsheet> Spreadsheet_001(display, screen, window, gc, &styles, 10, 10, 900, 500);
|
||||
Spreadsheet_001.w.set_size(26, 50);
|
||||
Spreadsheet_001.w.set_default_col_width(84);
|
||||
Spreadsheet_001.w.set_row_height(20);
|
||||
Spreadsheet_001.w.set_grid_line_width(1);
|
||||
// NOTE (model-only, no XFrame setter): columns=26
|
||||
lg::Holder<XSpreadsheet> Spreadsheet_002(display, screen, window, gc, &styles, 10, 520, 320, 180);
|
||||
Spreadsheet_002.w.set_size(1, 1);
|
||||
Spreadsheet_002.w.set_default_col_width(84);
|
||||
Spreadsheet_002.w.set_row_height(20);
|
||||
Spreadsheet_002.w.set_grid_line_width(1);
|
||||
lg::Holder<GtkWindow> Toplevel_001(display, screen, window, gc, &styles, 100, 100, 300, 200);
|
||||
Toplevel_001.w.set_title("Window 1");
|
||||
Toplevel_001.w.set_resizable(true);
|
||||
Toplevel_001.w.set_border_style(0);
|
||||
Toplevel_001.w.set_position(0);
|
||||
Toplevel_001.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Toplevel_002(display, screen, window, gc, &styles, 200, 200, 300, 200);
|
||||
Toplevel_002.w.set_title("Window 2");
|
||||
Toplevel_002.w.set_resizable(false);
|
||||
Toplevel_002.w.set_border_style(0);
|
||||
Toplevel_002.w.set_position(0);
|
||||
Toplevel_002.w.set_window_state(0);
|
||||
lg::Holder<GtkWindow> Toplevel_003(display, screen, window, gc, &styles, 300, 300, 300, 200);
|
||||
Toplevel_003.w.set_title("Window 3");
|
||||
Toplevel_003.w.set_resizable(true);
|
||||
Toplevel_003.w.set_border_style(0);
|
||||
Toplevel_003.w.set_position(0);
|
||||
Toplevel_003.w.set_window_state(0);
|
||||
std::vector<lg::IWidget*> widgets = { &Spreadsheet_001, &Spreadsheet_002, &Toplevel_001, &Toplevel_002, &Toplevel_003 };
|
||||
auto redraw_all = [&]() {
|
||||
XClearWindow(display, window);
|
||||
|
||||
@@ -51,6 +51,9 @@ int main() {
|
||||
Checkbutton_004.w.set_inconsistent(false);
|
||||
lg::Holder<GtkFrame> Frame_005(display, screen, window, gc, &styles, 690, 10, 200, 120);
|
||||
Frame_005.w.set_label("Frame_005");
|
||||
Frame_005.w.set_label_xalign(0.0);
|
||||
Frame_005.w.set_inset(8);
|
||||
Frame_005.w.set_top_inset(14);
|
||||
lg::Holder<GtkComboBoxText> Combobox_006(display, screen, window, gc, &styles, 10, 80, 160, 28);
|
||||
Combobox_006.w.append_text("Item 1");
|
||||
Combobox_006.w.append_text("Item 2");
|
||||
@@ -81,6 +84,9 @@ int main() {
|
||||
Checkbutton_012.w.set_inconsistent(false);
|
||||
lg::Holder<GtkFrame> Frame_013(display, screen, window, gc, &styles, 350, 150, 200, 120);
|
||||
Frame_013.w.set_label("Frame_013");
|
||||
Frame_013.w.set_label_xalign(0.0);
|
||||
Frame_013.w.set_inset(8);
|
||||
Frame_013.w.set_top_inset(14);
|
||||
lg::Holder<GtkComboBoxText> Combobox_014(display, screen, window, gc, &styles, 520, 150, 160, 28);
|
||||
Combobox_014.w.append_text("Item 1");
|
||||
Combobox_014.w.append_text("Item 2");
|
||||
@@ -111,6 +117,9 @@ int main() {
|
||||
Checkbutton_020.w.set_inconsistent(false);
|
||||
lg::Holder<GtkFrame> Frame_021(display, screen, window, gc, &styles, 10, 290, 200, 120);
|
||||
Frame_021.w.set_label("Frame_021");
|
||||
Frame_021.w.set_label_xalign(0.0);
|
||||
Frame_021.w.set_inset(8);
|
||||
Frame_021.w.set_top_inset(14);
|
||||
lg::Holder<GtkComboBoxText> Combobox_022(display, screen, window, gc, &styles, 180, 290, 160, 28);
|
||||
Combobox_022.w.append_text("Item 1");
|
||||
Combobox_022.w.append_text("Item 2");
|
||||
@@ -141,6 +150,9 @@ int main() {
|
||||
Checkbutton_028.w.set_inconsistent(false);
|
||||
lg::Holder<GtkFrame> Frame_029(display, screen, window, gc, &styles, 520, 360, 200, 120);
|
||||
Frame_029.w.set_label("Frame_029");
|
||||
Frame_029.w.set_label_xalign(0.0);
|
||||
Frame_029.w.set_inset(8);
|
||||
Frame_029.w.set_top_inset(14);
|
||||
lg::Holder<GtkComboBoxText> Combobox_030(display, screen, window, gc, &styles, 690, 360, 160, 28);
|
||||
Combobox_030.w.append_text("Item 1");
|
||||
Combobox_030.w.append_text("Item 2");
|
||||
@@ -171,6 +183,9 @@ int main() {
|
||||
Checkbutton_036.w.set_inconsistent(false);
|
||||
lg::Holder<GtkFrame> Frame_037(display, screen, window, gc, &styles, 180, 500, 200, 120);
|
||||
Frame_037.w.set_label("Frame_037");
|
||||
Frame_037.w.set_label_xalign(0.0);
|
||||
Frame_037.w.set_inset(8);
|
||||
Frame_037.w.set_top_inset(14);
|
||||
lg::Holder<GtkComboBoxText> Combobox_038(display, screen, window, gc, &styles, 350, 500, 160, 28);
|
||||
Combobox_038.w.append_text("Item 1");
|
||||
Combobox_038.w.append_text("Item 2");
|
||||
|
||||
@@ -295,6 +295,97 @@ fn build_cases() -> Vec<(String, Project)> {
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
// Phase 3 enums: every value of every new enum prop.
|
||||
for v in 0..=3 {
|
||||
add(
|
||||
&mut p,
|
||||
"ListView",
|
||||
format!("Lst_view_{v}"),
|
||||
"view-style",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
for v in 0..=2 {
|
||||
add(
|
||||
&mut p,
|
||||
"ListView",
|
||||
format!("Lst_sort_{v}"),
|
||||
"sort-type",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
for v in 0..=2 {
|
||||
add(
|
||||
&mut p,
|
||||
"TreeView",
|
||||
format!("Tre_sort_{v}"),
|
||||
"sort-type",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
for v in 0..=3 {
|
||||
add(
|
||||
&mut p,
|
||||
"Notebook",
|
||||
format!("Nbk_pos_{v}"),
|
||||
"tab-position",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
for v in 0..=1 {
|
||||
add(
|
||||
&mut p,
|
||||
"Splitter",
|
||||
format!("Spl_rs_{v}"),
|
||||
"resize-style",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
for v in 0..=3 {
|
||||
add(
|
||||
&mut p,
|
||||
"ColorBox",
|
||||
format!("Clr_style_{v}"),
|
||||
"style",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
for v in 0..=9 {
|
||||
add(
|
||||
&mut p,
|
||||
"Shape",
|
||||
format!("Shp_shape_{v}"),
|
||||
"shape",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
for v in 0..=3 {
|
||||
add(
|
||||
&mut p,
|
||||
"Toplevel",
|
||||
format!("Top_border_{v}"),
|
||||
"border-style",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
for v in 0..=4 {
|
||||
add(
|
||||
&mut p,
|
||||
"Toplevel",
|
||||
format!("Top_pos_{v}"),
|
||||
"position",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
for v in 0..=3 {
|
||||
add(
|
||||
&mut p,
|
||||
"Toplevel",
|
||||
format!("Top_state_{v}"),
|
||||
"window-state",
|
||||
&v.to_string(),
|
||||
);
|
||||
}
|
||||
cases.push(("04_enum_values".to_string(), p));
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user