ruby-****@sourc*****
ruby-****@sourc*****
2012年 10月 11日 (木) 08:07:13 JST
------------------------- REMOTE_ADDR = 184.145.82.7 REMOTE_HOST = URL = http://ruby-gnome2.sourceforge.jp/hiki.cgi?tut-gtk2-treev-cbbr ------------------------- @@ -10,12 +10,14 @@ The combo cell renderer displays the column identified by its((*text_column*))property. Note that this column is from module specified in the Gtk::CellRendererCombo#model=, not from the model associated with the tree view. With Gtk::CellRendererCombo render you can use either from Gtk::CellRendererText inherited 'edited' signal or'editing-started' signal inherited from Gtk::CellRenderer. -Like the spin button renderer which just like combo box renderer is also derived from the Gtk::CellRendererText, for both of them the((*'editable'*))property must be set to((*true*))to enable it. {{image_right("treev-combo-00.png")}} Following combo box renderer example program is a simple 'stripped down' implementation of our 'Grocery list' example. Note, that we are dealing here with two models. The first is model used to display rows of the tree view, and the other is the model used for the combo box items. + +Like the spin button renderer which just like combo box renderer is also derived from the Gtk::CellRendererText, for both of them the((*'editable'*))property must be set to((*true*))to enable it. Note that in this example the 'Count' column is controlled whether or not a cell or (renderer) should be editable in the cell data function. + {{br}}