Re: Window manager plugin?

2014-08-26 Thread Peter M. Brigham
Nice. Don't forget to reset the templatestack.

-- Peter

Peter M. Brigham
pmb...@gmail.com
http://home.comcast.net/~pmbrig

On Aug 25, 2014, at 3:49 PM, Mark Schonewille wrote:

 John,
 
 Here's my complete solution:
 
 on mouseUp
 put item 1 of the screenLoc  comma   round(item 2 of the screenLoc / 3) 
 into myLoc
 askAt Hello,Write something,myLoc
 if it is not empty then
  answerAt You wrote:  the result,myLoc,Yep,Nope
 end if
 put the result
 end mouseUp
 
 on answerAt theMessage,theLoc
 put answer information  quote  theMessage  quote  with  space 
 into myScript
 if the paramCount is 2 then
  put quote  OK  quote after myScript
 else
  put quote  param(3)  quote after myScript
  repeat with x = 4 to the paramCount
   put space  or  quote  param(x)  quote after myScript
  end repeat
 end if
 set the loc of the templateStack to theLoc
 set the vis of the templateStack to false
 create stack Place Holder
 set the defaultStack to Place Holder
 do myScript
 delete stack Place Holder
 return it
 end answerAt
 
 on askAt theMessage,theDefault,theLoc
 put ask question  quote  theMessage  quote  with  quote  
 theDefault  quote into myScript
 set the loc of the templateStack to theLoc
 set the vis of the templateStack to false
 create stack Place Holder
 set the defaultStack to Place Holder
 do myScript
 delete stack Place Holder
 return it
 end askAt
 
 The advantage of this approach is that it only depends on the ask and answer 
 stacks and still works if the lockMessages has been set to true. It would 
 need some adjustments if you want to use unicode or HTML.
 
 --
 Best regards,
 
 Mark Schonewille
 
 Economy-x-Talk Consulting and Software Engineering
 Homepage: http://economy-x-talk.com
 Twitter: http://twitter.com/xtalkprogrammer
 KvK: 50277553
 
 Installer Maker for LiveCode:
 http://qery.us/468
 
 Buy my new book Programming LiveCode for the Real Beginner 
 http://qery.us/3fi
 
 LiveCode on Facebook:
 https://www.facebook.com/groups/runrev/
 
 On 8/23/2014 13:07, Mark Schonewille wrote:
 Hi John,
 
 No, but that should be easy. There are several ways to do this. For example, 
 create an invisible stack, set its location to the location where you want 
 the answer dialog. Set the defaultStack to this stack and execute the ask or 
 answer command. There may be more elegant ways.
 
 set the topleft of the templateStack to 0,32
 set the vis of the templateStack to false
 create stack place holder
 set the defaultStack to it
 answer bla
 put it into myAnswer
 delete stack Place Holder
 
 This should work on windows and probably also on Mac, but on Mac I almost 
 always use ask/answer as sheet.
 
 --
 Kind regards,
 
 Mark Schonewille
 Economy-x-Talk
 Http://economy-x-talk.com
 
 Share the clipboard of your computer over a local network with Clipboard 
 Link http://clipboardlink.economy-x-talk.com
 
 
 Op 23 aug. 2014 om 02:50 heeft JB sund...@pacifier.com het volgende 
 geschreven:
 
 Hi Mark,
 
 Will that let you position the ask and answer dialogs?
 
 John Balgenorth
 
 
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-26 Thread JB
Thank you very much, Mark!!

That is really nice!

John Balgenorth


On Aug 25, 2014, at 12:49 PM, Mark Schonewille 
m.schonewi...@economy-x-talk.com wrote:

 John,
 
 Here's my complete solution:
 
 on mouseUp
 put item 1 of the screenLoc  comma   round(item 2 of the screenLoc / 3) 
 into myLoc
 askAt Hello,Write something,myLoc
 if it is not empty then
  answerAt You wrote:  the result,myLoc,Yep,Nope
 end if
 put the result
 end mouseUp
 
 on answerAt theMessage,theLoc
 put answer information  quote  theMessage  quote  with  space 
 into myScript
 if the paramCount is 2 then
  put quote  OK  quote after myScript
 else
  put quote  param(3)  quote after myScript
  repeat with x = 4 to the paramCount
   put space  or  quote  param(x)  quote after myScript
  end repeat
 end if
 set the loc of the templateStack to theLoc
 set the vis of the templateStack to false
 create stack Place Holder
 set the defaultStack to Place Holder
 do myScript
 delete stack Place Holder
 return it
 end answerAt
 
 on askAt theMessage,theDefault,theLoc
 put ask question  quote  theMessage  quote  with  quote  
 theDefault  quote into myScript
 set the loc of the templateStack to theLoc
 set the vis of the templateStack to false
 create stack Place Holder
 set the defaultStack to Place Holder
 do myScript
 delete stack Place Holder
 return it
 end askAt
 
 The advantage of this approach is that it only depends on the ask and answer 
 stacks and still works if the lockMessages has been set to true. It would 
 need some adjustments if you want to use unicode or HTML.
 
 --
 Best regards,
 
 Mark Schonewille
 
 Economy-x-Talk Consulting and Software Engineering
 Homepage: http://economy-x-talk.com
 Twitter: http://twitter.com/xtalkprogrammer
 KvK: 50277553
 
 Installer Maker for LiveCode:
 http://qery.us/468
 
 Buy my new book Programming LiveCode for the Real Beginner 
 http://qery.us/3fi
 
 LiveCode on Facebook:
 https://www.facebook.com/groups/runrev/
 
 On 8/23/2014 13:07, Mark Schonewille wrote:
 Hi John,
 
 No, but that should be easy. There are several ways to do this. For example, 
 create an invisible stack, set its location to the location where you want 
 the answer dialog. Set the defaultStack to this stack and execute the ask or 
 answer command. There may be more elegant ways.
 
 set the topleft of the templateStack to 0,32
 set the vis of the templateStack to false
 create stack place holder
 set the defaultStack to it
 answer bla
 put it into myAnswer
 delete stack Place Holder
 
 This should work on windows and probably also on Mac, but on Mac I almost 
 always use ask/answer as sheet.
 
 --
 Kind regards,
 
 Mark Schonewille
 Economy-x-Talk
 Http://economy-x-talk.com
 
 Share the clipboard of your computer over a local network with Clipboard 
 Link http://clipboardlink.economy-x-talk.com
 
 
 Op 23 aug. 2014 om 02:50 heeft JB sund...@pacifier.com het volgende 
 geschreven:
 
 Hi Mark,
 
 Will that let you position the ask and answer dialogs?
 
 John Balgenorth
 
 
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-26 Thread Mark Schonewille

Hi Peter,

You're right. I thought of it, but forgot to add it.

--
Best regards,

Mark Schonewille

Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
KvK: 50277553

Installer Maker for LiveCode:
http://qery.us/468

Buy my new book Programming LiveCode for the Real Beginner 
http://qery.us/3fi


LiveCode on Facebook:
https://www.facebook.com/groups/runrev/

On 8/26/2014 13:33, Peter M. Brigham wrote:

Nice. Don't forget to reset the templatestack.

-- Peter




___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-26 Thread J. Landman Gay

On 8/26/2014, 7:01 AM, JB wrote:

Thank you very much, Mark!!

That is really nice!


Unfortunately, I couldn't get Mark's answer and ask handlers to work on 
Mac. On Windows the default position is at the location of the default 
stack, which is why it works there. On Mac, it looks like you'll need to 
hide the window and move it after it is displayed, or use Scott Rossi's 
suspendStack solution.


--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-26 Thread Mark Schonewille

Jacque,

It is true that it doesn't work on Mac, but I never needed something 
like this on Mac. I made this specifically for Windows. On Mac I use as 
sheet most of the time.


--
Best regards,

Mark Schonewille

Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
KvK: 50277553

Installer Maker for LiveCode:
http://qery.us/468

Buy my new book Programming LiveCode for the Real Beginner 
http://qery.us/3fi


LiveCode on Facebook:
https://www.facebook.com/groups/runrev/

On 8/26/2014 19:55, J. Landman Gay wrote:

On 8/26/2014, 7:01 AM, JB wrote:

Thank you very much, Mark!!

That is really nice!


Unfortunately, I couldn't get Mark's answer and ask handlers to work on
Mac. On Windows the default position is at the location of the default
stack, which is why it works there. On Mac, it looks like you'll need to
hide the window and move it after it is displayed, or use Scott Rossi's
suspendStack solution.



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-25 Thread Mark Schonewille

John,

Here's my complete solution:

on mouseUp
 put item 1 of the screenLoc  comma   round(item 2 of the 
screenLoc / 3) into myLoc

 askAt Hello,Write something,myLoc
 if it is not empty then
  answerAt You wrote:  the result,myLoc,Yep,Nope
 end if
 put the result
end mouseUp

on answerAt theMessage,theLoc
 put answer information  quote  theMessage  quote  with  
space into myScript

 if the paramCount is 2 then
  put quote  OK  quote after myScript
 else
  put quote  param(3)  quote after myScript
  repeat with x = 4 to the paramCount
   put space  or  quote  param(x)  quote after myScript
  end repeat
 end if
 set the loc of the templateStack to theLoc
 set the vis of the templateStack to false
 create stack Place Holder
 set the defaultStack to Place Holder
 do myScript
 delete stack Place Holder
 return it
end answerAt

on askAt theMessage,theDefault,theLoc
 put ask question  quote  theMessage  quote  with  
quote  theDefault  quote into myScript

 set the loc of the templateStack to theLoc
 set the vis of the templateStack to false
 create stack Place Holder
 set the defaultStack to Place Holder
 do myScript
 delete stack Place Holder
 return it
end askAt

The advantage of this approach is that it only depends on the ask and 
answer stacks and still works if the lockMessages has been set to true. 
It would need some adjustments if you want to use unicode or HTML.


--
Best regards,

Mark Schonewille

Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
KvK: 50277553

Installer Maker for LiveCode:
http://qery.us/468

Buy my new book Programming LiveCode for the Real Beginner 
http://qery.us/3fi


LiveCode on Facebook:
https://www.facebook.com/groups/runrev/

On 8/23/2014 13:07, Mark Schonewille wrote:

Hi John,

No, but that should be easy. There are several ways to do this. For example, 
create an invisible stack, set its location to the location where you want the 
answer dialog. Set the defaultStack to this stack and execute the ask or answer 
command. There may be more elegant ways.

set the topleft of the templateStack to 0,32
set the vis of the templateStack to false
create stack place holder
set the defaultStack to it
answer bla
put it into myAnswer
delete stack Place Holder

This should work on windows and probably also on Mac, but on Mac I almost 
always use ask/answer as sheet.

--
Kind regards,

Mark Schonewille
Economy-x-Talk
Http://economy-x-talk.com

Share the clipboard of your computer over a local network with Clipboard Link 
http://clipboardlink.economy-x-talk.com


Op 23 aug. 2014 om 02:50 heeft JB sund...@pacifier.com het volgende 
geschreven:


Hi Mark,

Will that let you position the ask and answer dialogs?

John Balgenorth





___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread Mark Schonewille
Hi John,

No, but that should be easy. There are several ways to do this. For example, 
create an invisible stack, set its location to the location where you want the 
answer dialog. Set the defaultStack to this stack and execute the ask or answer 
command. There may be more elegant ways.

set the topleft of the templateStack to 0,32
set the vis of the templateStack to false
create stack place holder
set the defaultStack to it
answer bla
put it into myAnswer
delete stack Place Holder

This should work on windows and probably also on Mac, but on Mac I almost 
always use ask/answer as sheet.

--
Kind regards,

Mark Schonewille
Economy-x-Talk
Http://economy-x-talk.com

Share the clipboard of your computer over a local network with Clipboard Link 
http://clipboardlink.economy-x-talk.com


Op 23 aug. 2014 om 02:50 heeft JB sund...@pacifier.com het volgende 
geschreven:

 Hi Mark,
 
 Will that let you position the ask and answer dialogs?
 
 John Balgenorth
 
 
 On Aug 22, 2014, at 5:14 PM, Mark Schonewille 
 m.schonewi...@economy-x-talk.com wrote:
 
 Hi Charles,
 
 I made a plug-in (donationware) which makes sure that windows open inside a 
 visible screen rect and not off-screen. I could extend it and make it 
 remember window positions.
 
 --
 
 Economy-x-Talk
 Consultancy and Software Engineering
 http://economy-x-talk.com
 
 Download Color Converter at http://www.color-converter.com
 
 Op 23-aug-2014, om 2:04 heeft Charles E Buchwald het volgende geschreven:
 
 Hi List Folks,
 
 I've been thinking about making a plugin that manages window positions or 
 window layouts. If you are familiar with Adobe applications like 
 Illustrator, Photoshop or InDesign, then you may have an idea of what I 
 mean. Or perhaps you have used system-level utilities like Moom, Divvy, 
 Shiftit, GridMove or WindowTidy.
 
 The idea is that you can save the position of one or more of your windows, 
 including IDE palettes and so on, as a named set. Then you can switch back 
 to those positions when you select that set again.
 
 So, for example, one might have a window layout for working on iPhone apps 
 and another for tablet apps... or one for a dual monitor setup vs. a single 
 monitor setup... or for working on server scripts... or all of the above. I 
 switch back and forth between my laptop on its own, and my laptop open and 
 next to a second monitor, so this would be really useful.
 
 Firstly: does anyone know of an existing LC plugin like this?
 
 And of course: is anyone else interested in a plugin like this?
 
 Cheers,
 - Charles
 
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread Scott Rossi

 
 Will that let you position the ask and answer dialogs?
 
 John Balgenorth
 
 



Here's one way to position ask/answer dialogs on desktop:

[ in your stack script ]

on suspendStack
   if ask dialog is among the lines of the openStacks then
  set the loc of stack ask dialog to the loc of me
   end if
end suspendStack


on suspendStack
   if answer dialog is among the lines of the openStacks then
  set the loc of stack answer dialog to the loc of me
   end if
end suspendStack



( can replace loc of me with any desired screenLoc )


Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread JB
Hi Scott,

I put the script in my stack script and it continued to
show the answer dialog in the center of the screen.
So I replaced llc with “112,110” and  nothing changed.

Then I added put the openStacks into the mouseUp
handler where the answer dialog is called from.  If it
is at the very beginning of the handler it puts the open
stacks in the message box.  But if it is before or after
the answer script nothing is put in the message
box.

John Balgenorth


On Aug 23, 2014, at 8:54 AM, Scott Rossi sc...@tactilemedia.com wrote:

 
 
 Will that let you position the ask and answer dialogs?
 
 John Balgenorth
 
 
 
 
 
 Here's one way to position ask/answer dialogs on desktop:
 
 [ in your stack script ]
 
 on suspendStack
   if ask dialog is among the lines of the openStacks then
  set the loc of stack ask dialog to the loc of me
   end if
 end suspendStack
 
 
 on suspendStack
   if answer dialog is among the lines of the openStacks then
  set the loc of stack answer dialog to the loc of me
   end if
 end suspendStack
 
 
 
 ( can replace loc of me with any desired screenLoc )
 
 
 Regards,
 
 Scott Rossi
 Creative Director
 Tactile Media, UX/UI Design
 
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread Richard Gaskin

Scott Rossi wrote:


Here's one way to position ask/answer dialogs on desktop:

[ in your stack script ]

on suspendStack
   if ask dialog is among the lines of the openStacks then
  set the loc of stack ask dialog to the loc of me
   end if
end suspendStack


on suspendStack
   if answer dialog is among the lines of the openStacks then
  set the loc of stack answer dialog to the loc of me
   end if
end suspendStack

( can replace loc of me with any desired screenLoc )


On Windows and Linux centering to the topstack is already the default 
behavior.


On OS X, if an alert applies application-wide the HIG suggest the 
standard alert location (horizontally centered, 2/5 of the way down from 
the top vertically).


When you need an answer dialog to apply to a single window, you can get 
both enhanced behavior and window-specific location using the as sheet 
modifier:


  answer Something as sheet

Not only will this use OS X's recommended sheet appearance, but on all 
platforms the alert box will be modal only to the stack over which is 
appears, allowing the user to continue to interact with other windows.


That said, from time to time we're asked to do things outside of the HIG 
recommendations, and there's a request for being able to set the loc of 
the ask and answer dialogs in the RQCC:

http://quality.runrev.com/show_bug.cgi?id=4309

--
 Richard Gaskin
 Fourth World Systems
 Software Design and Development for the Desktop, Mobile, and the Web
 
 ambassa...@fourthworld.comhttp://www.FourthWorld.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread Scott Rossi
I should have clarified that I listed two scripts: one for answer, one for
ask.  But the script is working here for all versions of LC, Mac and Win,
including v7.  Not sure what to tell you.  Did you try the script in a
new, empty stack?

Something like this would be better to be all-inclusive:

on suspendStack
   put the openStacks into theList
   if answer dialog is among the lines of theList then set the loc of
stack answer dialog to loc of me
   if ask dialog is among the lines of theList then set the loc of stack
ask dialog to loc of me
end suspendStack


Historically, there has been no approved way to position the dialogs
that I know of.  This method was suggested a long time ago (can't recall
by who) but it works for me.

Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design




On 8/23/14 9:25 AM, JB sund...@pacifier.com wrote:

Hi Scott,

I put the script in my stack script and it continued to
show the answer dialog in the center of the screen.
So I replaced llc with ³112,110² and  nothing changed.

Then I added put the openStacks into the mouseUp
handler where the answer dialog is called from.  If it
is at the very beginning of the handler it puts the open
stacks in the message box.  But if it is before or after
the answer script nothing is put in the message
box.

John Balgenorth


On Aug 23, 2014, at 8:54 AM, Scott Rossi sc...@tactilemedia.com wrote:

 
 
 Will that let you position the ask and answer dialogs?
 
 John Balgenorth
 
 
 
 
 
 Here's one way to position ask/answer dialogs on desktop:
 
 [ in your stack script ]
 
 on suspendStack
   if ask dialog is among the lines of the openStacks then
  set the loc of stack ask dialog to the loc of me
   end if
 end suspendStack
 
 
 on suspendStack
   if answer dialog is among the lines of the openStacks then
  set the loc of stack answer dialog to the loc of me
   end if
 end suspendStack
 
 
 
 ( can replace loc of me with any desired screenLoc )
 
 
 Regards,
 
 Scott Rossi
 Creative Director
 Tactile Media, UX/UI Design
 
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread JB
Thanks for the info, Richard.

John Balgenorth


On Aug 23, 2014, at 9:59 AM, Richard Gaskin ambassa...@fourthworld.com wrote:

 Scott Rossi wrote:
 
 Here's one way to position ask/answer dialogs on desktop:
 
 [ in your stack script ]
 
 on suspendStack
   if ask dialog is among the lines of the openStacks then
  set the loc of stack ask dialog to the loc of me
   end if
 end suspendStack
 
 
 on suspendStack
   if answer dialog is among the lines of the openStacks then
  set the loc of stack answer dialog to the loc of me
   end if
 end suspendStack
 
 ( can replace loc of me with any desired screenLoc )
 
 On Windows and Linux centering to the topstack is already the default 
 behavior.
 
 On OS X, if an alert applies application-wide the HIG suggest the standard 
 alert location (horizontally centered, 2/5 of the way down from the top 
 vertically).
 
 When you need an answer dialog to apply to a single window, you can get both 
 enhanced behavior and window-specific location using the as sheet modifier:
 
  answer Something as sheet
 
 Not only will this use OS X's recommended sheet appearance, but on all 
 platforms the alert box will be modal only to the stack over which is 
 appears, allowing the user to continue to interact with other windows.
 
 That said, from time to time we're asked to do things outside of the HIG 
 recommendations, and there's a request for being able to set the loc of the 
 ask and answer dialogs in the RQCC:
 http://quality.runrev.com/show_bug.cgi?id=4309
 
 --
 Richard Gaskin
 Fourth World Systems
 Software Design and Development for the Desktop, Mobile, and the Web
 
 ambassa...@fourthworld.comhttp://www.FourthWorld.com
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread JB
Thanks Scott.

I cannot believe how dumb I am somedays.
The problem was I pasted the code as it was
in my openStack handler and after looking at
it I see they both call the same thing.

Your latest version fixed it.

thank again.

John Balgenorth


On Aug 23, 2014, at 10:07 AM, Scott Rossi sc...@tactilemedia.com wrote:

 I should have clarified that I listed two scripts: one for answer, one for
 ask.  But the script is working here for all versions of LC, Mac and Win,
 including v7.  Not sure what to tell you.  Did you try the script in a
 new, empty stack?
 
 Something like this would be better to be all-inclusive:
 
 on suspendStack
   put the openStacks into theList
   if answer dialog is among the lines of theList then set the loc of
 stack answer dialog to loc of me
   if ask dialog is among the lines of theList then set the loc of stack
 ask dialog to loc of me
 end suspendStack
 
 
 Historically, there has been no approved way to position the dialogs
 that I know of.  This method was suggested a long time ago (can't recall
 by who) but it works for me.
 
 Regards,
 
 Scott Rossi
 Creative Director
 Tactile Media, UX/UI Design
 
 
 
 
 On 8/23/14 9:25 AM, JB sund...@pacifier.com wrote:
 
 Hi Scott,
 
 I put the script in my stack script and it continued to
 show the answer dialog in the center of the screen.
 So I replaced llc with ³112,110² and  nothing changed.
 
 Then I added put the openStacks into the mouseUp
 handler where the answer dialog is called from.  If it
 is at the very beginning of the handler it puts the open
 stacks in the message box.  But if it is before or after
 the answer script nothing is put in the message
 box.
 
 John Balgenorth
 
 
 On Aug 23, 2014, at 8:54 AM, Scott Rossi sc...@tactilemedia.com wrote:
 
 
 
 Will that let you position the ask and answer dialogs?
 
 John Balgenorth
 
 
 
 
 
 Here's one way to position ask/answer dialogs on desktop:
 
 [ in your stack script ]
 
 on suspendStack
  if ask dialog is among the lines of the openStacks then
 set the loc of stack ask dialog to the loc of me
  end if
 end suspendStack
 
 
 on suspendStack
  if answer dialog is among the lines of the openStacks then
 set the loc of stack answer dialog to the loc of me
  end if
 end suspendStack
 
 
 
 ( can replace loc of me with any desired screenLoc )
 
 
 Regards,
 
 Scott Rossi
 Creative Director
 Tactile Media, UX/UI Design
 
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your
 subscription preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your
 subscription preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread J. Landman Gay

On 8/23/2014, 12:07 PM, Scott Rossi wrote:

I should have clarified that I listed two scripts: one for answer, one for
ask.  But the script is working here for all versions of LC, Mac and Win,
including v7.  Not sure what to tell you.  Did you try the script in a
new, empty stack?

Something like this would be better to be all-inclusive:

on suspendStack
put the openStacks into theList
if answer dialog is among the lines of theList then set the loc of
stack answer dialog to loc of me
if ask dialog is among the lines of theList then set the loc of stack
ask dialog to loc of me
end suspendStack


I needed this once, and tried this suggestion but I couldn't get it to 
work either. I'm not sure why. I settled on this hack:


on answerWithLoc pString,pBtn1,pBtn2
  set the vis of stack answer dialog to false
  answer pString with pBtn1 and pBtn2
  set the loc of stack answer dialog to the loc of this stack
  set the vis of stack answer dialog to true
end answerWithLoc

--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread Scott Rossi
If you haven't already, try the script in an empty stack -- should work as
expected.  I doubt my systems have any special mojo going on (usually I
get curses, plagues, and the occasional hex).

Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design




On 8/23/14 11:06 AM, J. Landman Gay jac...@hyperactivesw.com wrote:

On 8/23/2014, 12:07 PM, Scott Rossi wrote:
 I should have clarified that I listed two scripts: one for answer, one
for
 ask.  But the script is working here for all versions of LC, Mac and
Win,
 including v7.  Not sure what to tell you.  Did you try the script in a
 new, empty stack?

 Something like this would be better to be all-inclusive:

 on suspendStack
 put the openStacks into theList
 if answer dialog is among the lines of theList then set the loc of
 stack answer dialog to loc of me
 if ask dialog is among the lines of theList then set the loc of
stack
 ask dialog to loc of me
 end suspendStack

I needed this once, and tried this suggestion but I couldn't get it to
work either. I'm not sure why. I settled on this hack:

on answerWithLoc pString,pBtn1,pBtn2
   set the vis of stack answer dialog to false
   answer pString with pBtn1 and pBtn2
   set the loc of stack answer dialog to the loc of this stack
   set the vis of stack answer dialog to true
end answerWithLoc

-- 
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread JB
Thanks, Jacque.

It is nice to have some more code examples.  I was
able to get it to work okay but if I use answer warning
the warning icon does not show.  Is there a way to
get it to show up with this code?

John Balgenorth


On Aug 23, 2014, at 11:06 AM, J. Landman Gay jac...@hyperactivesw.com wrote:

 On 8/23/2014, 12:07 PM, Scott Rossi wrote:
 I should have clarified that I listed two scripts: one for answer, one for
 ask.  But the script is working here for all versions of LC, Mac and Win,
 including v7.  Not sure what to tell you.  Did you try the script in a
 new, empty stack?
 
 Something like this would be better to be all-inclusive:
 
 on suspendStack
put the openStacks into theList
if answer dialog is among the lines of theList then set the loc of
 stack answer dialog to loc of me
if ask dialog is among the lines of theList then set the loc of stack
 ask dialog to loc of me
 end suspendStack
 
 I needed this once, and tried this suggestion but I couldn't get it to work 
 either. I'm not sure why. I settled on this hack:
 
 on answerWithLoc pString,pBtn1,pBtn2
  set the vis of stack answer dialog to false
  answer pString with pBtn1 and pBtn2
  set the loc of stack answer dialog to the loc of this stack
  set the vis of stack answer dialog to true
 end answerWithLoc
 
 -- 
 Jacqueline Landman Gay | jac...@hyperactivesw.com
 HyperActive Software   | http://www.hyperactivesw.com
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread J. Landman Gay
I believe you. I needed it for The Big Project, which already has a 
suspendStack handler, and I was trying to integrate your part. There's a 
backscript too with a few thousand lines of code that traps most system 
messages. I never bothered to figure out why it didn't work, I just 
plugged in my custom handler because it doesn't rely on any system messages.


Your way is cleaner but I needed a hack.

On 8/23/2014, 1:17 PM, Scott Rossi wrote:

If you haven't already, try the script in an empty stack -- should work as
expected.  I doubt my systems have any special mojo going on (usually I
get curses, plagues, and the occasional hex).

Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design




On 8/23/14 11:06 AM, J. Landman Gay jac...@hyperactivesw.com wrote:


On 8/23/2014, 12:07 PM, Scott Rossi wrote:

I should have clarified that I listed two scripts: one for answer, one
for
ask.  But the script is working here for all versions of LC, Mac and
Win,
including v7.  Not sure what to tell you.  Did you try the script in a
new, empty stack?

Something like this would be better to be all-inclusive:

on suspendStack
 put the openStacks into theList
 if answer dialog is among the lines of theList then set the loc of
stack answer dialog to loc of me
 if ask dialog is among the lines of theList then set the loc of
stack
ask dialog to loc of me
end suspendStack


I needed this once, and tried this suggestion but I couldn't get it to
work either. I'm not sure why. I settled on this hack:

on answerWithLoc pString,pBtn1,pBtn2
   set the vis of stack answer dialog to false
   answer pString with pBtn1 and pBtn2
   set the loc of stack answer dialog to the loc of this stack
   set the vis of stack answer dialog to true
end answerWithLoc

--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode




___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode




--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread Scott Rossi
Ooo.  I smell a t-shirt to be made:

Your way is clean, but I need a hack.

Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design




On 8/23/14 11:50 AM, J. Landman Gay jac...@hyperactivesw.com wrote:

I believe you. I needed it for The Big Project, which already has a
suspendStack handler, and I was trying to integrate your part. There's a
backscript too with a few thousand lines of code that traps most system
messages. I never bothered to figure out why it didn't work, I just
plugged in my custom handler because it doesn't rely on any system
messages.

Your way is cleaner but I needed a hack.

On 8/23/2014, 1:17 PM, Scott Rossi wrote:
 If you haven't already, try the script in an empty stack -- should work
as
 expected.  I doubt my systems have any special mojo going on (usually I
 get curses, plagues, and the occasional hex).

 Regards,

 Scott Rossi
 Creative Director
 Tactile Media, UX/UI Design




 On 8/23/14 11:06 AM, J. Landman Gay jac...@hyperactivesw.com wrote:

 On 8/23/2014, 12:07 PM, Scott Rossi wrote:
 I should have clarified that I listed two scripts: one for answer, one
 for
 ask.  But the script is working here for all versions of LC, Mac and
 Win,
 including v7.  Not sure what to tell you.  Did you try the script in a
 new, empty stack?

 Something like this would be better to be all-inclusive:

 on suspendStack
  put the openStacks into theList
  if answer dialog is among the lines of theList then set the
loc of
 stack answer dialog to loc of me
  if ask dialog is among the lines of theList then set the loc of
 stack
 ask dialog to loc of me
 end suspendStack

 I needed this once, and tried this suggestion but I couldn't get it to
 work either. I'm not sure why. I settled on this hack:

 on answerWithLoc pString,pBtn1,pBtn2
set the vis of stack answer dialog to false
answer pString with pBtn1 and pBtn2
set the loc of stack answer dialog to the loc of this stack
set the vis of stack answer dialog to true
 end answerWithLoc

 --
 Jacqueline Landman Gay | jac...@hyperactivesw.com
 HyperActive Software   | http://www.hyperactivesw.com





___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread J. Landman Gay

If I change the answer line to this it works:

 answer warning pString with pBtn1 and pBtn2

If you want a more flexible handler that answers with regular, warning, 
or info icons, then you'd need to pass that in a parameter and branch 
the handler depending on the type. I wasn't able to get it to compile 
with this:


 answer pType pString with pBtn1 and pBtn2

so you'd need to do:

on answerWithLoc pType,pString,pBtn1,pBtn2
  set the vis of stack answer dialog to false
  switch pType
case warning
  answer warning pString with pBtn1 and pBtn2
  break
case info
  answer info pString with pBtn1 and pBtn2
  break
default
  answer pString with pBtn1 and pBtn2
  end switch
  set the loc of stack answer dialog to the loc of this stack
  set the vis of stack answer dialog to true
end answerWithLoc


On 8/23/2014, 1:21 PM, JB wrote:

Thanks, Jacque.

It is nice to have some more code examples.  I was
able to get it to work okay but if I use answer warning
the warning icon does not show.  Is there a way to
get it to show up with this code?

John Balgenorth


On Aug 23, 2014, at 11:06 AM, J. Landman Gay jac...@hyperactivesw.com wrote:


On 8/23/2014, 12:07 PM, Scott Rossi wrote:

I should have clarified that I listed two scripts: one for answer, one for
ask.  But the script is working here for all versions of LC, Mac and Win,
including v7.  Not sure what to tell you.  Did you try the script in a
new, empty stack?

Something like this would be better to be all-inclusive:

on suspendStack
put the openStacks into theList
if answer dialog is among the lines of theList then set the loc of
stack answer dialog to loc of me
if ask dialog is among the lines of theList then set the loc of stack
ask dialog to loc of me
end suspendStack


I needed this once, and tried this suggestion but I couldn't get it to work 
either. I'm not sure why. I settled on this hack:

on answerWithLoc pString,pBtn1,pBtn2
  set the vis of stack answer dialog to false
  answer pString with pBtn1 and pBtn2
  set the loc of stack answer dialog to the loc of this stack
  set the vis of stack answer dialog to true
end answerWithLoc

--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode




--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-23 Thread JB
That works good!

Very nice, thank you.

John Balgenorth


On Aug 23, 2014, at 12:39 PM, J. Landman Gay jac...@hyperactivesw.com wrote:

 If I change the answer line to this it works:
 
 answer warning pString with pBtn1 and pBtn2
 
 If you want a more flexible handler that answers with regular, warning, or 
 info icons, then you'd need to pass that in a parameter and branch the 
 handler depending on the type. I wasn't able to get it to compile with this:
 
 answer pType pString with pBtn1 and pBtn2
 
 so you'd need to do:
 
 on answerWithLoc pType,pString,pBtn1,pBtn2
  set the vis of stack answer dialog to false
  switch pType
case warning
  answer warning pString with pBtn1 and pBtn2
  break
case info
  answer info pString with pBtn1 and pBtn2
  break
default
  answer pString with pBtn1 and pBtn2
  end switch
  set the loc of stack answer dialog to the loc of this stack
  set the vis of stack answer dialog to true
 end answerWithLoc
 
 
 On 8/23/2014, 1:21 PM, JB wrote:
 Thanks, Jacque.
 
 It is nice to have some more code examples.  I was
 able to get it to work okay but if I use answer warning
 the warning icon does not show.  Is there a way to
 get it to show up with this code?
 
 John Balgenorth
 
 
 On Aug 23, 2014, at 11:06 AM, J. Landman Gay jac...@hyperactivesw.com 
 wrote:
 
 On 8/23/2014, 12:07 PM, Scott Rossi wrote:
 I should have clarified that I listed two scripts: one for answer, one for
 ask.  But the script is working here for all versions of LC, Mac and Win,
 including v7.  Not sure what to tell you.  Did you try the script in a
 new, empty stack?
 
 Something like this would be better to be all-inclusive:
 
 on suspendStack
put the openStacks into theList
if answer dialog is among the lines of theList then set the loc of
 stack answer dialog to loc of me
if ask dialog is among the lines of theList then set the loc of stack
 ask dialog to loc of me
 end suspendStack
 
 I needed this once, and tried this suggestion but I couldn't get it to work 
 either. I'm not sure why. I settled on this hack:
 
 on answerWithLoc pString,pBtn1,pBtn2
  set the vis of stack answer dialog to false
  answer pString with pBtn1 and pBtn2
  set the loc of stack answer dialog to the loc of this stack
  set the vis of stack answer dialog to true
 end answerWithLoc
 
 --
 Jacqueline Landman Gay | jac...@hyperactivesw.com
 HyperActive Software   | http://www.hyperactivesw.com
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your 
 subscription preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 
 
 
 -- 
 Jacqueline Landman Gay | jac...@hyperactivesw.com
 HyperActive Software   | http://www.hyperactivesw.com
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-22 Thread Mark Schonewille

Hi Charles,

I made a plug-in (donationware) which makes sure that windows open  
inside a visible screen rect and not off-screen. I could extend it  
and make it remember window positions.


--

Economy-x-Talk
Consultancy and Software Engineering
http://economy-x-talk.com

Download Color Converter at http://www.color-converter.com

Op 23-aug-2014, om 2:04 heeft Charles E Buchwald het volgende  
geschreven:



Hi List Folks,

I've been thinking about making a plugin that manages window  
positions or window layouts. If you are familiar with Adobe  
applications like Illustrator, Photoshop or InDesign, then you may  
have an idea of what I mean. Or perhaps you have used system-level  
utilities like Moom, Divvy, Shiftit, GridMove or WindowTidy.


The idea is that you can save the position of one or more of your  
windows, including IDE palettes and so on, as a named set. Then you  
can switch back to those positions when you select that set again.


So, for example, one might have a window layout for working on  
iPhone apps and another for tablet apps... or one for a dual  
monitor setup vs. a single monitor setup... or for working on  
server scripts... or all of the above. I switch back and forth  
between my laptop on its own, and my laptop open and next to a  
second monitor, so this would be really useful.


Firstly: does anyone know of an existing LC plugin like this?

And of course: is anyone else interested in a plugin like this?

Cheers,
- Charles




___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Window manager plugin?

2014-08-22 Thread JB
Hi Mark,

Will that let you position the ask and answer dialogs?

John Balgenorth


On Aug 22, 2014, at 5:14 PM, Mark Schonewille 
m.schonewi...@economy-x-talk.com wrote:

 Hi Charles,
 
 I made a plug-in (donationware) which makes sure that windows open inside a 
 visible screen rect and not off-screen. I could extend it and make it 
 remember window positions.
 
 --
 
 Economy-x-Talk
 Consultancy and Software Engineering
 http://economy-x-talk.com
 
 Download Color Converter at http://www.color-converter.com
 
 Op 23-aug-2014, om 2:04 heeft Charles E Buchwald het volgende geschreven:
 
 Hi List Folks,
 
 I've been thinking about making a plugin that manages window positions or 
 window layouts. If you are familiar with Adobe applications like 
 Illustrator, Photoshop or InDesign, then you may have an idea of what I 
 mean. Or perhaps you have used system-level utilities like Moom, Divvy, 
 Shiftit, GridMove or WindowTidy.
 
 The idea is that you can save the position of one or more of your windows, 
 including IDE palettes and so on, as a named set. Then you can switch back 
 to those positions when you select that set again.
 
 So, for example, one might have a window layout for working on iPhone apps 
 and another for tablet apps... or one for a dual monitor setup vs. a single 
 monitor setup... or for working on server scripts... or all of the above. I 
 switch back and forth between my laptop on its own, and my laptop open and 
 next to a second monitor, so this would be really useful.
 
 Firstly: does anyone know of an existing LC plugin like this?
 
 And of course: is anyone else interested in a plugin like this?
 
 Cheers,
 - Charles
 
 
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode