Re: Editable tables and general planning help
| From: | Jake Gordon | Date: | Thu, 07 Jul 2005 10:31:42 +0000 |
| Subject: | Re: Editable tables and general planning help | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-5925@lists.php.net to get a copy of this message | ||
Thanks Steph. Any idea how long I'll have to wait? Is it possible to start using an alpha version of PHP-GTK2 on Windows already?
I really need to finish this app by the end of next week or go back to a web based interface which I'm not too keen on :(
Jake.
Steph wrote:
Yeah, wait for PHP-GTK 2 and either write or use the correct tool. GTK 1 was very buggy indeed under Windows. The underlying toolkit didn't have built-in support for win32 and extensions couldn't be easily ported or written for that reason. GTK 2 _does_ have built-in support for win32 and is also much faster as a result. - Steph ----- Original Message ----- From: "Jake Gordon" <php-gtk@jakeg.co.uk> To: <php-gtk-general@lists.php.net> Sent: Thursday, July 07, 2005 11:35 AM Subject: Re: [PHP-GTK] Editable tables and general planning helpHi again, I tried GtkSheet but for some reason it doesn't display column and row headings until you go into a cell on the row/column. It seems a bit buggy. Also, it seems stuck at a fixed size so if there are too many rows or columns it can't display them all. Instead for now I've created a grid with GtkTable and GtkEntry and the functionality seems fine for what I need. However, my desired grid size is 22 columns and 100 rows. The program has great difficulty doing this - taking about 30 seconds to load, and then often crashing, possibly due to PHP max execution settings or something. Either way, not desirable. If its possible to get this table to load in a second or two then I'm set... if not then I think I'll have to stop playing with PHP-GTK and just go back to a web based interface. Here's my code for the grid. Perhaps someone can suggest a way to do this without having the application take ages and/or crash?: --- $table = &new GtkTable(); $vbox->add($table); $table->set_row_spacings(0); $table->set_col_spacings(0); $rows = 1000; $cols = 22; // Do $rows rows for($row=1;$row<=$rows;$row++) { // Do $cols columns for($col=1;$col<=$cols;$col++) {${'text_'.$col.'_'.$row} = &new GtkEntry(); ${'text_'.$col.'_'.$row}->set_text($row.".".$col); ${'text_'.$col.'_'.$row}->set_usize(40, -1); $table->attach(${'text_'.$col.'_'.$row}, $col, $col+1, $row,$row+1, GTK_SHRINK, GTK_SHRINK); } } $table->show_all(); --- Also, PHP seems not to release memory when I $widget->destroy(). Should it do? Or is there a different suggested way to release memory? e.g. I have five 'pages' in my application. When I go to one page the widget for the page that was showing before is destroyed. However, the memory it used doesn't seem to be release. Jake. Ivan Rodriguez wrote:PHP-GTK 1.0.1 version has all widgets, GtkSheet GtkPlot and other, the GtkExtra widgets and GtkScintilla and others too On 7/7/05, Jake Gordon <php-gtk@jakeg.co.uk> wrote:-- PHP-GTK General Mailing List (http://gtk.php.net/) To unsubscribe, visit: http://www.php.net/unsub.phpIvan Rodriguez wrote:I recommend you to see the widget GtkSheet is all what you need.This seems to be an 'extra' which is no longer maintained. Where can I get it from? I'm on Windows. Apparently I need a .dll as well. Jake. -- PHP-GTK General Mailing List (http://gtk.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php