Re: [PD] Toggle Status

2011-04-23 Thread Saul

Hi All,

I'm sure this has been asked many times, but nothing comes up in an  
archive search.


I'm using a multiple toggles to activate each element of a sequence.  
Is it possible to interrogate the status of a toggle or in fact any  
gui object.


Thanks for any help,

/S



___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-23 Thread Mathieu Bouchard

On Sat, 23 Apr 2011, Saul wrote:

I'm using a multiple toggles to activate each element of a sequence. Is 
it possible to interrogate the status of a toggle or in fact any gui 
object.


If you have many toggles, you may have an incentive to use [#many] :

  http://gridflow.ca/help/%23many-help.html

from GridFlow : http://gridflow.ca/

You may plug it into [#to_l] to get a normal list, or use any of the many 
classes that can process grids. You can select one or more elements by row 
number and column number using [#store].


In the example of the web page, you have two sets of 91 toggles (13 rows 
of 7 toggles).


Some screenshots in action :

  http://gridflow.ca/gallery/qbert.pd.png
  http://gridflow.ca/gallery/pdmtl-33-image-many.png
  http://gridflow.ca/gallery/sequenceur.pd.png
  http://gridflow.ca/gallery/sequenceur.pd.mp3

and same thing with many numberboxes :

  http://gridflow.ca/gallery/bezier.png

 ___
| Mathieu Bouchard  tél: +1.514.383.3801  Villeray, Montréal, QC
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-23 Thread Hans-Christoph Steiner


banging most GUI objects will get their values. But with toggle, it  
changes it, so you would just need to connect the toggle to the right  
inlet of [float], and bang the left inlet when you want to know the  
toggle's state.


.hc

On Apr 23, 2011, at 12:00 PM, Saul wrote:


Hi All,

I'm sure this has been asked many times, but nothing comes up in an  
archive search.


I'm using a multiple toggles to activate each element of a sequence.  
Is it possible to interrogate the status of a toggle or in fact any  
gui object.


Thanks for any help,

/S



___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list





Access to computers should be unlimited and total.  - the hacker ethic



___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-23 Thread Jonathan Wilkes


--- On Sat, 4/23/11, Saul  wrote:

> From: Saul 
> Subject: Re: [PD] Toggle Status
> To: pd-list@iem.at
> Date: Saturday, April 23, 2011, 6:00 PM
> Hi All,
> 
> I'm sure this has been asked many times, but nothing comes
> up in an archive search.
> 
> I'm using a multiple toggles to activate each element of a
> sequence. Is it possible to interrogate the status of a
> toggle or in fact any gui object.

I haven't used it, but
there's a patch on the tracker that adds a "get" method to tgl:

http://sourceforge.net/tracker/index.php?func=detail&aid=2419952&group_id=55736&atid=478072

I think matju's #many abstraction is probably your best bet.

As for other GUIs-- [cnv] has a get_pos method to report it's x y position 
in a patch.

Also, I started coding a "get" method for canvases, which happens to do 
what Miller describes in his comment about the above patch.

-Jonathan

> 
> Thanks for any help,
> 
> /S
> 
> 
> 
> ___
> Pd-list@iem.at
> mailing list
> UNSUBSCRIBE and account-management -> 
> http://lists.puredata.info/listinfo/pd-list
> 

___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-26 Thread pierlu
Hi Saul

I had the same problem some years ago and I wrote the attached object
to achieve what you say, even if in an indirect way. Just connect the
toggle to the left inlet of fm and use it as a normal f object. When
you bang the right outlet tho, status is let out thru left object.

The name of the object it's not correct tho, but you can easily change
it yourself.

Cheers, p.

On Sat, Apr 23, 2011 at 6:00 PM, Saul  wrote:
> Hi All,
>
> I'm sure this has been asked many times, but nothing comes up in an archive
> search.
>
> I'm using a multiple toggles to activate each element of a sequence. Is it
> possible to interrogate the status of a toggle or in fact any gui object.
>
> Thanks for any help,
>
> /S
>
>
>
> ___
> Pd-list@iem.at mailing list
> UNSUBSCRIBE and account-management ->
> http://lists.puredata.info/listinfo/pd-list
>


fm.pd
Description: Binary data
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-26 Thread William Brent
I had to do this recently for a monome-ish thing.  There are already
good suggestions from others, but here's yet another approach: I ended
up making a table and accompanying abstraction for each column of the
grid so that clicking on the toggle at row N in any particular column
writes to index N of that column's table.  Then it's easy to check the
state of all toggles in a column with [tabread].


On Sat, Apr 23, 2011 at 12:00 PM, Saul  wrote:
> Hi All,
>
> I'm sure this has been asked many times, but nothing comes up in an archive
> search.
>
> I'm using a multiple toggles to activate each element of a sequence. Is it
> possible to interrogate the status of a toggle or in fact any gui object.
>
> Thanks for any help,
>
> /S
>
>
>
> ___
> Pd-list@iem.at mailing list
> UNSUBSCRIBE and account-management ->
> http://lists.puredata.info/listinfo/pd-list
>



-- 
William Brent
www.williambrent.com

“Great minds flock together”
Conflations: conversational idiom for the 21st century

www.conflations.com

___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-26 Thread IOhannes m zmoelnig
> 
> Also, I started coding a "get" method for canvases, which happens to do 
> what Miller describes in his comment about the above patch.
> 
so in the meantime you can either apply a diff to the sources of Pd, recompile
Pd and change your patch accordingly, so it is incompatible with all past 
versions of Pd (and
probably a number of future versions of Pd as well), or use [f] to store the
values of [tgl] and query them via bang, change your patch accordingly and be
happy.

i'm not saying that things should be kept deliberately complicated, but it is
really simple to implement what you need with what is there.

mfdst
IOhannes

PS: you could also "double bang" the toggle, which wil give you the current
value and will restore this value. or use "bang" + "set " to restore the
original.

___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-26 Thread Lorenzo Sutton
IOhannes m zmoelnig wrote:
>> Also, I started coding a "get" method for canvases, which happens to do 
>> what Miller describes in his comment about the above patch.
>>
> so in the meantime you can either apply a diff to the sources of Pd, recompile
> Pd and change your patch accordingly, so it is incompatible with all past 
> versions of Pd (and
> probably a number of future versions of Pd as well), or use [f] to store the
> values of [tgl] and query them via bang, change your patch accordingly and be
> happy.
>
> i'm not saying that things should be kept deliberately complicated, but it is
> really simple to implement what you need with what is there.

This question made me think. Is there a kind of reverse [route] object?
What I mean is something like:

[name_of_the_object_im_thinking_of 10]

Would create 10 inlets and 1 outlet. Sending "something" through inlet n
would output "n somwthing" which could for instance be saved in an array
eventually be re-used with a [route] etc.

This is of course easily created for a known number of "somethings" but
dynamic (as rout is) would be nice.

Hopefully I managed to explain what I mean.

Lorenzo.
> mfdst
> IOhannes
>
> PS: you could also "double bang" the toggle, which wil give you the current
> value and will restore this value. or use "bang" + "set " to restore 
> the
> original.
>
> ___
> Pd-list@iem.at mailing list
> UNSUBSCRIBE and account-management -> 
> http://lists.puredata.info/listinfo/pd-list
>

___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-26 Thread Frank Barknecht
Hi,

On Sun, Apr 24, 2011 at 05:47:44PM +0200, IOhannes m zmoelnig wrote:
> > Also, I started coding a "get" method for canvases, which happens to do 
> > what Miller describes in his comment about the above patch.
> > 
> so in the meantime you can either apply a diff to the sources of Pd, recompile
> Pd and change your patch accordingly, so it is incompatible with all past 
> versions of Pd (and
> probably a number of future versions of Pd as well), or use [f] to store the
> values of [tgl] and query them via bang, change your patch accordingly and be
> happy.
> 
> i'm not saying that things should be kept deliberately complicated, but it is
> really simple to implement what you need with what is there.
> 
> mfdst
> IOhannes
> 
> PS: you could also "double bang" the toggle, which wil give you the current
> value and will restore this value. or use "bang" + "set " to restore 
> the
> original.

PPS: Or make a GOP abstraction around [tgl] wrapping whatever added
functionality you desire into it. Attached is a [gtgl] abstraction with a "get"
method.

Ciao
-- 
 Frank BarknechtDo You RjDj.me?  _ __footils.org__


gtgl-help.pd
Description: application/puredata


gtgl.pd
Description: application/puredata
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-26 Thread Ingo
The easiest way to find out about the toggle status is to write all of the
switches into a table with [tabwrite] as you are changing the stataus. Then
you use [tabread] to check the status. No external required.

Ingo

> -Ursprüngliche Nachricht-
> Von: pd-list-boun...@iem.at [mailto:pd-list-boun...@iem.at] Im Auftrag von
> Saul
> Gesendet: Samstag, 23. April 2011 18:00
> An: pd-list@iem.at
> Betreff: Re: [PD] Toggle Status
> 
> Hi All,
> 
> I'm sure this has been asked many times, but nothing comes up in an
> archive search.
> 
> I'm using a multiple toggles to activate each element of a sequence.
> Is it possible to interrogate the status of a toggle or in fact any
> gui object.
> 
> Thanks for any help,


___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-26 Thread Jack
Or you can use [value] instead of [float] and its cold inlet.
++

Jack



Le samedi 23 avril 2011 à 14:13 -0400, Hans-Christoph Steiner a écrit :
> banging most GUI objects will get their values. But with toggle, it  
> changes it, so you would just need to connect the toggle to the right  
> inlet of [float], and bang the left inlet when you want to know the  
> toggle's state.
> 
> .hc
> 
> On Apr 23, 2011, at 12:00 PM, Saul wrote:
> 
> > Hi All,
> >
> > I'm sure this has been asked many times, but nothing comes up in an  
> > archive search.
> >
> > I'm using a multiple toggles to activate each element of a sequence.  
> > Is it possible to interrogate the status of a toggle or in fact any  
> > gui object.
> >
> > Thanks for any help,
> >
> > /S
> >
> >
> >
> > ___
> > Pd-list@iem.at mailing list
> > UNSUBSCRIBE and account-management -> 
> > http://lists.puredata.info/listinfo/pd-list
> 
> 
> 
> 
> Access to computers should be unlimited and total.  - the hacker ethic
> 
> 
> 
> ___
> Pd-list@iem.at mailing list
> UNSUBSCRIBE and account-management -> 
> http://lists.puredata.info/listinfo/pd-list



signature.asc
Description: This is a digitally signed message part
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-26 Thread Saul

Thank you all for your prompt responses.

I've managed it with select and float, a bit messy. many and gridflow  
look very interesting and the addition to toggle would be a good one.


Cheers,

/S 
  


___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Toggle Status

2011-04-26 Thread András Murányi
On Sat, Apr 23, 2011 at 18:00, Saul  wrote:

> Hi All,
>
> I'm sure this has been asked many times, but nothing comes up in an archive
> search.
>
> I'm using a multiple toggles to activate each element of a sequence. Is it
> possible to interrogate the status of a toggle or in fact any gui object.
>
> Thanks for any help,
>
> /S
>
> A possible workaround is to feed each toggle to the right inlet of an [i]
and then you can bang those [i]s anytime to get their values.

Andras
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list