w3-tools.com - Free Webmaster Tools and Resources
 
w3-tools.com - Free Webmaster Tools and Resources
 Free Webmaster Tools and Resources

 



PHP-GTK Manual

This manual is provided as a courtesy. It is not an official source. Please check gtk.php.net for updated information.

PHP-GTK Manual

PHP-GTK Manual

GtkDialog

Widget that eases creation of popup dialogs.

Object Hierarchy

GtkObject
`-- GtkWidget
       `-- GtkContainer
              `-- GtkBin
                     `-- GtkWindow
                            `-- GtkDialog

Direct subclasses

Description

GtkDialog is used to create a popup window for presenting or requesting small amounts of information. It is composed of two containers separated by a GtkHSeparator. The top container is a GtkVBox, and would typically contain GtkLabel and GtkEntry widgets to present the user with information and allow input. The bottom container is a GtkHBox and would usually contain dialog buttons, e.g. OK, Cancel, Help and so on.

Note that widgets should not be added to the GtkDialog itself but to the containers, which can be accessed as vbox and action_area respectively.

Dialogs can be made modal (in effect freezing input to the rest of the application) by calling the GtkWindow method set_modal() on the GtkDialog object.

Note that making a GtkDialog modal does not stop execution of the code that calls it. In the example below, the call to 'echo' will still get executed even though the main application may not respond to user input. To stop execution of the code the GtkDialog must contain a call to a nested gtk::main() function. Execution will then continue when the corresponding gtk::main_quit() function is called.

Example 12. Using set_modal()

<?php

$dialog = &new GtkDialog(); 
$dialog->set_modal(TRUE); 
echo "This message will still be printed \n";

?>

Constructor

GtkDialog (void);
-- Creates the basis for a popup dialog window.

Properties

vbox:
  Upper container.
action_area:
  Lower container.

Newsletter

Join to our newsletter and receive news and updates about our site.
Your name: 
E-mail address: 
Action: 
 

Hosted by

Search

Google
Web w3-tools.com

Links

  What is my IP? Find your IP address!     Valid XHTML 1.0 Transitional  
Copyright © 2006. by w3-tools.com. All rights reserved