Fix #8003 - undo code
[roobuilder] / src / Builder4 / WindowLeftProps.vala
index 5da1a3f..1941dcd 100644 (file)
@@ -12,7 +12,7 @@ public class Xcls_LeftProps : Object
                }
                return _LeftProps;
        }
-       public Xcls_AddPropertyPopup AddPropertyPopup;
+       public Xcls_addpop addpop;
        public Xcls_EditProps EditProps;
        public Xcls_view view;
        public Xcls_deletemenu deletemenu;
@@ -28,6 +28,7 @@ public class Xcls_LeftProps : Object
        public signal void show_add_props (string type);
        public signal bool stop_editor ();
        public Xcls_MainWindow main_window;
+       public int last_error_counter;
        public signal void changed ();
        public JsRender.JsRender file;
        public JsRender.Node node;
@@ -43,6 +44,7 @@ public class Xcls_LeftProps : Object
                this.loading = false;
                this.allow_edit = false;
                this.main_window = null;
+               this.last_error_counter = -1;
 
                // set gobject values
                this.el.homogeneous = false   ;
@@ -83,6 +85,61 @@ public class Xcls_LeftProps : Object
        
        
        
+       }
+       public void updateErrors () {
+               var file = this.file;
+               if (file == null) {
+                       return;
+               }
+               var ar = file.getErrors();
+               if (ar == null || ar.size < 1) {
+                       if (this.last_error_counter != file.error_counter) {
+                               this.removeErrors();
+                       }
+       
+                       this.last_error_counter = file.error_counter ;
+       
+                       return;
+               }
+               if (this.last_error_counter == file.error_counter) {
+                       return;
+               }
+               this.removeErrors();
+               
+               foreach(var diag in ar) { 
+               
+                        
+       //        print("get inter\n");
+                   var node= file.lineToNode( (int)diag.range.start.line) ;
+                   if (node == null || node.oid != this.node.oid) {
+                       continue;
+               }
+               var prop = node.lineToProp( (int)diag.range.start.line) ;
+               
+               var row = _this.selmodel.propToRow(prop);
+               if (row < 0) {
+                       continue;
+                       }
+               var w = this.view.getWidgetAtRow(row);
+               if (w == null) {
+                       return;
+                       }
+                               var ed = diag.category.down();
+                       if (ed != "err" && w.has_css_class("node-err")) {
+                               continue;
+                       }
+                       if (ed == "err" && w.has_css_class("node-warn")) {
+                               w.remove_css_class("node-warn");
+                       }
+                       if (ed == "err" && w.has_css_class("node-depr")) {
+                               w.remove_css_class("node-depr");
+                       }
+                       if (!w.has_css_class("node-"+ ed)) {
+                               w.add_css_class("node-" + ed);
+                       }
+                       
+               }
+               
        }
        public string keyFormat (string val, string type) {
            
@@ -185,38 +242,46 @@ public class Xcls_LeftProps : Object
                _this.changed();
                */
        }
-       public void a_addProp (JsRender.NodeProp prop) {
-             // info includes key, val, skel, etype..
-             //console.dump(info);
-               //type = info.type.toLowerCase();
-               //var data = this.toJS();
-                 
-                     
-           if (prop.ptype == JsRender.NodePropType.LISTENER) {
-               if (this.node.listeners.has_key(prop.name)) {
-                   return;
-               }
-               this.node.listeners.set(prop.name,prop);
-           } else  {
-                assert(this.node != null);
-                assert(this.node.props != null);
-               if (this.node.props.has_key(prop.to_index_key())) {
-                   return;
-               }
-               this.node.props.set(prop.to_index_key(),prop);
-           }
-                   
-             
-           // add a row???
-           this.load(this.file, this.node);
-           
-           
-            
-           
-           GLib.debug("trying to find new iter");
+       public void removeErrors () {
+               var  child = this.view.el.get_first_child(); 
         
-           
-                     
+               var reading_header = true;
+        
+               while (child != null) {
+                       //GLib.debug("Got %s", child.get_type().name());
+                  
+                  if (reading_header) {
+                               
+       
+                               if (child.get_type().name() != "GtkColumnListView") {
+                                  
+                                       child = child.get_next_sibling();
+                                       continue;
+                               }
+                               // should be columnlistview
+                               child = child.get_first_child(); 
+                        
+                        
+                               
+                               reading_header = false;
+                               continue;
+                   }
+                   
+                       if (child.has_css_class("node-err")) {
+                               child.remove_css_class("node-err");
+                       }
+                       if (child.has_css_class("node-warn")) {
+                               child.remove_css_class("node-warn");
+                       }
+                       
+                       if (child.has_css_class("node-depr")) {
+                               child.remove_css_class("node-depr");
+                       }
+                       
+               child = child.get_next_sibling(); 
+               }
+               //GLib.debug("Rturning null");
+            
        }
        public void load (JsRender.JsRender file, JsRender.Node? node) 
        {
@@ -253,6 +318,7 @@ public class Xcls_LeftProps : Object
           
                this.loading = false;
            this.selmodel.el.set_selected(Gtk.INVALID_LIST_POSITION);
+           this.updateErrors();
           // clear selection?
          //this.model.el.set_sort_column_id(4,Gtk.SortType.ASCENDING); // sort by real key..
           
@@ -289,7 +355,7 @@ public class Xcls_LeftProps : Object
                        var child_3 = new Xcls_Button5( _this );
                        child_3.ref();
                        this.el.append( child_3.el );
-                       var child_4 = new Xcls_Button6( _this );
+                       var child_4 = new Xcls_MenuButton6( _this );
                        child_4.ref();
                        this.el.append( child_4.el );
                }
@@ -398,54 +464,31 @@ public class Xcls_LeftProps : Object
                // user defined functions
        }
 
-       public class Xcls_Button6 : Object
+       public class Xcls_MenuButton6 : Object
        {
-               public Gtk.Button el;
+               public Gtk.MenuButton el;
                private Xcls_LeftProps  _this;
 
 
                        // my vars (def)
-               public bool always_show_image;
 
                // ctor
-               public Xcls_Button6(Xcls_LeftProps _owner )
+               public Xcls_MenuButton6(Xcls_LeftProps _owner )
                {
                        _this = _owner;
-                       this.el = new Gtk.Button();
+                       this.el = new Gtk.MenuButton();
 
                        // my vars (dec)
-                       this.always_show_image = true;
 
                        // set gobject values
-                       this.el.icon_name = "list-add";
-                       this.el.hexpand = true;
                        this.el.label = "Other";
-                       new Xcls_AddPropertyPopup( _this );
-
-                       //listeners
-                       this.el.clicked.connect( ( ) => {
-                         //_this.before_edit();
-                         
-                               
-                           var p = _this.AddPropertyPopup;
-                           
-                        //     Gtk.Allocation rect;
-                               //this.el.get_allocation(out rect);
-                               if (p.el.parent == null) {
-                                        p.el.set_parent(this.el);
-                                }
-                           //p.el.set_pointing_to(rect);
-                               p.el.show();
-                               p.el.set_position(Gtk.PositionType.BOTTOM);
-                               p.el.autohide = true;
-                            return;
-                       
-                       });
+                       new Xcls_addpop( _this );
+                       this.el.popover = _this.addpop.el;
                }
 
                // user defined functions
        }
-       public class Xcls_AddPropertyPopup : Object
+       public class Xcls_addpop : Object
        {
                public Gtk.Popover el;
                private Xcls_LeftProps  _this;
@@ -454,16 +497,15 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_AddPropertyPopup(Xcls_LeftProps _owner )
+               public Xcls_addpop(Xcls_LeftProps _owner )
                {
                        _this = _owner;
-                       _this.AddPropertyPopup = this;
+                       _this.addpop = this;
                        this.el = new Gtk.Popover();
 
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.autohide = true;
                        var child_1 = new Xcls_Box8( _this );
                        this.el.child = child_1.el;
                }
@@ -490,52 +532,52 @@ public class Xcls_LeftProps : Object
                        var child_1 = new Xcls_Button9( _this );
                        child_1.ref();
                        this.el.append( child_1.el );
-                       var child_2 = new Xcls_Button10( _this );
+                       var child_2 = new Xcls_Button11( _this );
                        child_2.ref();
                        this.el.append( child_2.el );
-                       var child_3 = new Xcls_Button11( _this );
+                       var child_3 = new Xcls_Button13( _this );
                        child_3.ref();
                        this.el.append( child_3.el );
-                       var child_4 = new Xcls_Button12( _this );
+                       var child_4 = new Xcls_Button15( _this );
                        child_4.ref();
                        this.el.append( child_4.el );
-                       var child_5 = new Xcls_Button13( _this );
+                       var child_5 = new Xcls_Button17( _this );
                        child_5.ref();
                        this.el.append( child_5.el );
-                       var child_6 = new Xcls_Separator14( _this );
+                       var child_6 = new Xcls_Separator19( _this );
                        child_6.ref();
                        this.el.append( child_6.el );
-                       var child_7 = new Xcls_Button15( _this );
+                       var child_7 = new Xcls_Button20( _this );
                        child_7.ref();
                        this.el.append( child_7.el );
-                       var child_8 = new Xcls_Button16( _this );
+                       var child_8 = new Xcls_Button22( _this );
                        child_8.ref();
                        this.el.append( child_8.el );
-                       var child_9 = new Xcls_Button17( _this );
+                       var child_9 = new Xcls_Button24( _this );
                        child_9.ref();
                        this.el.append( child_9.el );
-                       var child_10 = new Xcls_Separator18( _this );
+                       var child_10 = new Xcls_Separator26( _this );
                        child_10.ref();
                        this.el.append( child_10.el );
-                       var child_11 = new Xcls_Button19( _this );
+                       var child_11 = new Xcls_Button27( _this );
                        child_11.ref();
                        this.el.append( child_11.el );
-                       var child_12 = new Xcls_Button20( _this );
+                       var child_12 = new Xcls_Button29( _this );
                        child_12.ref();
                        this.el.append( child_12.el );
-                       var child_13 = new Xcls_Button21( _this );
+                       var child_13 = new Xcls_Button31( _this );
                        child_13.ref();
                        this.el.append( child_13.el );
-                       var child_14 = new Xcls_Separator22( _this );
+                       var child_14 = new Xcls_Separator33( _this );
                        child_14.ref();
                        this.el.append( child_14.el );
-                       var child_15 = new Xcls_Button23( _this );
+                       var child_15 = new Xcls_Button34( _this );
                        child_15.ref();
                        this.el.append( child_15.el );
-                       var child_16 = new Xcls_Button24( _this );
+                       var child_16 = new Xcls_Button36( _this );
                        child_16.ref();
                        this.el.append( child_16.el );
-                       var child_17 = new Xcls_Button25( _this );
+                       var child_17 = new Xcls_Button38( _this );
                        child_17.ref();
                        this.el.append( child_17.el );
                }
@@ -559,12 +601,13 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "Using _this.{ID} will map to this element";
-                       this.el.label = "id: _this.{ID} (Vala)";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label10( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ()  => {
-                               _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                                // is this userdef or special??
                                var add = new JsRender.NodeProp.prop("id");
                                if (_this.node.has_prop_key(add)) {
@@ -575,14 +618,37 @@ public class Xcls_LeftProps : Object
                                
                                _this.view.editProp( add );
                                
-                               
                        });
                }
 
                // user defined functions
        }
+       public class Xcls_Label10 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
+
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label10(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "id: _this.{ID} (Vala)" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Using _this.{ID} will map to this element";
+               }
+
+               // user defined functions
+       }
+
 
-       public class Xcls_Button10 : Object
+       public class Xcls_Button11 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -591,7 +657,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button10(Xcls_LeftProps _owner )
+               public Xcls_Button11(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -599,14 +665,15 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "how to pack this element onto parent, (method, 2nd arg, 3rd arg) .. the 1st argument is filled by the element";
-                       this.el.label = "pack: Pack method (Vala)";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label12( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) => {
                         
                        
-                               _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                                // is this userdef or special??
                                var add = new JsRender.NodeProp.special("pack", "add");
                                if (_this.node.has_prop_key(add)) {
@@ -623,8 +690,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label12 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
 
-       public class Xcls_Button11 : Object
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label12(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "pack: Pack method (Vala)" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "how to pack this element onto parent, (method, 2nd arg, 3rd arg) .. the 1st argument is filled by the element";
+               }
+
+               // user defined functions
+       }
+
+
+       public class Xcls_Button13 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -633,7 +724,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button11(Xcls_LeftProps _owner )
+               public Xcls_Button13(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -641,13 +732,14 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "eg. \n\nnew Clutter.Image.from_file(.....)";
-                       this.el.label = "ctor: Alterative to default contructor (Vala)";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label14( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) => {
                           
-                        _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                                // is this userdef or special??
                                var add = new JsRender.NodeProp.special("ctor");
                                if (_this.node.has_prop_key(add)) {
@@ -663,8 +755,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label14 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
+
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label14(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "ctor: Alterative to default contructor (Vala)" );
 
-       public class Xcls_Button12 : Object
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "eg. \n\nnew Clutter.Image.from_file(.....)";
+               }
+
+               // user defined functions
+       }
+
+
+       public class Xcls_Button15 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -673,7 +789,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button12(Xcls_LeftProps _owner )
+               public Xcls_Button15(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -681,13 +797,14 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "This code is called after the ctor";
-                       this.el.label = "init: initialziation code (vala)";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label16( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) => {
                            
-                        _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                                // is this userdef or special??
                                var add =  new JsRender.NodeProp.special("init","{\n\n}\n" ) ;
                                if (_this.node.has_prop_key(add)) {
@@ -702,8 +819,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label16 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
 
-       public class Xcls_Button13 : Object
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label16(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "init: initialziation code (vala)" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "This code is called after the ctor";
+               }
+
+               // user defined functions
+       }
+
+
+       public class Xcls_Button17 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -712,7 +853,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button13(Xcls_LeftProps _owner )
+               public Xcls_Button17(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -720,13 +861,14 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "set the cms-id for this element, when converted to javascript, the html value will be wrapped with Pman.Cms.content({cms-id},{original-html})\n";
-                       this.el.label = "cms-id: (Roo JS/Pman library)";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label18( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ()  => {
-                          
-                        _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
+                        
                                // is this userdef or special??
                                var add =   new JsRender.NodeProp.prop("cms-id","string", "" ) ;
                                if (_this.node.has_prop_key(add)) {
@@ -742,8 +884,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label18 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
+
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label18(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "cms-id: (Roo JS/Pman library)" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "set the cms-id for this element, when converted to javascript, the html value will be wrapped with Pman.Cms.content({cms-id},{original-html})\n";
+               }
+
+               // user defined functions
+       }
+
 
-       public class Xcls_Separator14 : Object
+       public class Xcls_Separator19 : Object
        {
                public Gtk.Separator el;
                private Xcls_LeftProps  _this;
@@ -752,7 +918,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Separator14(Xcls_LeftProps _owner )
+               public Xcls_Separator19(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Separator( Gtk.Orientation.HORIZONTAL );
@@ -765,7 +931,7 @@ public class Xcls_LeftProps : Object
                // user defined functions
        }
 
-       public class Xcls_Button15 : Object
+       public class Xcls_Button20 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -774,7 +940,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button15(Xcls_LeftProps _owner )
+               public Xcls_Button20(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -782,12 +948,13 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "Add a user defined string property";
-                       this.el.label = "String";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label21( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( (self) => {
-                            _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                                _this.view.popover.show(
                                        _this.view.el, 
                                        _this.node, 
@@ -801,8 +968,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label21 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
+
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label21(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "String" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Add a user defined string property";
+               }
+
+               // user defined functions
+       }
+
 
-       public class Xcls_Button16 : Object
+       public class Xcls_Button22 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -811,7 +1002,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button16(Xcls_LeftProps _owner )
+               public Xcls_Button22(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -819,13 +1010,14 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "Add a user defined number property";
-                       this.el.label = "Number";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label23( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) =>{
-                             _this.AddPropertyPopup.el.hide();
-                             
+                        
+                               _this.addpop.el.hide();
                               _this.view.popover.show(
                                        _this.view.el, 
                                        _this.node, 
@@ -839,8 +1031,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label23 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
 
-       public class Xcls_Button17 : Object
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label23(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "Number" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Add a user defined number property";
+               }
+
+               // user defined functions
+       }
+
+
+       public class Xcls_Button24 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -849,7 +1065,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button17(Xcls_LeftProps _owner )
+               public Xcls_Button24(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -857,13 +1073,14 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "Add a user defined boolean property";
-                       this.el.label = "Boolean";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label25( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) =>{
                          
-                                    _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                           _this.view.popover.show(
                                        _this.view.el, 
                                        _this.node, 
@@ -877,8 +1094,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label25 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
+
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label25(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "Boolean" );
 
-       public class Xcls_Separator18 : Object
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Add a user defined boolean property";
+               }
+
+               // user defined functions
+       }
+
+
+       public class Xcls_Separator26 : Object
        {
                public Gtk.Separator el;
                private Xcls_LeftProps  _this;
@@ -887,7 +1128,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Separator18(Xcls_LeftProps _owner )
+               public Xcls_Separator26(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Separator( Gtk.Orientation.HORIZONTAL );
@@ -900,7 +1141,7 @@ public class Xcls_LeftProps : Object
                // user defined functions
        }
 
-       public class Xcls_Button19 : Object
+       public class Xcls_Button27 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -909,7 +1150,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button19(Xcls_LeftProps _owner )
+               public Xcls_Button27(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -917,12 +1158,13 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "Add a user function boolean property";
-                       this.el.label = "Javascript Function";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label28( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) =>{
-                         _this.AddPropertyPopup.el.hide(); 
+                               _this.addpop.el.hide();
                           _this.view.popover.show(
                                        _this.view.el, 
                                        _this.node, 
@@ -937,8 +1179,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label28 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
 
-       public class Xcls_Button20 : Object
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label28(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "Javascript Function" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Add a javascript  function";
+               }
+
+               // user defined functions
+       }
+
+
+       public class Xcls_Button29 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -947,7 +1213,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button20(Xcls_LeftProps _owner )
+               public Xcls_Button29(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -955,12 +1221,13 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "Add a user function boolean property";
-                       this.el.label = "Vala Method";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label30( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) =>{
-                       _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                            _this.view.popover.show(
                                        _this.view.el, 
                                        _this.node, 
@@ -973,8 +1240,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label30 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
+
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label30(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "Vala Method" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Add a user defined method to a object";
+               }
+
+               // user defined functions
+       }
+
 
-       public class Xcls_Button21 : Object
+       public class Xcls_Button31 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -983,7 +1274,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button21(Xcls_LeftProps _owner )
+               public Xcls_Button31(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -991,12 +1282,13 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "Add a vala signal";
-                       this.el.label = "Vala Signal";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label32( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) =>{
-                         _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide(); 
                          _this.view.popover.show(
                                        _this.view.el, 
                                        _this.node, 
@@ -1009,8 +1301,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label32 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
+
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label32(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "Vala Signal" );
+
+                       // my vars (dec)
 
-       public class Xcls_Separator22 : Object
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Add a user defined signal to a object";
+               }
+
+               // user defined functions
+       }
+
+
+       public class Xcls_Separator33 : Object
        {
                public Gtk.Separator el;
                private Xcls_LeftProps  _this;
@@ -1019,7 +1335,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Separator22(Xcls_LeftProps _owner )
+               public Xcls_Separator33(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Separator( Gtk.Orientation.HORIZONTAL );
@@ -1032,7 +1348,7 @@ public class Xcls_LeftProps : Object
                // user defined functions
        }
 
-       public class Xcls_Button23 : Object
+       public class Xcls_Button34 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -1041,7 +1357,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button23(Xcls_LeftProps _owner )
+               public Xcls_Button34(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -1049,12 +1365,13 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "Add a flexy if (for HTML templates)";
-                       this.el.label = "Flexy - If";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label35( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) =>{
-                               _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                                _this.view.popover.show(
                                        _this.view.el, 
                                        _this.node, 
@@ -1069,8 +1386,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label35 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
 
-       public class Xcls_Button24 : Object
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label35(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "Flexy - If" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Add a flexy if (for HTML templates)";
+               }
+
+               // user defined functions
+       }
+
+
+       public class Xcls_Button36 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -1079,7 +1420,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button24(Xcls_LeftProps _owner )
+               public Xcls_Button36(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -1087,12 +1428,13 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       this.el.tooltip_markup = "Add a flexy include (for HTML templates)";
-                       this.el.label = "Flexy - Include";
+                       this.el.has_frame = false;
+                       var child_1 = new Xcls_Label37( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) =>{
-                               _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                                _this.view.popover.show(
                                        _this.view.el, 
                                        _this.node, 
@@ -1107,8 +1449,32 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label37 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
+
 
-       public class Xcls_Button25 : Object
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label37(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "Flexy - Include" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Add a flexy include (for HTML templates)";
+               }
+
+               // user defined functions
+       }
+
+
+       public class Xcls_Button38 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -1117,7 +1483,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button25(Xcls_LeftProps _owner )
+               public Xcls_Button38(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -1125,12 +1491,14 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
+                       this.el.has_frame = false;
                        this.el.tooltip_markup = "Add a flexy include (for HTML templates)";
-                       this.el.label = "Flexy - Foreach";
+                       var child_1 = new Xcls_Label39( _this );
+                       this.el.child = child_1.el;
 
                        //listeners
                        this.el.clicked.connect( ( ) =>{
-                               _this.AddPropertyPopup.el.hide();
+                               _this.addpop.el.hide();
                                _this.view.popover.show(
                                        _this.view.el, 
                                        _this.node, 
@@ -1144,6 +1512,30 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
+       public class Xcls_Label39 : Object
+       {
+               public Gtk.Label el;
+               private Xcls_LeftProps  _this;
+
+
+                       // my vars (def)
+
+               // ctor
+               public Xcls_Label39(Xcls_LeftProps _owner )
+               {
+                       _this = _owner;
+                       this.el = new Gtk.Label( "Flexy - Foreach" );
+
+                       // my vars (dec)
+
+                       // set gobject values
+                       this.el.halign = Gtk.Align.START;
+                       this.el.tooltip_text = "Add a flexy foreach (for HTML templates)";
+               }
+
+               // user defined functions
+       }
+
 
 
 
@@ -1212,10 +1604,10 @@ public class Xcls_LeftProps : Object
                        this.el.vexpand = true;
                        this.el.show_row_separators = true;
                        new Xcls_deletemenu( _this );
-                       var child_3 = new Xcls_GestureClick31( _this );
+                       var child_3 = new Xcls_GestureClick45( _this );
                        child_3.ref();
                        this.el.add_controller(  child_3.el );
-                       var child_4 = new Xcls_GestureClick32( _this );
+                       var child_4 = new Xcls_GestureClick46( _this );
                        child_4.ref();
                        this.el.add_controller(  child_4.el );
                        new Xcls_keycol( _this );
@@ -1288,6 +1680,7 @@ public class Xcls_LeftProps : Object
                                                }
                                                child = child.get_first_child(); 
                                                reading_header = false;
+                                               continue;
                                }
                                    if (child.get_type().name() != "GtkColumnViewRowWidget") {
                                    child = child.get_next_sibling();
@@ -1437,11 +1830,11 @@ public class Xcls_LeftProps : Object
                                                }
                                                // should be columnlistview
                                                child = child.get_first_child(); 
-                                           GLib.debug("header height=%d", h);
+                                           //GLib.debug("header height=%d", h);
                                                header_height =  h;
                                                
                                                reading_header = false;
-                                               
+                                               continue;
                                }
                                
                                    if (child.get_type().name() != "GtkColumnViewRowWidget") {
@@ -1455,6 +1848,13 @@ public class Xcls_LeftProps : Object
                                    
                                    line_no++;
                                        var hh = child.get_height();
+                                       if (child.has_css_class("node-err") || 
+                                               child.has_css_class("node-warn") || 
+                                               child.has_css_class("node-depr")) {
+                                               hh += 10;
+                                       
+                                       }
+                                       
                                        //child.get_allocation(out alloc);
                                        //GLib.debug("got cell xy = %d,%d  w,h= %d,%d", alloc.x, alloc.y, alloc.width, alloc.height);
                                        //GLib.debug("row %d y= %d %s", line_no, (int) (header_height + alloc.y),
@@ -1502,13 +1902,13 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       var child_1 = new Xcls_Box29( _this );
+                       var child_1 = new Xcls_Box43( _this );
                        this.el.child = child_1.el;
                }
 
                // user defined functions
        }
-       public class Xcls_Box29 : Object
+       public class Xcls_Box43 : Object
        {
                public Gtk.Box el;
                private Xcls_LeftProps  _this;
@@ -1517,7 +1917,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Box29(Xcls_LeftProps _owner )
+               public Xcls_Box43(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Box( Gtk.Orientation.VERTICAL, 0 );
@@ -1525,14 +1925,14 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       var child_1 = new Xcls_Button30( _this );
+                       var child_1 = new Xcls_Button44( _this );
                        child_1.ref();
                        this.el.append( child_1.el );
                }
 
                // user defined functions
        }
-       public class Xcls_Button30 : Object
+       public class Xcls_Button44 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -1541,7 +1941,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button30(Xcls_LeftProps _owner )
+               public Xcls_Button44(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();
@@ -1567,7 +1967,7 @@ public class Xcls_LeftProps : Object
 
 
 
-       public class Xcls_GestureClick31 : Object
+       public class Xcls_GestureClick45 : Object
        {
                public Gtk.GestureClick el;
                private Xcls_LeftProps  _this;
@@ -1576,7 +1976,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_GestureClick31(Xcls_LeftProps _owner )
+               public Xcls_GestureClick45(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.GestureClick();
@@ -1624,7 +2024,7 @@ public class Xcls_LeftProps : Object
                // user defined functions
        }
 
-       public class Xcls_GestureClick32 : Object
+       public class Xcls_GestureClick46 : Object
        {
                public Gtk.GestureClick el;
                private Xcls_LeftProps  _this;
@@ -1633,7 +2033,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_GestureClick32(Xcls_LeftProps _owner )
+               public Xcls_GestureClick46(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.GestureClick();
@@ -1707,6 +2107,17 @@ public class Xcls_LeftProps : Object
                }
 
                // user defined functions
+               public int propToRow (JsRender.NodeProp prop) {
+                       for (var i = 0 ; i < this.el.n_items; i++) {
+                               var r = (JsRender.NodeProp)this.el.get_item(i);
+                               if (r.equals(prop)) {
+                                       return i;
+                                       
+                               }
+                       }
+                       return -1;
+                        
+               }
                public void startEditing (JsRender.NodeProp prop) {
                        // should we call select?? - caller does int (from windowstate)
                        
@@ -1765,7 +2176,7 @@ public class Xcls_LeftProps : Object
                {
                        _this = _owner;
                        _this.keycol = this;
-                       var child_1 = new Xcls_SignalListItemFactory36( _this );
+                       var child_1 = new Xcls_SignalListItemFactory50( _this );
                        child_1.ref();
                        this.el = new Gtk.ColumnViewColumn( "Property", child_1.el );
 
@@ -1779,7 +2190,7 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
-       public class Xcls_SignalListItemFactory36 : Object
+       public class Xcls_SignalListItemFactory50 : Object
        {
                public Gtk.SignalListItemFactory el;
                private Xcls_LeftProps  _this;
@@ -1788,7 +2199,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_SignalListItemFactory36(Xcls_LeftProps _owner )
+               public Xcls_SignalListItemFactory50(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.SignalListItemFactory();
@@ -1850,7 +2261,7 @@ public class Xcls_LeftProps : Object
                {
                        _this = _owner;
                        _this.valcol = this;
-                       var child_1 = new Xcls_SignalListItemFactory38( _this );
+                       var child_1 = new Xcls_SignalListItemFactory52( _this );
                        child_1.ref();
                        this.el = new Gtk.ColumnViewColumn( "Value", child_1.el );
 
@@ -1864,7 +2275,7 @@ public class Xcls_LeftProps : Object
 
                // user defined functions
        }
-       public class Xcls_SignalListItemFactory38 : Object
+       public class Xcls_SignalListItemFactory52 : Object
        {
                public Gtk.SignalListItemFactory el;
                private Xcls_LeftProps  _this;
@@ -1874,7 +2285,7 @@ public class Xcls_LeftProps : Object
                public bool is_setting;
 
                // ctor
-               public Xcls_SignalListItemFactory38(Xcls_LeftProps _owner )
+               public Xcls_SignalListItemFactory52(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.SignalListItemFactory();
@@ -2082,13 +2493,13 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       var child_1 = new Xcls_Box40( _this );
+                       var child_1 = new Xcls_Box54( _this );
                        this.el.child = child_1.el;
                }
 
                // user defined functions
        }
-       public class Xcls_Box40 : Object
+       public class Xcls_Box54 : Object
        {
                public Gtk.Box el;
                private Xcls_LeftProps  _this;
@@ -2097,7 +2508,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Box40(Xcls_LeftProps _owner )
+               public Xcls_Box54(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Box( Gtk.Orientation.VERTICAL, 0 );
@@ -2105,14 +2516,14 @@ public class Xcls_LeftProps : Object
                        // my vars (dec)
 
                        // set gobject values
-                       var child_1 = new Xcls_Button41( _this );
+                       var child_1 = new Xcls_Button55( _this );
                        child_1.ref();
                        this.el.append( child_1.el );
                }
 
                // user defined functions
        }
-       public class Xcls_Button41 : Object
+       public class Xcls_Button55 : Object
        {
                public Gtk.Button el;
                private Xcls_LeftProps  _this;
@@ -2121,7 +2532,7 @@ public class Xcls_LeftProps : Object
                        // my vars (def)
 
                // ctor
-               public Xcls_Button41(Xcls_LeftProps _owner )
+               public Xcls_Button55(Xcls_LeftProps _owner )
                {
                        _this = _owner;
                        this.el = new Gtk.Button();