[PD] Request - Deleting struct instances, progress?

Christof Ressi christof.ressi at gmx.at
Tue Jan 3 12:41:59 CET 2017


yeah, "vis 1" and "vis 0" is necessary if the window is not visible. Forget to mention that. Thanks!
 

Gesendet: Dienstag, 03. Januar 2017 um 12:29 Uhr
Von: "João Pais" <jmmmpais at gmail.com>
An: "Christof Ressi" <christof.ressi at gmx.at>
Cc: "Derek Kwan" <derek.x.kwan at gmail.com>, "Jonathan Wilkes via Pd-list" <pd-list at lists.iem.at>
Betreff: Re: [PD] Request - Deleting struct instances, progress?

 
in the meantime, here's a little hack how to delete specific scalar instances (as long the scalar has a drawing instruction and is visible + editable). get the scalar's x + y coordinates with [get], then send following message to the subpatch containing the scalar:
[mouse x y 1 0, mouseup x y 1, key 1 8 0(
 
what you can also do is to put a "vis 1" before and "vis 0" after those commands. in my experience, it opens up and closes the window so fast, that one doesn't see it happening. (I didn't try it with pointers, just with normal objects - but that's the same for the mouse) it should work even if the scalar is outside the window borders.
regarding the drawing instruction, don't all scalars have the x y coordinates, even if they're not defined in the template? in that case, the scalars without a drawing should be automatically at the coordinates 0 0 - which can be dangerous in case you use your scalars just to store (and not display) data, because all of them will be positioned at 0 0.
all this I can't test now, I'm just replying from memory.
 > I suppose since we're doing this about feature requests, I'd like to ask

> about deleting instances of structs in linked lists =).
 
that has been asked for a while. also with a "previous" method, instead of just "next".
 
Best,
 
jmmmp



More information about the Pd-list mailing list