Is anyone using the 'relocate' message to move/resize windows in Pd?
I ask because I want to simplify that code and the message itself in
pd-gui-rewrite 0.43. Its currently a very strange format, and it no
longer needs to be.
Here's the only working example that I know of: http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/doc/additional/p...
The idea is to make the message like this:
"relocate WIDTHxHEIGHT+XLoc+YLoc"
Currently its like this:
"relocate WIDTHxHEIGHT+0+0 0x0+XLoc+YLoc"
.hc
"[T]he greatest purveyor of violence in the world today [is] my own
government." - Martin Luther King, Jr.
I'm not using it, but can you simplify the vm geometry comand as well?
Is anyone using the 'relocate' message to move/resize windows in Pd? I
ask because I want to simplify that code and the message itself in
pd-gui-rewrite 0.43. Its currently a very strange format, and it no
longer needs to be.Here's the only working example that I know of: http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/doc/additional/p...
The idea is to make the message like this:
"relocate WIDTHxHEIGHT+XLoc+YLoc"
Currently its like this:
"relocate WIDTHxHEIGHT+0+0 0x0+XLoc+YLoc"
--- On Sun, 1/3/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: [PD] 'relocate' message To: "Pd List" pd-list@iem.at Date: Sunday, January 3, 2010, 12:00 AM
Is anyone using the 'relocate' message to move/resize windows in Pd? I ask because I want to simplify that code and the message itself in pd-gui-rewrite 0.43. Its currently a very strange format, and it no longer needs to be.
Here's the only working example that I know of: http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/doc/additional/p...
The idea is to make the message like this:
"relocate WIDTHxHEIGHT+XLoc+YLoc"
Currently its like this:
"relocate WIDTHxHEIGHT+0+0 0x0+XLoc+YLoc"
.hc
Hi Hans, Is there a reason the message can't simply be "relocate WIDTH HEIGHT XLoc Yloc"? Whether using pd-ext or vanilla, I've always thought it seems really awkward to cram the coordinates into one big symbol.
-Jonathan
On Jan 2, 2010, at 8:22 PM, Jonathan Wilkes wrote:
--- On Sun, 1/3/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: [PD] 'relocate' message To: "Pd List" pd-list@iem.at Date: Sunday, January 3, 2010, 12:00 AM
Is anyone using the 'relocate' message to move/resize windows in Pd? I ask because I want to simplify that code and the message itself in pd-gui-rewrite 0.43. Its currently a very strange format, and it no longer needs to be.
Here's the only working example that I know of: http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/doc/additional/p...
The idea is to make the message like this:
"relocate WIDTHxHEIGHT+XLoc+YLoc"
Currently its like this:
"relocate WIDTHxHEIGHT+0+0 0x0+XLoc+YLoc"
.hc
Hi Hans, Is there a reason the message can't simply be "relocate WIDTH
HEIGHT XLoc Yloc"? Whether using pd-ext or vanilla, I've always thought it
seems really awkward to cram the coordinates into one big symbol.-Jonathan
Hmm, that makes sense. I wonder if this should just have the same
syntax as 'canvas', so:
relocate x1 y1 x2 y2
Where x is the upper left corner, and y is the lower right corner.
.hc
There is no way to peace, peace is the way. -A.J. Muste
Currently, the help patches in the reference folder have two ways of referring to the "all_about_x" patches:
The first option requires the user to open the patch manually, which is klunky because the last patch opened is probably different than the reference folder (not to mention the fact that the reference folder has hundreds of patches in it). The second option currently stinks because pddplink is buggy (at least on winxp: for example, I can't open the link listed in ctlin-help.pd).
But what about using the "all_about_x" patches as abstractions in the relevant help patches? So for example: under the "more_info" heading in float-help.pd, instead of the comment "all_about_data-types.pd", just have [all_about_data-types], which the user can open with one click. Those patches aren't particularly complex, so it shouldn't affect load time of the help patches very much (I think), but it would greatly improve navigation. And unlike pddplink, typos would be obvious because the abstraction wouldn't create.
What do people think?
-Jonathan
Glad to see you thinking about improving the docs :) We tried the
abstraction thing before, but got in trouble because so much stuff got
loaded when loading a single help patch, then there were also
seemingly endless loops of loading.
I'd prefer to get pddplink working well and use it throughout. It
seems to be the best approach, provided it works. Can you describe
the problem with pddplink or provide an example patch?
.hc
On Jan 3, 2010, at 1:55 PM, Jonathan Wilkes wrote:
Currently, the help patches in the reference folder have two ways of referring to the "all_about_x" patches:
- comments in the form of "docs/reference/all_about_x
- pddplink
The first option requires the user to open the patch manually, which
is klunky because the last patch opened is probably different than the reference folder (not to mention the fact that the reference folder
has hundreds of patches in it). The second option currently stinks
because pddplink is buggy (at least on winxp: for example, I can't open the link listed in ctlin-help.pd).But what about using the "all_about_x" patches as abstractions in the relevant help patches? So for example: under the "more_info"
heading in float-help.pd, instead of the comment "all_about_data-types.pd",
just have [all_about_data-types], which the user can open with one click. Those patches aren't particularly complex, so it shouldn't affect load
time of the help patches very much (I think), but it would greatly improve navigation. And unlike pddplink, typos would be obvious because the
abstraction wouldn't create.What do people think?
-Jonathan
¡El pueblo unido jamás será vencido!
--- On Mon, 1/4/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: Re: Using "all_about_x" patches as abstractions in help files To: "Jonathan Wilkes" jancsika@yahoo.com Cc: "Pd List" pd-list@iem.at Date: Monday, January 4, 2010, 2:03 AM
Glad to see you thinking about improving the docs :) We tried the abstraction thing before, but got in trouble because so much stuff got loaded when loading a single help patch, then there were also seemingly endless loops of loading.
Well it wouldn't be a problem if you're only using abstractions in this manner in help patches and not in the "all_about_x" patches. But I guess this restriction means the method doesn't scale well.
I'd prefer to get pddplink working well and use it throughout. It seems to be the best approach, provided it works. Can you describe the problem with pddplink or provide an example patch?
I don't think pddplink likes spaces in the filename.
Ok, in windows xp open the pd browser and in the examples/pddp/, click on pddplink-test-01.pd. All the links should work. Now go in and change the name of the containing folder from "pddp" to "pddp bug". Now when you open that same patch, you'll get a tk error message for every [pddplink] object (excluding the ones with the -box flag).
But I don't understand why I don't see the error message in the first place, because pd/doc/examples/pddp/ is in the "Program Files" folder.
-Jonathan
.hc
On Jan 3, 2010, at 1:55 PM, Jonathan Wilkes wrote:
Currently, the help patches in the reference folder
have two ways of
referring to the "all_about_x" patches:
- comments in the form of
"docs/reference/all_about_x
- pddplink
The first option requires the user to open the patch
manually, which is
klunky because the last patch opened is probably
different than the
reference folder (not to mention the fact that the
reference folder has
hundreds of patches in it). The second option
currently stinks because
pddplink is buggy (at least on winxp: for example, I
can't open the
link listed in ctlin-help.pd).
But what about using the "all_about_x" patches as
abstractions in the
relevant help patches? So for example: under the
"more_info" heading in
float-help.pd, instead of the comment
"all_about_data-types.pd", just have
[all_about_data-types], which the user can open with
one click. Those
patches aren't particularly complex, so it shouldn't
affect load time of
the help patches very much (I think), but it would
greatly improve
navigation. And unlike pddplink, typos would be
obvious because the abstraction wouldn't create.
What do people think?
-Jonathan
¡El pueblo unido jamás será vencido!
Ok, found the bug, it was a quoting issue. Check tomorrow's build, or
build pddplink.dll yourself by going to externals/miXed/pddp and
running "make" the file will then be in externals/miXed/bin/
pddplink.dll
.hc
On Jan 3, 2010, at 10:55 PM, Jonathan Wilkes wrote:
--- On Mon, 1/4/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: Re: Using "all_about_x" patches as abstractions in help
files To: "Jonathan Wilkes" jancsika@yahoo.com Cc: "Pd List" pd-list@iem.at Date: Monday, January 4, 2010, 2:03 AMGlad to see you thinking about improving the docs :) We tried the abstraction thing before, but got in trouble because so much stuff got loaded when loading a single help patch, then there were also seemingly endless loops of loading.
Well it wouldn't be a problem if you're only using abstractions in
this manner in help patches and not in the "all_about_x" patches. But I
guess this restriction means the method doesn't scale well.I'd prefer to get pddplink working well and use it throughout. It seems to be the best approach, provided it works. Can you describe the problem with pddplink or provide an example patch?
I don't think pddplink likes spaces in the filename.
Ok, in windows xp open the pd browser and in the examples/pddp/,
click on pddplink-test-01.pd. All the links should work. Now go in and change the name of the containing folder from "pddp" to "pddp bug". Now when you open that same patch, you'll get a tk error message for every [pddplink] object (excluding the ones with the -box flag).But I don't understand why I don't see the error message in the first place, because pd/doc/examples/pddp/ is in the "Program Files" folder.
-Jonathan
.hc
On Jan 3, 2010, at 1:55 PM, Jonathan Wilkes wrote:
Currently, the help patches in the reference folder
have two ways of
referring to the "all_about_x" patches:
- comments in the form of
"docs/reference/all_about_x
- pddplink
The first option requires the user to open the patch
manually, which is
klunky because the last patch opened is probably
different than the
reference folder (not to mention the fact that the
reference folder has
hundreds of patches in it). The second option
currently stinks because
pddplink is buggy (at least on winxp: for example, I
can't open the
link listed in ctlin-help.pd).
But what about using the "all_about_x" patches as
abstractions in the
relevant help patches? So for example: under the
"more_info" heading in
float-help.pd, instead of the comment
"all_about_data-types.pd", just have
[all_about_data-types], which the user can open with
one click. Those
patches aren't particularly complex, so it shouldn't
affect load time of
the help patches very much (I think), but it would
greatly improve
navigation. And unlike pddplink, typos would be
obvious because the abstraction wouldn't create.
What do people think?
-Jonathan
¡El pueblo unido jamás será vencido!
I have always wished for my computer to be as easy to use as my
telephone; my wish has come true because I can no longer figure out
how to use my telephone." --Bjarne Stroustrup (creator of C++)
On Jan 3, 2010, at 1:14 AM, Hans-Christoph Steiner wrote:
On Jan 2, 2010, at 8:22 PM, Jonathan Wilkes wrote:
--- On Sun, 1/3/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: [PD] 'relocate' message To: "Pd List" pd-list@iem.at Date: Sunday, January 3, 2010, 12:00 AM
Is anyone using the 'relocate' message to move/resize windows in Pd? I ask because I want to simplify that code and the message itself in pd-gui-rewrite 0.43. Its currently a very strange format, and it no longer needs to be.
Here's the only working example that I know of: http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/doc/additional/p...
The idea is to make the message like this:
"relocate WIDTHxHEIGHT+XLoc+YLoc"
Currently its like this:
"relocate WIDTHxHEIGHT+0+0 0x0+XLoc+YLoc"
.hc
Hi Hans, Is there a reason the message can't simply be "relocate WIDTH
HEIGHT XLoc Yloc"? Whether using pd-ext or vanilla, I've always thought
it seems really awkward to cram the coordinates into one big symbol.-Jonathan
Hmm, that makes sense. I wonder if this should just have the same
syntax as 'canvas', so:relocate x1 y1 x2 y2
Where x is the upper left corner, and y is the lower right corner.
So I restored the old relocate message, and added a new message which
the GUI now uses a new message 'whxy'. 'whxy' stands for Width/Height/
X/Y. Width/Height is the size of the window, and (x,y) is where the
upper-left corner is located:
whxy width height xPosition yPosition whxy 450 300 0 22
I am now thinking that perhaps I should make it called 'setbounds'
after the old internal function, and make it mirror that:
canvas_setbounds(x, xpos, ypos, xpos + width, ypos + height);
i.e. "setbounds Xleft Ytop Xright Ybottom"
.hc
If nature has made any one thing less susceptible than all others of
exclusive property, it is the action of the thinking power called an
idea, which an individual may exclusively possess as long as he keeps
it to himself; but the moment it is divulged, it forces itself into
the possession of everyone, and the receiver cannot dispossess himself
of it. - Thomas Jefferson
On Jan 4, 2010, at 1:50 AM, Hans-Christoph Steiner wrote:
On Jan 3, 2010, at 1:14 AM, Hans-Christoph Steiner wrote:
On Jan 2, 2010, at 8:22 PM, Jonathan Wilkes wrote:
--- On Sun, 1/3/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: [PD] 'relocate' message To: "Pd List" pd-list@iem.at Date: Sunday, January 3, 2010, 12:00 AM
Is anyone using the 'relocate' message to move/resize windows in Pd? I ask because I want to simplify that code and the message itself in pd-gui-rewrite 0.43. Its currently a very strange format, and it no longer needs to be.
Here's the only working example that I know of: http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/doc/additional/p...
The idea is to make the message like this:
"relocate WIDTHxHEIGHT+XLoc+YLoc"
Currently its like this:
"relocate WIDTHxHEIGHT+0+0 0x0+XLoc+YLoc"
.hc
Hi Hans, Is there a reason the message can't simply be "relocate WIDTH
HEIGHT XLoc Yloc"? Whether using pd-ext or vanilla, I've always thought
it seems really awkward to cram the coordinates into one big symbol.-Jonathan
Hmm, that makes sense. I wonder if this should just have the same
syntax as 'canvas', so:relocate x1 y1 x2 y2
Where x is the upper left corner, and y is the lower right corner.
So I restored the old relocate message, and added a new message
which the GUI now uses a new message 'whxy'. 'whxy' stands for
Width/Height/X/Y. Width/Height is the size of the window, and (x,y)
is where the upper-left corner is located:whxy width height xPosition yPosition whxy 450 300 0 22
I am now thinking that perhaps I should make it called 'setbounds'
after the old internal function, and make it mirror that:canvas_setbounds(x, xpos, ypos, xpos + width, ypos + height);
i.e. "setbounds Xleft Ytop Xright Ybottom"
After a little discussion with Miller, this one seems to make the most
sense, so this is what the pd-gui-rewrite uses now.
http://pure-data.svn.sourceforge.net/viewvc/pure-data?view=rev&revision=...
.hc
If you are not part of the solution, you are part of the problem.
--- On Tue, 1/5/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: Re: [PD] 'relocate' message To: "Jonathan Wilkes" jancsika@yahoo.com, "PD List" pd-list@iem.at Date: Tuesday, January 5, 2010, 12:26 AM
On Jan 4, 2010, at 1:50 AM, Hans-Christoph Steiner wrote:
On Jan 3, 2010, at 1:14 AM, Hans-Christoph Steiner
wrote:
On Jan 2, 2010, at 8:22 PM, Jonathan Wilkes
wrote:
--- On Sun, 1/3/10, Hans-Christoph Steiner
hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: [PD] 'relocate' message To: "Pd List" pd-list@iem.at Date: Sunday, January 3, 2010, 12:00 AM
Is anyone using the 'relocate' message to
move/resize
windows in Pd? I ask because I want
to simplify that
code and the message itself in
pd-gui-rewrite 0.43.
Its currently a very strange format, and
it no longer needs
to be.
Here's the only working example that I
know of:
http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/doc/additional/p...
The idea is to make the message like
this:
"relocate WIDTHxHEIGHT+XLoc+YLoc"
Currently its like this:
"relocate WIDTHxHEIGHT+0+0
0x0+XLoc+YLoc"
.hc
Hi Hans, Is there a reason the message can't
simply be "relocate WIDTH HEIGHT
XLoc Yloc"? Whether using pd-ext or
vanilla, I've always thought it seems
really awkward to cram the coordinates into
one big symbol..
-Jonathan
Hmm, that makes sense. I wonder if this should
just have the same syntax as 'canvas', so:
relocate x1 y1 x2 y2
Where x is the upper left corner, and y is the
lower right corner.
So I restored the old relocate message, and added a
new message which the GUI now uses a new message 'whxy'. 'whxy' stands for Width/Height/X/Y. Width/Height is the size of the window, and (x,y) is where the upper-left corner is located:
whxy width height xPosition yPosition whxy 450 300 0 22
I am now thinking that perhaps I should make it called
'setbounds' after the old internal function, and make it mirror that:
canvas_setbounds(x, xpos, ypos, xpos +
width, ypos + height);
i.e. "setbounds Xleft Ytop Xright Ybottom"
After a little discussion with Miller, this one seems to make the most sense, so this is what the pd-gui-rewrite uses now.
http://pure-data.svn.sourceforge.net/viewvc/pure-data?view=rev&revision=...
That's great. I think "setbounds" is a much better name than "relocate"; it has a straightforward connection to the arguments (unlike "relocate").
Is there any way to have the iemgui messages "pos" and "delta" for canvases? For example, if I have a canvas with a bunch of subpatches that all have different sizes, but I want to move them all up to the top left-hand corner or the screen, "pos 0 0" would be really handy.
-Jonathan
On Jan 4, 2010, at 7:16 PM, Jonathan Wilkes wrote:
--- On Tue, 1/5/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: Re: [PD] 'relocate' message To: "Jonathan Wilkes" jancsika@yahoo.com, "PD List" <pd- list@iem.at> Date: Tuesday, January 5, 2010, 12:26 AM
On Jan 4, 2010, at 1:50 AM, Hans-Christoph Steiner wrote:
On Jan 3, 2010, at 1:14 AM, Hans-Christoph Steiner
wrote:
On Jan 2, 2010, at 8:22 PM, Jonathan Wilkes
wrote:
--- On Sun, 1/3/10, Hans-Christoph Steiner
hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: [PD] 'relocate' message To: "Pd List" pd-list@iem.at Date: Sunday, January 3, 2010, 12:00 AM
Is anyone using the 'relocate' message to
move/resize
windows in Pd? I ask because I want
to simplify that
code and the message itself in
pd-gui-rewrite 0.43.
Its currently a very strange format, and
it no longer needs
to be.
Here's the only working example that I
know of:
http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/doc/additional/p...
The idea is to make the message like
this:
"relocate WIDTHxHEIGHT+XLoc+YLoc"
Currently its like this:
"relocate WIDTHxHEIGHT+0+0
0x0+XLoc+YLoc"
.hc
Hi Hans, Is there a reason the message can't
simply be "relocate WIDTH HEIGHT
XLoc Yloc"? Whether using pd-ext or
vanilla, I've always thought it seems
really awkward to cram the coordinates into
one big symbol..
-Jonathan
Hmm, that makes sense. I wonder if this should
just have the same syntax as 'canvas', so:
relocate x1 y1 x2 y2
Where x is the upper left corner, and y is the
lower right corner.
So I restored the old relocate message, and added a
new message which the GUI now uses a new message 'whxy'. 'whxy' stands for Width/Height/X/Y. Width/Height is the size of the window, and (x,y) is where the upper-left corner is located:
whxy width height xPosition yPosition whxy 450 300 0 22
I am now thinking that perhaps I should make it called
'setbounds' after the old internal function, and make it mirror that:
canvas_setbounds(x, xpos, ypos, xpos +
width, ypos + height);
i.e. "setbounds Xleft Ytop Xright Ybottom"
After a little discussion with Miller, this one seems to make the most sense, so this is what the pd-gui-rewrite uses now.
http://pure-data.svn.sourceforge.net/viewvc/pure-data?view=rev&revision=...
That's great. I think "setbounds" is a much better name than
"relocate"; it has a straightforward connection to the arguments (unlike
"relocate").Is there any way to have the iemgui messages "pos" and "delta" for canvases? For example, if I have a canvas with a bunch of subpatches that all have different sizes, but I want to move them all up to the top left-hand corner or the screen, "pos 0 0" would be really handy.
The first two values of 'setbounds' are the same as 'pos', they are
the upper left corner. But you have to also set the lower right
too. This message is not really meant to be used a lot externally.
Its really a direct mapping of the data that Tk gives to the format
that Pd saves in the .pd file. Plus 'setbounds' doesn't even take
effect until you close and open the patch again.
.hc
Access to computers should be unlimited and total. - the hacker ethic
--- On Sun, 1/3/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: Re: [PD] 'relocate' message To: "Jonathan Wilkes" jancsika@yahoo.com Cc: "Pd List" pd-list@iem.at Date: Sunday, January 3, 2010, 7:14 AM
[...]
Hmm, that makes sense. I wonder if this should just have the same syntax as 'canvas', so:
relocate x1 y1 x2 y2
Where x is the upper left corner, and y is the lower right corner.
.hc
That's not right. The syntax of 'canvas' is: canvas topLeftX topLeftY Width Height (not including the menu/title bar)
-Jonathan
On Jan 6, 2010, at 4:02 PM, Jonathan Wilkes wrote:
--- On Sun, 1/3/10, Hans-Christoph Steiner hans@at.or.at wrote:
From: Hans-Christoph Steiner hans@at.or.at Subject: Re: [PD] 'relocate' message To: "Jonathan Wilkes" jancsika@yahoo.com Cc: "Pd List" pd-list@iem.at Date: Sunday, January 3, 2010, 7:14 AM
[...]
Hmm, that makes sense. I wonder if this should just have the same syntax as 'canvas', so:
relocate x1 y1 x2 y2
Where x is the upper left corner, and y is the lower right corner.
.hc
That's not right. The syntax of 'canvas' is: canvas topLeftX topLeftY Width Height (not including the menu/title
bar)-Jonathan
Hmm, you are indeed right. That's how the internal canvas_setbounds()
function specs the coords and how t_glist stores them, unfortunately...
.hc
"[W]e have invented the technology to eliminate scarcity, but we are
deliberately throwing it away to benefit those who profit from
scarcity." -John Gilmore