// my vars (def)
public bool loading;
public string prop_selected;
- public bool allow_node_scroll;
public Gtk.CssProvider css;
+ public bool allow_node_scroll;
public JsRender.Node? node_selected;
// ctor
"* pack" : "pack_start,false,false,4",
"bool hexpand" : true,
"id" : "grid",
- "int margin_left" : 4,
- "int margin_right" : 4,
+ "int margin_end" : 4,
+ "int margin_start" : 4,
"items" : [
{
"$ justify" : "Gtk.Justification.RIGHT",
"* pack" : "add",
"Gtk.Orientation orientation" : "Gtk.Orientation.HORIZONTAL",
"int margin_bottom" : 4,
- "int margin_left" : 4,
- "int margin_right" : 4,
+ "int margin_end" : 4,
+ "int margin_start" : 4,
"int margin_top" : 4,
"items" : [
{
// my vars (dec)
// set gobject values
- this.el.margin_right = 4;
- this.el.margin_left = 4;
+ this.el.margin_end = 4;
+ this.el.margin_start = 4;
this.el.hexpand = true;
this.el.row_spacing = 2;
var child_0 = new Xcls_filetypelbl( _this );
// my vars (dec)
// set gobject values
- this.el.margin_right = 4;
- this.el.margin_left = 4;
+ this.el.margin_end = 4;
+ this.el.margin_start = 4;
this.el.margin_bottom = 4;
this.el.margin_top = 4;
var child_0 = new Xcls_Button32( _this );
}
],
"listeners" : {
- "pressed" : [
+ "button_press_event" : [
"() => { ",
"",
"\t_this.prop = null;",
"\t_this.is_new = false;",
"\t_this.kname.el.set_text(\"Cancel\");",
"\t_this.el.hide();",
- "",
+ "\treturn false;",
"}"
]
},
}
],
"listeners" : {
- "pressed" : [
+ "button_press_event" : [
"() => {",
"\t// check if text is not empty..",
"\tif ( _this.kname.el.get_text().strip().length < 1) {",
"\t\t// error should already be showing?",
- "\t\treturn;",
+ "\t\treturn false;",
"\t}",
"\t_this.updateProp();",
"\t",
"\tvar prop = _this.prop;",
"\tif (_this.node.props.has_key(prop.to_index_key())) {",
"\t\t_this.error.setError(\"Property already exists\");",
- "\t\treturn;\t",
+ "\t\treturn false;\t",
"\t}",
"\t",
"\t",
"\t",
"\t_this.mainwindow.windowstate.left_props.addProp(prop);\t\t",
"\t",
- "",
+ "\treturn false;",
"}"
]
},
this.el.image = child_0.el;
//listeners
- this.el.pressed.connect( () => {
+ this.el.button_press_event.connect( () => {
_this.prop = null;
_this.is_new = false;
_this.kname.el.set_text("Cancel");
_this.el.hide();
-
+ return false;
});
}
this.el.image = child_0.el;
//listeners
- this.el.pressed.connect( () => {
+ this.el.button_press_event.connect( () => {
// check if text is not empty..
if ( _this.kname.el.get_text().strip().length < 1) {
// error should already be showing?
- return;
+ return false;
}
_this.updateProp();
var prop = _this.prop;
if (_this.node.props.has_key(prop.to_index_key())) {
_this.error.setError("Property already exists");
- return;
+ return false;
}
_this.mainwindow.windowstate.left_props.addProp(prop);
-
+ return false;
});
}
"$ xns" : "Gtk",
"* init" : [
"{",
- " var description = new Pango.FontDescription();",
- " description.set_size(10000);",
- " this.el.override_font(description);",
- "",
+ " this.css = new Gtk.CssProvider();",
+ "\ttry {",
+ "\t\tthis.css.load_from_data(\"#compile-erros-view { font-size: 10px;}\");",
+ "\t} catch (Error e) {}",
+ "\tthis.el.get_style_context().add_provider(this.css,",
+ "\t\tGtk.STYLE_PROVIDER_PRIORITY_APPLICATION);",
+ "\t ",
+ "\t ",
"}",
""
],
"* pack" : "add",
+ "Gtk.CssProvider css" : "",
"id" : "compile_tree",
"items" : [
{
" "
]
},
+ "string name" : "compile-erros-view",
"xtype" : "TreeView"
}
],
// my vars (def)
+ public Gtk.CssProvider css;
// ctor
public Xcls_compile_tree(Xcls_ValaCompileErrors _owner )
// my vars (dec)
// set gobject values
+ this.el.name = "compile-erros-view";
var child_0 = new Xcls_compile_result_store( _this );
child_0.ref();
this.el.set_model ( child_0.el );
// init method
{
- var description = new Pango.FontDescription();
- description.set_size(10000);
- this.el.override_font(description);
-
+ this.css = new Gtk.CssProvider();
+ try {
+ this.css.load_from_data("#compile-erros-view { font-size: 10px;}");
+ } catch (Error e) {}
+ this.el.get_style_context().add_provider(this.css,
+ Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
+
+
}
//listeners
"* init" : [
"{",
"",
- " var description = Pango.FontDescription.from_string(\"monospace\");",
- " description.set_size(8000);",
- " this.el.override_font(description);",
- "",
+ " \tthis.css = new Gtk.CssProvider();",
+ "\ttry {",
+ "\t\tthis.css.load_from_data(\"#compile-results-view { font: 10px Monospace;}\");",
+ "\t} catch (Error e) {}",
+ "\tthis.el.get_style_context().add_provider(this.css,",
+ "\t\tGtk.STYLE_PROVIDER_PRIORITY_APPLICATION);",
+ "\t ",
"",
"}",
""
],
"* pack" : "add",
+ "Gtk.CssProvider css" : "",
"bool editable" : false,
"bool show_line_numbers" : false,
"id" : "sourceview",
+ "string name" : "compile-results-view",
"xtype" : "SourceView"
}
],
// my vars (def)
+ public Gtk.CssProvider css;
// ctor
public Xcls_sourceview(Xcls_ValaCompileResults _owner )
// my vars (dec)
// set gobject values
+ this.el.name = "compile-results-view";
this.el.editable = false;
this.el.show_line_numbers = false;
{
- var description = Pango.FontDescription.from_string("monospace");
- description.set_size(8000);
- this.el.override_font(description);
-
+ this.css = new Gtk.CssProvider();
+ try {
+ this.css.load_from_data("#compile-results-view { font: 10px Monospace;}");
+ } catch (Error e) {}
+ this.el.get_style_context().add_provider(this.css,
+ Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
+
}
}
" ",
" _this.default_directory_menu.el.set_screen(Gdk.Screen.get_default());",
" _this.default_directory_menu.el.show_all();",
- " _this.default_directory_menu.el.popup(null, null, null, 3, ev.time);",
+ " _this.default_directory_menu.el.popup_at_pointer(ev);",
" // print(\"click:\" + res.path.to_string());",
" return true;",
"}"
" ",
" _this.targets_tree_menu.el.set_screen(Gdk.Screen.get_default());",
" _this.targets_tree_menu.el.show_all();",
- " _this.targets_tree_menu.el.popup(null, null, null, 3, ev.time);",
+ " _this.targets_tree_menu.el.popup_at_pointer(ev);",
" // print(\"click:\" + res.path.to_string());",
" return true;",
"}"
"xtype" : "Notebook"
},
{
+ "$ Gtk.Orientation orientation" : "Gtk.Orientation.HORIZONTAL",
"$ xns" : "Gtk",
"* pack" : "add",
"int margin_bottom" : 4,
- "int margin_left" : 4,
- "int margin_right" : 4,
+ "int margin_end" : 4,
+ "int margin_start" : 4,
"int margin_top" : 4,
"items" : [
{
"xtype" : "Button"
}
],
- "xtype" : "HButtonBox"
+ "xtype" : "ButtonBox"
}
],
"xtype" : "Box"
var child_1 = new Xcls_Notebook4( _this );
child_1.ref();
this.el.pack_start ( child_1.el , true,true,0 );
- var child_2 = new Xcls_HButtonBox53( _this );
+ var child_2 = new Xcls_ButtonBox53( _this );
child_2.ref();
this.el.add ( child_2.el );
}
_this.default_directory_menu.el.set_screen(Gdk.Screen.get_default());
_this.default_directory_menu.el.show_all();
- _this.default_directory_menu.el.popup(null, null, null, 3, ev.time);
+ _this.default_directory_menu.el.popup_at_pointer(ev);
// print("click:" + res.path.to_string());
return true;
});
// set gobject values
this.el.label = "Add Directory";
+ this.el.show();
//listeners
this.el.activate.connect( () => {
// set gobject values
this.el.label = "Add File";
+ this.el.show();
//listeners
this.el.activate.connect( () => {
// my vars (dec)
// set gobject values
+ this.el.show();
}
// user defined functions
// set gobject values
this.el.label = "Remove File/Directory";
+ this.el.show();
//listeners
this.el.activate.connect( () => {
// set gobject values
this.el.label = "Add Compile Target";
+ this.el.show();
//listeners
this.el.activate.connect( () => {
// my vars (dec)
// set gobject values
+ this.el.show();
}
// user defined functions
// set gobject values
this.el.label = "Remove Target";
+ this.el.show();
//listeners
this.el.activate.connect( () => {
_this.targets_tree_menu.el.set_screen(Gdk.Screen.get_default());
_this.targets_tree_menu.el.show_all();
- _this.targets_tree_menu.el.popup(null, null, null, 3, ev.time);
+ _this.targets_tree_menu.el.popup_at_pointer(ev);
// print("click:" + res.path.to_string());
return true;
});
- public class Xcls_HButtonBox53 : Object
+ public class Xcls_ButtonBox53 : Object
{
- public Gtk.HButtonBox el;
+ public Gtk.ButtonBox el;
private ValaProjectSettingsPopover _this;
// my vars (def)
// ctor
- public Xcls_HButtonBox53(ValaProjectSettingsPopover _owner )
+ public Xcls_ButtonBox53(ValaProjectSettingsPopover _owner )
{
_this = _owner;
- this.el = new Gtk.HButtonBox();
+ this.el = new Gtk.ButtonBox( Gtk.Orientation.HORIZONTAL );
// my vars (dec)
// set gobject values
- this.el.margin_right = 4;
- this.el.margin_left = 4;
+ this.el.margin_end = 4;
+ this.el.margin_start = 4;
this.el.margin_bottom = 4;
this.el.margin_top = 4;
var child_0 = new Xcls_Button54( _this );
"xtype" : "Menu"
},
{
- "$ Gtk.Stock stock" : "Gtk.Stock.ADD",
- "$ icon_size" : "Gtk.IconSize.MENU",
"$ xns" : "Gtk",
"* pack" : "set_image",
+ "string icon_name" : "list-add",
"xtype" : "Image"
}
],
" var p = _this.AddPropertyPopup;",
" p.el.set_screen(Gdk.Screen.get_default());",
" p.el.show_all();",
- " p.el.popup(null, null, null, ev.button, ev.time);",
+ " p.el.popup_at_pointer(ev);",
" return true;",
"}"
]
" selection.set_mode( Gtk.SelectionMode.SINGLE);",
"",
"",
- " var description = new Pango.FontDescription();",
- " description.set_size(10000);",
- " this.el.override_font(description);",
- " ",
+ " \tthis.css = new Gtk.CssProvider();",
+ "\ttry {",
+ "\t\tthis.css.load_from_data(\"#leftprops-view { font: 10p; x}\");",
+ "\t} catch (Error e) {}",
+ "\tthis.el.get_style_context().add_provider(this.css,",
+ "\t\tGtk.STYLE_PROVIDER_PRIORITY_APPLICATION);",
+ "",
+ " ",
"}",
""
],
"* pack" : "add",
+ "Gtk.CssProvider css" : "",
"Xcls_PopoverProperty popover" : "null",
"id" : "view",
"items" : [
"",
" p.el.set_screen(Gdk.Screen.get_default());",
" p.el.show_all();",
- " p.el.popup(null, null, null, ev.button, ev.time);",
+ " p.el.popup_at_pointer(ev);",
" //Seed.print(\"click:\" + res.column.title);",
" // select the ",
" GLib.Timeout.add_full(GLib.Priority.DEFAULT,10 , () => {",
"}"
]
},
+ "string name" : "leftprops-view",
"tooltip_column" : 3,
"xtype" : "TreeView",
"| void editPropertyDetails" : [
var p = _this.AddPropertyPopup;
p.el.set_screen(Gdk.Screen.get_default());
p.el.show_all();
- p.el.popup(null, null, null, ev.button, ev.time);
+ p.el.popup_at_pointer(ev);
return true;
});
}
// my vars (dec)
// set gobject values
- this.el.stock = Gtk.Stock.ADD;
- this.el.icon_size = Gtk.IconSize.MENU;
+ this.el.icon_name = "list-add";
}
// user defined functions
// my vars (def)
+ public Gtk.CssProvider css;
public Xcls_PopoverProperty popover;
// ctor
this.popover = null;
// set gobject values
+ this.el.name = "leftprops-view";
this.el.tooltip_column = 3;
this.el.enable_tree_lines = true;
this.el.headers_visible = true;
selection.set_mode( Gtk.SelectionMode.SINGLE);
- var description = new Pango.FontDescription();
- description.set_size(10000);
- this.el.override_font(description);
-
+ this.css = new Gtk.CssProvider();
+ try {
+ this.css.load_from_data("#leftprops-view { font: 10p; x}");
+ } catch (Error e) {}
+ this.el.get_style_context().add_provider(this.css,
+ Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
+
+
}
//listeners
p.el.set_screen(Gdk.Screen.get_default());
p.el.show_all();
- p.el.popup(null, null, null, ev.button, ev.time);
+ p.el.popup_at_pointer(ev);
//Seed.print("click:" + res.column.title);
// select the
GLib.Timeout.add_full(GLib.Priority.DEFAULT,10 , () => {
"$ xns" : "Gtk",
"* init" : [
"{",
- " var description = new Pango.FontDescription();",
- " description.set_size(8000);",
- " this.el.override_font(description);",
- "",
+ " this.css = new Gtk.CssProvider();",
+ "\ttry {",
+ "\t\tthis.css.load_from_data(\"#left-tree-view { font-size: 10px;}\");",
+ "\t} catch (Error e) {}",
+ "\tthis.el.get_style_context().add_provider(this.css,",
+ "\t\tGtk.STYLE_PROVIDER_PRIORITY_APPLICATION);",
+ "\t ",
+ "\t ",
+ " ",
" var selection = this.el.get_selection();",
" selection.set_mode( Gtk.SelectionMode.SINGLE);",
"",
],
"* pack" : "add",
"Boolean id" : "view",
+ "Gtk.CssProvider css" : "",
"bool button_is_pressed" : false,
"bool expand" : true,
"bool headers_visible" : false,
" ",
" _this.LeftTreeMenu.el.set_screen(Gdk.Screen.get_default());",
" _this.LeftTreeMenu.el.show_all();",
- " _this.LeftTreeMenu.el.popup(null, null, null, 3, ev.time);",
+ " _this.LeftTreeMenu.el.popup_at_pointer(ev);",
" // print(\"click:\" + res.path.to_string());",
" return true;",
"}"
""
]
},
+ "string name" : "left-tree-view",
"tooltip_column" : 1,
"xtype" : "TreeView",
"| void highlightDropPath" : [
public string dragData;
public bool button_is_pressed;
public bool key_is_pressed;
+ public Gtk.CssProvider css;
public int drag_x;
public int drag_y;
public string[] dropList;
this.key_is_pressed = false;
// set gobject values
+ this.el.name = "left-tree-view";
this.el.expand = true;
this.el.tooltip_column = 1;
this.el.enable_tree_lines = true;
// init method
{
- var description = new Pango.FontDescription();
- description.set_size(8000);
- this.el.override_font(description);
-
+ this.css = new Gtk.CssProvider();
+ try {
+ this.css.load_from_data("#left-tree-view { font-size: 10px;}");
+ } catch (Error e) {}
+ this.el.get_style_context().add_provider(this.css,
+ Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
+
+
+
var selection = this.el.get_selection();
selection.set_mode( Gtk.SelectionMode.SINGLE);
_this.LeftTreeMenu.el.set_screen(Gdk.Screen.get_default());
_this.LeftTreeMenu.el.show_all();
- _this.LeftTreeMenu.el.popup(null, null, null, 3, ev.time);
+ _this.LeftTreeMenu.el.popup_at_pointer(ev);
// print("click:" + res.path.to_string());
return true;
});
"* init" : [
"{",
" ",
- " ",
- " var description = Pango.FontDescription.from_string(\"monospace\");",
- " description.set_size(8000);",
- " this.el.override_font(description);",
- "",
+ " this.css = new Gtk.CssProvider();",
+ "\ttry {",
+ "\t\tthis.css.load_from_data(\"#roo-view { font: 10px Monospace;}\");",
+ "\t} catch (Error e) {}",
+ "\tthis.el.get_style_context().add_provider(this.css,",
+ "\t\tGtk.STYLE_PROVIDER_PRIORITY_APPLICATION);",
+ "\t ",
+ "\t ",
+ " ",
" this.loading = true;",
" //var buf = this.el.get_buffer();",
" //buf.notify.connect(this.onCursorChanged);",
" "
],
"* pack" : "add",
+ "Gtk.CssProvider css" : "",
"gboolean editable" : false,
"gboolean show_line_marks" : true,
"gboolean show_line_numbers" : true,
""
]
},
+ "string name" : "roo-view",
"xtype" : "SourceView",
"| string toString" : [
"() {",
{
"$ xns" : "Gtk",
"* init" : [
- "var description = Pango.FontDescription.from_string(\"monospace\");",
- "\tdescription.set_size(8000);",
- "\t this.el.override_font(description);",
- "",
+ "\tthis.css = new Gtk.CssProvider();",
+ "\ttry {",
+ "\t\tthis.css.load_from_data(\"#roo-search-entry { background-color: #ccc; }\");",
+ "\t} catch (Error e) {}",
+ "\tthis.el.get_style_context().add_provider(this.css,",
+ "\t\tGtk.STYLE_PROVIDER_PRIORITY_APPLICATION);",
+ "\t ",
+ " ",
""
],
+ "Gtk.CssProvider css" : "",
"bool hexpand" : true,
"id" : "search_entry",
"int width_request" : 300,
"} "
]
},
+ "string name" : "roo-search-entry",
"string placeholder_text" : "Press enter to search",
"xtype" : "SearchEntry",
"| void forwardSearch" : [
"}"
]
},
- "xtype" : "ImageMenuItem",
+ "xtype" : "MenuItem",
"| void updateResults" : [
"() {",
"\tthis.el.visible = true;",
public bool button_is_pressed;
public string prop_selected;
public bool key_is_pressed;
+ public Gtk.CssProvider css;
public JsRender.Node? node_selected;
// ctor
this.node_selected = null;
// set gobject values
+ this.el.name = "roo-view";
this.el.editable = false;
this.el.show_line_marks = true;
this.el.show_line_numbers = true;
{
-
- var description = Pango.FontDescription.from_string("monospace");
- description.set_size(8000);
- this.el.override_font(description);
-
+ this.css = new Gtk.CssProvider();
+ try {
+ this.css.load_from_data("#roo-view { font: 10px Monospace;}");
+ } catch (Error e) {}
+ this.el.get_style_context().add_provider(this.css,
+ Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
+
+
+
this.loading = true;
//var buf = this.el.get_buffer();
//buf.notify.connect(this.onCursorChanged);
// my vars (def)
+ public Gtk.CssProvider css;
// ctor
public Xcls_search_entry(Xcls_WindowRooView _owner )
// set gobject values
this.el.width_request = 300;
+ this.el.name = "roo-search-entry";
this.el.hexpand = true;
this.el.placeholder_text = "Press enter to search";
// init method
- var description = Pango.FontDescription.from_string("monospace");
- description.set_size(8000);
- this.el.override_font(description);
+ this.css = new Gtk.CssProvider();
+ try {
+ this.css.load_from_data("#roo-search-entry { background-color: #ccc; }");
+ } catch (Error e) {}
+ this.el.get_style_context().add_provider(this.css,
+ Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
//listeners
this.el.key_press_event.connect( (event) => {
}
public class Xcls_search_results : Object
{
- public Gtk.ImageMenuItem el;
+ public Gtk.MenuItem el;
private Xcls_WindowRooView _this;
// my vars (def)
+ public bool always_show_image;
// ctor
public Xcls_search_results(Xcls_WindowRooView _owner )
{
_this = _owner;
_this.search_results = this;
- this.el = new Gtk.ImageMenuItem();
+ this.el = new Gtk.MenuItem();
// my vars (dec)
+ this.always_show_image = true;
// set gobject values
- this.el.always_show_image = true;
this.el.visible = false;
this.el.show();
((global::Gtk.Widget)parent).button_press_event.connect((s, ev) => {
p.set_screen(Gdk.Screen.get_default());
p.show_all();
- p.popup(null, null, null, ev.button, ev.time);
+ p.popup_at_pointer(ev);
return true;
});
}