guenter geiger wrote:
On Tue, 10 Feb 2004, B. Bogart wrote:
Hello All,
I'm still on that slow process of learning how one writes graphical externals.
I was wondering if anyone has a very simple graphical external example? Perhaps something that just creates a label widget, perhaps with a property dialog to change the text therin?
I'm currently looking at the simplest graphical things I can find, which are the iemgui objects, bang etc.. Are these now internals? Are they written differently than if they were externals?
Take a look at the even simpler graphical objects in pd, like the numberbox and the "objects", the message boxes. Basically you have to fill up the widgetbehaviour structure which defines, well, the widgetbehaviour. For the properties dialogs you will have to write some tcl/tk code in u_main.tk (or you reuse the existing dialogs). There is a third option of sending the tcl/tk code from your external, but this is pretty ugly.
I think I mentioned this before, and I am sure Krysztof did it too, graphical externals written this way can cause performance problems. It would be a lot better to reuse tcl/tk widgets, ...
yeh, it might be slower this way, but how can you insert your tcl/tk in u_main.tk ( which is distributed with pd ) without ugly patches?
if your graphical updater runs in a thread, it works smoothly.
cheers, sevy
Guenter
PD-dev mailing list PD-dev@iem.at http://iem.at/cgi-bin/mailman/listinfo/pd-dev