[Gnocl -the Tcl/Gtk Bindings] Summary of Recent Progress

3 views
Skip to first unread message

William J Giddings

unread,
Jun 4, 2015, 5:49:41 PM6/4/15
to gn...@googlegroups.com
The current nightly build sees a a range of enacements to Gnocl as a whole. A number of issues have been addressed as itemized in the extract from the NEWS document below. This nightly update sees the -name option taking on a greater role in the control of widgets. Ordinarily used for specifying ojects in a Gtk CSS file, or in a builder/glade XML file, using the name option will cause the interpretor to create a command for the widget using the string specified by the -name option. Ordinarily a widget instance would be created as follows:

set myButton [gnocl::button -text "Hello World"]

And modified with:

$myButton configure -onClicked { puts %w }

But now,  the following will produce similar results.

gnocl::button -text "Hell World" -name myButton

Modification can also be handled too,

myButton configure -onClicked {puts %w}

This approach provides a neat and efficient way of creating widgets as objects within namespaces. Using the same example the following could be used:

gnocl::button -text "Hell World" -name myprocs::myButton

The creation of widget with command names in this way does not eliminate the process of registering widgets with a unique id. Using the same example, to access this simply use:

[myprocs::myButton]

and the widget id will be returned.

Substitution strings also unclude the %g and %w parameters to extract the (glade) name and w(idget-id) of the object.


2015-05:
    gnocl::notebook
        o added extra percentage subtitution strings to -onPageAdded, -onPageRemoved
                %l page label
    gnocl::comboBox/comboEntry added new sub-commands: get, set, prepend, append, insert and remove.
    gnocl::box/hBox/vBox fixed problem with cget -children
    gnocl::window, gnocl::expander, gnocl::fontSelection, gnocl::gammaCurve,
    gnocl::curve, gnocl::handleBox, gnocl::level, gnocl::popupEntry, gnocl::recentChooser
        o added -name
  

--
Posted By William J Giddings to Gnocl -the Tcl/Gtk Bindings on 6/04/2015 10:49:00 p.m.
Reply all
Reply to author
Forward
0 new messages