getting base gtkwindow without globals
| From: | Simon Wheeler | Date: | Thu, 27 Nov 2003 00:16:18 +0000 |
| Subject: | getting base gtkwindow without globals | ||
| Groups: | php.gtk.general | ||
| Request: | Send a blank email to php-gtk-general+get-4242@lists.php.net to get a copy of this message | ||
Hi,
I have a couple of widgets that require images , & sometimes its pretty damn
hard to keep a reference to the calling GtkWindow (which is I suppose plain
dodgy coding ;)) , anyway when I do get into this situation I end up
setting $GLOBALS['interface']['gdkwin']=$this->gdkwin in the main
constructor and utilise that when I use my image widgets later, but I would
love to avoid the globals if I could , I have managed to lose them most
everywhere else , just not here.
I tried a recursive get_toplevel() which was amusing to watch.
Is there an easy/any way to get a reference to the toplevel window object
from some unknown depth of an application?
Also ... does anyone have a working example (working in any sense) of a
scintilla widget with a working lexer for win32 ? I get scintilla 'working'
and do lots of fun stuff , just no joy whatsoever with the lexers.
Regards,
Simon Wheeler.