so, I have a data structure based GUI object, and say I just want it to display things and not really interact with it by clicking the data structures around, is it possible? Sorry if this is a stupid question, I just want to be sure.
So, say I have some shapes (for instance, a polygon) that can be controlled by messages and change something like its size. Now, because of that, if I go over the graph on parent and click on the corner of the polygon, I can drag and change the shape. Now, what if I want to prevent that from happening? Hints for tricks and hacks?
What I'm doing so far is I'm getting the values of these parameters with [get] and reset the value if they change with [set]. it seems to be doing the trick, but maybe there are other ways of doing this?
And maybe, just maybe, perhaps we could include an option, a flag, that an object is only for display? hmm? what you think?
cheers
I think Miller already introduced some options to switch off interaction in edit and run modes. Check the documentation of the latest Pd version (I can't do it now). Besides that, get and set are the way to go.
Am 29.11.2019 um 06:57 schrieb Alexandre Torres Porres:
so, I have a data structure based GUI object, and say I just want it to display things and not really interact with it by clicking the data structures around, is it possible? Sorry if this is a stupid question, I just want to be sure.
So, say I have some shapes (for instance, a polygon) that can be controlled by messages and change something like its size. Now, because of that, if I go over the graph on parent and click on the corner of the polygon, I can drag and change the shape. Now, what if I want to prevent that from happening? Hints for tricks and hacks?
What I'm doing so far is I'm getting the values of these parameters with [get] and reset the value if they change with [set]. it seems to be doing the trick, but maybe there are other ways of doing this?
And maybe, just maybe, perhaps we could include an option, a flag, that an object is only for display? hmm? what you think?
cheers
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
Em sex., 29 de nov. de 2019 às 06:01, João Pais jmmmpais@gmail.com escreveu:
Miller already introduced some options to switch off interaction in edit and run modes.
HELL YEAH!!!! :D
thanks ;) next time I'll RTFM!
cheers
Hi João
On Fri, 2019-11-29 at 09:51 +0100, João Pais wrote:
I think Miller already introduced some options to switch off interaction in edit and run modes.
Cool. I missed that, too. This is great news. I have a ton of now obsolete code to remove...
Check the documentation of the latest Pd version (I can't do it now).
It still says 'updated for 0.40.', though.
Roman
ha, that was actually a PR of mine. glad I'm not the only one who finds this useful :-) BTW, Miller just merged another PR where you can only disable moving vertices while still receiving mouse events. I thought this would be useful for building GUIs where you don't want users to (accidentally) change the shape of widgets.
Christof
Gesendet: Dienstag, 03. Dezember 2019 um 09:21 Uhr Von: "Roman Haefeli" reduzent@gmail.com An: pd-list@lists.iem.at Betreff: Re: [PD] data structures for display only, not interaction
Hi João
On Fri, 2019-11-29 at 09:51 +0100, João Pais wrote:
I think Miller already introduced some options to switch off interaction in edit and run modes.
Cool. I missed that, too. This is great news. I have a ton of now obsolete code to remove...
Check the documentation of the latest Pd version (I can't do it now).
It still says 'updated for 0.40.', though.
Roman
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list