cvs: php-gtk /test bug_gtkdialog_title.phpw
| From: | Christian Weiske | Date: | Wed, 19 Oct 2005 17:34:30 +0000 |
| Subject: | cvs: php-gtk /test bug_gtkdialog_title.phpw | ||
| Groups: | php.gtk.cvs | ||
| Request: | Send a blank email to php-gtk-cvs+get-1918@lists.php.net to get a copy of this message | ||
cweiske Wed Oct 19 13:34:30 2005 EDT
Added files:
/php-gtk/test bug_gtkdialog_title.phpw
Log:
Weird title characters bug test script
http://cvs.php.net/co.php/php-gtk/test/bug_gtkdialog_title.phpw?r=1.1&p=1
Index: php-gtk/test/bug_gtkdialog_title.phpw
+++ php-gtk/test/bug_gtkdialog_title.phpw
<?php
/**
* Start the program, look at the title: Weird chars
* Click on the "Show again" button. Different weird chars.
*/
function showDialog()
{
$dialog = new GtkDialog('abcdef', null, 0, array( Gtk::STOCK_OK, Gtk::RESPONSE_OK,
'_Show again', Gtk::RESPONSE_CANCEL));
$hbox = new GtkHBox(false, 8);
$hbox->set_border_width(8);
$dialog->vbox->pack_start($hbox, false, false, 0);
$stock = GtkImage::new_from_stock(
Gtk::STOCK_DIALOG_QUESTION,
Gtk::ICON_SIZE_DIALOG);
$hbox->pack_start($stock, false, false, 0);
$table = new GtkTable(2, 2);
$table->set_row_spacings(4);
$table->set_col_spacings(4);
$hbox->pack_start($table, true, true, 0);
$label = new GtkLabel('Entry _1');
$label->set_use_underline(true);
$table->attach($label, 0, 1, 0, 1);
$local_entry1 = new GtkEntry();
//$local_entry1->set_text($this->entry1->get_text());
$table->attach($local_entry1, 1, 2, 0, 1);
$label->set_mnemonic_widget($local_entry1);
$label = new GtkLabel('Entry _2');
$label->set_use_underline(true);
$table->attach($label, 0, 1, 1, 2);
$local_entry2 = new GtkEntry();
//$local_entry2->set_text($this->entry2->get_text());
$table->attach($local_entry2, 1, 2, 1, 2);
$label->set_mnemonic_widget($local_entry2);
$dialog->show_all();
$response = $dialog->run();
$dialog->destroy();
if ($response == Gtk::RESPONSE_CANCEL) {
showDialog();
// $this->entry1->set_text($local_entry1->get_text());
// $this->entry2->set_text($local_entry2->get_text());
}
}
showDialog();
?>