Creates a new entry dialog instance. After creating it, you can modify it and finally use the run() to show it and await the input.
You might want to use a more simple constructor, e.g. get() or new_simple()
<?php require_once 'Gtk2/EntryDialog.php'; $id = new Gtk2_EntryDialog( null, //parent window 0, //flags (GtkDialogFlags) Gtk::MESSAGE_QUESTION, //type of message Gtk::BUTTONS_OK_CANCEL, //which buttons shall be there 'What\'s your name?', //the message 'Don\'t know' //The default text ); $answer = $id->run(); $id->destroy(); if ($answer == Gtk::RESPONSE_OK) { echo 'The name is: '; var_dump($id->get_text()); } else { echo "You cancelled\r\n"; } ?> |
Parent window (can be null).
Dialog flags (use 0 as default)
Message type (e.g. Gtk::MESSAGE_QUESTION)
Buttons to show (e.g. Gtk::BUTTONS_OK)
Message to display.
Default text for the entry.
Пред. | Начало | След. |
Introduction | Уровень выше | Gtk2_EntryDialog::new_simple() |
HIVE: All information for read only. Please respect copyright! |