Request for GtkWidget::set_visible(boolean) method
| From: | Christian Weiske | Date: | Tue, 28 Mar 2006 09:58:49 +0000 |
| Subject: | Request for GtkWidget::set_visible(boolean) method | ||
| Groups: | php.gtk.dev | ||
| Request: | Send a blank email to php-gtk-dev+get-2683@lists.php.net to get a copy of this message | ||
Hello all,
Currently, the only way to show/hide a widget in gtk2 is to use the
show() or hide() method. It is not possible to call a method with a
boolean parameter (as in e.g. set_sensitive(boolean)) to dynamically
modify the visibility of the widget.
I have the case that I need to show/hide some menu items dynamically
depending on a liststore value, but I need to make an if block to call
the right method:
if ($model->get_value($iter, 10)) {
$item->hide();
} else {
$item->show();
}
With set_sensitive, it's easy:
$item->set_sensitive($model->get_value($iter, 10));
Can we add a set_visible() method to the GtkWidget class?
--
Regards/MfG,
Christian Weiske
Attachment: [application/pgp-signature] OpenPGP digital signature signature.asc
Attachment: [application/pgp-signature] OpenPGP digital signature signature.asc