Re: Labels that don't update?
| From: | Rich Payne | Date: | Tue, 11 Mar 2003 23:47:49 +0000 |
| Subject: | Re: Labels that don't update? | ||
| References: | 1 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-3027@lists.php.net to get a copy of this message | ||
try this:
On Tue, 11 Feb 2003, Benjamin Smith wrote:
> I'm having trouble getting GtkLabel() widgets to update. Here's some sample
> code - Why isn't this working like I think it should? Instead of indicating
> that we're doing 1, 2, 3, 4 it doesn't display until it's gotten to 4.
>
> <?
> if (!class_exists('gtk'))
> {
> if (strtoupper(substr(PHP_OS, 0,3) == 'WIN'))
> dl('php_gtk.dll');
> else dl('php_gtk.so');
> }
>
> Function Go()
> {
> global $d;
> for ($i=0; $i<5; $i++)
> {
> $d[label]->Set_Text('Now processing: '.$i);
while (gtk::events_pending())
gtk::main_iteration();
> sleep(2);
> }
> }
[snip]
--rdp
Rich Payne
http://talisman.mv.com
rdp at talisman dot mv dot com