Re: GtkBuilder syntax for property bindings



On Fri, 2011-05-06 at 13:04 +0200, Denis Washington wrote:
> The main issue with this approach is what to do with two-way bindings. 
> One approach would be to make this a property of <bind>, but then, 
> <bind> wouldn't appear in every property it influences anymore. 
> Alternatively, the parser could be required to recognize direct cyclic 
> binding declarations (A binds to B, B binds to A) and collapse them into 
> a single two-way binding, which retains the 
> <bind>-only-affects-the-property-it-appears-in property; the parser 
> would be complicated by this, though.

Since GBinding, is itself, an object, why not just have the GBinding
instance represented in the GtkBuilder XML. The normal object syntax
might work as well:

  <object class"GBinding" id="some_binding">
    <property name="source">object1</property>
    <property name="target">object2</property>
  </object>

I think this would mean the majority of work is how to make it easy to
manage from within Glade.

Just a thought,

-- Christian




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]