py drawing to 3dview (Re: [Bf-committers] User-defined Material
Willian Padovani Germano
wgermano at superig.com.br
Tue Oct 18 23:42:41 CEST 2005
antont at kyperjokki.fi wrote:
> i know there is this principle that windows are separate etc. but such a
> script actually does not use the ScriptSpace, but is scriptlinked. so in a
> way the 3d view is the space that is uses. is there a problem with it? can we
> make it nice for 2.4?
Well, Ton devised space handlers for scripts to be able to get events
from and draw to a given space type (3d view currently, but it's easy to
add for others) in a way that fits with Blender's model.
But scriptlinks are also acceptable, afaik, so it's ok to use them if
space handlers are not adequate for some task (feedback on handlers is
always important to know if we can / should upgrade them, btw).
> also, such scripts suffer from the lack of Object.Changed scriptlink event
> type, 'cause they currently have to listen to Redraw() and check for possible
> changes in the object that they 'own' in python. so i think we must add such
> a scriptlink event type.
Yes, there are missing events. "OnSelect" used to be mentioned, as well
as "OnMouseClick", "OnKeyDown" (these two covered by event space
handlers), etc. A coder mentioned he had success with a listener
(sockets) event, too, but we got no news from him after that.
Now that space handlers are in place being used, we can see what's still
needed. Events for object changes, like you mention, and selection are
More information about the Bf-committers