Poet 1.1 was a lot slower, I did some profiling and optimizing around
1999-2000 but haven't done any since. It's likely that profiling
using modern tools would uncover some low-hanging fruit that could
be fixed to get a significant speed-up.
Another thing that's been suggested is to port Poet to TclOO, which
is well optimized already.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I don't have many tips for faster Poet. Using autoloading helps,
since you don't have to load the whole application at once. I
also mix Poet widgets and Tk/Ttk widgets freely, if it's faster
to do something in raw Tk and I don't need Poet's slot behavior,
I just implement it in Tk.
I often store slot values in local variables rather than repeatedly
calling "slot" on the same slot. Using "poetvar" is handy but apparently
actually slower than using "slot", so I only use it when I'm
going to be getting and setting a slot frequently.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Moving from Poet Tk_Canvas_* objects to raw Tk's increased speed a lot. I would say in times.
E.g. when there are 50 shapes on the screen and I select them all a lot of handlers/resizers are drawn. Now it takes around a second against several before.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
What are advises to speed up a poet based application? E.g. to avoid some syntactiv forms, initializations; use faster method calls etc.
Poet 1.1 was a lot slower, I did some profiling and optimizing around
1999-2000 but haven't done any since. It's likely that profiling
using modern tools would uncover some low-hanging fruit that could
be fixed to get a significant speed-up.
Another thing that's been suggested is to port Poet to TclOO, which
is well optimized already.
> Another thing that's been suggested is to port Poet to TclOO, which
> is well optimized already
How much efforts needed for that? Can the work be automated? I'm just curious.
I don't have many tips for faster Poet. Using autoloading helps,
since you don't have to load the whole application at once. I
also mix Poet widgets and Tk/Ttk widgets freely, if it's faster
to do something in raw Tk and I don't need Poet's slot behavior,
I just implement it in Tk.
I often store slot values in local variables rather than repeatedly
calling "slot" on the same slot. Using "poetvar" is handy but apparently
actually slower than using "slot", so I only use it when I'm
going to be getting and setting a slot frequently.
Moving from Poet Tk_Canvas_* objects to raw Tk's increased speed a lot. I would say in times.
E.g. when there are 50 shapes on the screen and I select them all a lot of handlers/resizers are drawn. Now it takes around a second against several before.