Re: [UPDATE] Free 'Clearview' desktop clock v1.5

2012-10-12 Thread Richmond

On 10/12/2012 10:08 PM, FlexibleLearning.com wrote:

If your copy of the DigitalClock is not being restored to the state you left
it between sessions, you can get the new one that does...


Download v1.5 at www.FlexibleLearning.com/freeclock


Available for Windows, Macs and Linuxes - 100% free - 100% recycled
electrons.


I wonder if the plural of Linux shouldn't be 'Linuses' ?

Congratulations on having a fully (well, not Haiku) cross-platform program!



Hugh Senior
FLCo
The home of:
- ChartMaker www.FlexibleLearning.com/chartmaker
- DatePicker www.FlexibleLearning.com/datepicker
- The Scripter's Scrapbook www.FlexibleLearning.com/ssbk


___
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: Another reason I so dislike the LC IDE

2012-10-12 Thread Kay C Lan
On Fri, Oct 12, 2012 at 10:09 PM, FlexibleLearning.com <
ad...@flexiblelearning.com> wrote:

> Any pointers to how to stop this damn dialog would be most welcome!
>

I eventually learnt to out smart the dialog by a preemptive cmd-s. It's
doing what LC wants you to do without being told.

Probably not the pointer you wanted ;-(
___
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: [ANN] lcStackBrowser V1.0.5

2012-10-12 Thread Thierry Douez
2012/10/13 Peter Haworth :
>
>- lcStackBrowser now provides a way for you to request a update of its
>display.  This can be useful if your scripts trigger a change for which the
>IDE does not have an equivalent message.


Kudos Peter :)

I've implemented it in my PassWords manager plug-in and
it works like a charm !

Thanks for that.

Regards,

Thierry

___
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: Seeking advice for iPad apps

2012-10-12 Thread J. Landman Gay

On 10/12/12 4:31 PM, Lars Brehmer wrote:


I am starting with retina display, but there are of course a hell of
a lot of on non-retina iPads out there. It seems that I have 2
choices to accommodate this. I could make 2 separate apps, on for
retina and one for non-retina or I can construct the app in such a
way that it essentially contains both, and the stacks that are saved
into the documents folder on first launch are determined by the iPad
resolution. Since there are a lot of graphics items, and they are
already big on non-retina and positively huge on retina, the
resulting app would have a very large file size and might be slow to
launch.


I use a third way. I create a single set of images at high resolution. 
When the app launches I determine the correct size and scale them if 
necessary in resizeStack handlers. High-res images look fine at 50% on 
iOS devices and scale well for most Android devices too.


--
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: Unpopularity of global variables - why?

2012-10-12 Thread Timothy Miller
On Oct 12, 2012, at 7:13 PM, J. Landman Gay wrote:

> On 10/12/12 6:50 PM, Timothy Miller wrote:
>> 
>> I consistently put empty into all unused globals when a script starts.
> 
> Unlike HyperCard, in LiveCode you can actually delete them entirely:
> 
>  delete global gMyGlobal

Busted! HyperCard retread, obviously.

I could hunt down all those "put empty into..." scripts and fix them, but 
probably more trouble than it's worth. It would just free up a little bit of 
RAM.

Tim


___
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: Unpopularity of global variables - why?

2012-10-12 Thread J. Landman Gay

On 10/12/12 6:50 PM, Timothy Miller wrote:


I consistently put empty into all unused globals when a script starts.


Unlike HyperCard, in LiveCode you can actually delete them entirely:

  delete global gMyGlobal

I don't have a particular hatred for globals either, you just have to 
know how to be careful with them. On the other hand, I don't think I've 
needed one now for years but if I did, I wouldn't hesitate to use it. 
They are faster and more convenient than a property or a handler, but 
their main advantage is that they aren't tied to any particular stack. 
That's a big advantage, even if you don't need it very often.


--
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: Unpopularity of global variables - why?

2012-10-12 Thread Mark Wieder
Tim-

Friday, October 12, 2012, 4:50:11 PM, you wrote:


> Sometimes I'm using a dozen or more globals at once. I
> consistently put empty into all unused globals when a script starts.
...

That seems like a lot of work, but it also seems like a safe way to
handle global variables. Sounds like you've got it covered.

-- 
-Mark Wieder
 mwie...@ahsoftware.net


___
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: [OT] Where ill conceived copyright laws can lead

2012-10-12 Thread Timothy Miller
Evolution optimized the human brain to cope effectively with ownership of a 
physical object bigger than a pea and no larger than a barn. Ancestral humans 
did not own land, for instance. 

Until recently, people didn't own many abstractions. Maybe a stock certificate 
or the deed to a house. Our evolved moral intuitions do not clearly address 
ownership of an abstraction.

Now, most people own abstractions. To own an ebook, an Mp3 or a software 
license is to own an abstraction. The human brain is not prepared to deal with 
that. The human brain was promoted to its level of incompetence when 
agriculture was invented and people started living in cities.

In the 21st century, all possible answers to complex questions of intellectual 
property will be unsatisfactory and contentious. I need to get used to that. 
Others may suit themselves.

Just my opinion.

Cheers,

Tim


On Oct 11, 2012, at 10:50 PM, Peter Haworth wrote:

> That's not copyright, that's patent, different thing although just as weird!
> 
> One problem with copyright laws is that, as with a lot of laws, they are
> different in every country.


___
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: [ANN] lcStackBrowser V1.0.5

2012-10-12 Thread Matthias Rebbe
Worked. Thanks. :)

Matthias


--
Matthias Rebbe
matthias (at) rebbe.tk
Tel +49.5741.31
Tel +49.160.5504462
--
"Life is too short for boring code"







Am 13.10.2012 um 02:14 schrieb Peter Haworth :

> Hi Matthias,
> Sorry forgot to update the file on my web server with the latest version in
> it.  Please try now and let me know if works OK.
> Pete
> lcSQL Software 
> 
> 
> 
> On Fri, Oct 12, 2012 at 4:45 PM, Matthias Rebbe <
> matthias_livecode_150...@m-r-d.de> wrote:
> 
>> Peter,
>> 
>> lcStackBrowser is telling me here that 1.0.4 is available.
>> But trying to download is not successful.  After selecting the target
>> folder nothing happens.
>> 
>> Any idea?
>> 
>> Regards,
>> 
>> Matthias
>> --
>> Matthias Rebbe
>> matthias (at) rebbe.tk
>> Tel +49.5741.31
>> Tel +49.160.5504462
>> --
>> "Life is too short for boring code"
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> Am 13.10.2012 um 01:21 schrieb Peter Haworth :
>> 
>>> The above version of lcStackBrowser, a plugin alternative to the IDE
>>> Application Browser, is now available at www.lcsql.com.  This release is
>>> free to existing customers.
>>> 
>>> Bugs fixed in this release include:
>>> 
>>>  - New main stacks created from within lcStackBrowser and existing
>> stacks
>>>  opened from within lcStackBrowserwere not shown in the display.
>>>  - New stacks created in lcStackBrowser did not observe the Livecode
>>>  Preference for setting their destroyStack property.  As part of this
>> fix,
>>>  the size of stacks created within lcStackBrowser will be the same as
>> those
>>>  created in the IDE.
>>>  - Sorting cards by number used an alpha sort instead of numeric.
>>>  - Renaming a group resulted in an incorrect display of its members.
>>>  - Made several internal changes to make things work more reliably.
>>> 
>>> In addition, there are two enhancements in this release:
>>> 
>>>  - When you select a control in the IDE, it will be highlighted in the
>>>  lcStackBrowser display and vice versa.
>>> 
>>> 
>>>  - lcStackBrowser now provides a way for you to request a update of its
>>>  display.  This can be useful if your scripts trigger a change for
>> which the
>>>  IDE does not have an equivalent message.
>>> 
>>> To communicate with lcStackBrowser, send the message "lcsb_updateDisplay"
>>> to the lcStackBrowser stack.  The message has one required parameter
>> which
>>> is the action to be taken by lcStackBrowser; other parameters may be
>>> necessary depending on the action.
>>> 
>>> 
>>> 
>>> Currently, only one action is available - "resetLockedStatus". This
>> action
>>> has one optional parameter, a list of stack names, one per line.  This
>>> action causes lcStackBrowser to re-evaluate the locked status of the
>>> specified stacks and adjust its display accordingly.  If the list of
>> stack
>>> names is not provided, all stacks in the display will be re-evaluated.
>>> 
>>> 
>>> Pete
>>> lcSQL Software 
>>> ___
>>> 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: [ANN] lcStackBrowser V1.0.5

2012-10-12 Thread Peter Haworth
Hi Matthias,
Sorry forgot to update the file on my web server with the latest version in
it.  Please try now and let me know if works OK.
Pete
lcSQL Software 



On Fri, Oct 12, 2012 at 4:45 PM, Matthias Rebbe <
matthias_livecode_150...@m-r-d.de> wrote:

> Peter,
>
> lcStackBrowser is telling me here that 1.0.4 is available.
> But trying to download is not successful.  After selecting the target
> folder nothing happens.
>
> Any idea?
>
> Regards,
>
> Matthias
> --
> Matthias Rebbe
> matthias (at) rebbe.tk
> Tel +49.5741.31
> Tel +49.160.5504462
> --
> "Life is too short for boring code"
>
>
>
>
>
>
>
> Am 13.10.2012 um 01:21 schrieb Peter Haworth :
>
> > The above version of lcStackBrowser, a plugin alternative to the IDE
> > Application Browser, is now available at www.lcsql.com.  This release is
> > free to existing customers.
> >
> > Bugs fixed in this release include:
> >
> >   - New main stacks created from within lcStackBrowser and existing
> stacks
> >   opened from within lcStackBrowserwere not shown in the display.
> >   - New stacks created in lcStackBrowser did not observe the Livecode
> >   Preference for setting their destroyStack property.  As part of this
> fix,
> >   the size of stacks created within lcStackBrowser will be the same as
> those
> >   created in the IDE.
> >   - Sorting cards by number used an alpha sort instead of numeric.
> >   - Renaming a group resulted in an incorrect display of its members.
> >   - Made several internal changes to make things work more reliably.
> >
> > In addition, there are two enhancements in this release:
> >
> >   - When you select a control in the IDE, it will be highlighted in the
> >   lcStackBrowser display and vice versa.
> >
> >
> >   - lcStackBrowser now provides a way for you to request a update of its
> >   display.  This can be useful if your scripts trigger a change for
> which the
> >   IDE does not have an equivalent message.
> >
> > To communicate with lcStackBrowser, send the message "lcsb_updateDisplay"
> > to the lcStackBrowser stack.  The message has one required parameter
> which
> > is the action to be taken by lcStackBrowser; other parameters may be
> > necessary depending on the action.
> >
> >
> >
> > Currently, only one action is available - "resetLockedStatus". This
> action
> > has one optional parameter, a list of stack names, one per line.  This
> > action causes lcStackBrowser to re-evaluate the locked status of the
> > specified stacks and adjust its display accordingly.  If the list of
> stack
> > names is not provided, all stacks in the display will be re-evaluated.
> >
> >
> > Pete
> > lcSQL Software 
> > ___
> > 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: Unpopularity of global variables - why?

2012-10-12 Thread Terry Judd
Well, I often use a single global multidimensional array to store all my 
settings and data and It very rarely causes problems. You declare the variable 
in every script and you're away. Easy enough to supplement with script locals 
or custom properties when required and it has the advantage of allowing you to 
save all your data out/in in one fell swoop using arrayEncode/decode.

Terry...

On 13/10/2012, at 8:25 AM, "Peter Haworth"  wrote:

> What Mark said.  Plus I've spent many a happy hour debugging code that was
> supposed to refer to a global variable except that I forgot to declare it
> as such in my script so it was treated as a local variable (in the days
> before realising that Strict Compile Mode is a good thing to do).  That's
> my own stupidity of course but any time I find a way to protect myself from
> my own mistakes, I'll take it!
> 
> Pete
> lcSQL Software 
> 
> 
> 
> On Fri, Oct 12, 2012 at 1:50 PM, Graham Samuel  wrote:
> 
>> The discussion about Strict Compile Mode brought in a lot of stuff about
>> globals, and I sense that many people think they're a bad thing - I am not
>> talking about trick ways of using them, just regular globals that allow one
>> to refer quantities (numbers, strings, anything really) across scripts
>> which are housed in different objects in the same program (set of stacks).
>> 
>> The thing is, I can't see the objection. Clearly any technique can become
>> sufficiently messy and obscure as to negate its own usefulness, but what's
>> wrong with the idea itself? If I want to maintain for example a status
>> across a whole program, if I don't use a global, I am going to have to use
>> a custom prop or a function to transmit that status across object
>> boundaries, and that means more typing with no more security, so why do it?
>> What's wrong with
>> 
>>   if gMy_Status is "open"...
>> 
>> compared to
>> 
>>   if fMy_Status() is "open"…
>> 
>> or
>> 
>>   get the cpMy_Status of stack "myStack"
>>   if it is "open"…
>> 
>> Again, since the 'constant' command doesn't have global status, what's
>> wrong with using globals to store program-wide constants? Is any other way
>> cleaner?
>> 
>> Obviously I'm missing the point - I know I am. It's probably my age. But
>> I'd like to see a more reasoned attack on globals before I give them up.
>> 
>> Graham
>> ___
>> 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: Unpopularity of global variables - why?

2012-10-12 Thread Timothy Miller

On Oct 12, 2012, at 2:25 PM, Bob Sneidar wrote:
> 
> Across ALL stacks in the IDE. That is the rub. If you only work on one 
> application at a time, well and good. But what about library stacks? What 
> about plug-ins? Use as a global something a plugin also uses as a global, and 
> you could really begin to screw things up royally. 

That's all true.

On the other hand, I use a complex set of stacks, but I don't use library 
stacks, plug-ins, etc. Also, the stacks are only for my own use. If something 
goes haywire, it's my job to fix it.

Sometimes I'm using a dozen or more globals at once. I consistently put empty 
into all unused globals when a script starts. In my scripts, globals are 
presumed un-used unless proven otherwise. At the end of scripts, I consistently 
put empty into all globals when I don't need them any more. If I'm using 
several globals, I write a handler just for the purpose of clearing all 
un-needed globals. When perfecting a script or stack, I look at the variable 
watcher to make sure I don't forget to clear un-used globals. I keep a list of 
all my globals (in the global-clearing handler), and avoid using local 
variables with the same name, even if, in theory, I can get away with it.

Works for me. Never had a problem. (I've learned to use custom properties. That 
works too, and there are other alternatives to globals.) The simplicity of a 
global concords with my simple skills and simple brain.

Maybe Graham works the way I do. If so, it's not so easy to see why globals are 
frowned upon.

Cheeers,

Tim
___
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: [ANN] lcStackBrowser V1.0.5

2012-10-12 Thread Matthias Rebbe
Peter,

lcStackBrowser is telling me here that 1.0.4 is available.
But trying to download is not successful.  After selecting the target folder 
nothing happens.

Any idea?

Regards,

Matthias
--
Matthias Rebbe
matthias (at) rebbe.tk
Tel +49.5741.31
Tel +49.160.5504462
--
"Life is too short for boring code"







Am 13.10.2012 um 01:21 schrieb Peter Haworth :

> The above version of lcStackBrowser, a plugin alternative to the IDE
> Application Browser, is now available at www.lcsql.com.  This release is
> free to existing customers.
> 
> Bugs fixed in this release include:
> 
>   - New main stacks created from within lcStackBrowser and existing stacks
>   opened from within lcStackBrowserwere not shown in the display.
>   - New stacks created in lcStackBrowser did not observe the Livecode
>   Preference for setting their destroyStack property.  As part of this fix,
>   the size of stacks created within lcStackBrowser will be the same as those
>   created in the IDE.
>   - Sorting cards by number used an alpha sort instead of numeric.
>   - Renaming a group resulted in an incorrect display of its members.
>   - Made several internal changes to make things work more reliably.
> 
> In addition, there are two enhancements in this release:
> 
>   - When you select a control in the IDE, it will be highlighted in the
>   lcStackBrowser display and vice versa.
> 
> 
>   - lcStackBrowser now provides a way for you to request a update of its
>   display.  This can be useful if your scripts trigger a change for which the
>   IDE does not have an equivalent message.
> 
> To communicate with lcStackBrowser, send the message "lcsb_updateDisplay"
> to the lcStackBrowser stack.  The message has one required parameter which
> is the action to be taken by lcStackBrowser; other parameters may be
> necessary depending on the action.
> 
> 
> 
> Currently, only one action is available - "resetLockedStatus". This action
> has one optional parameter, a list of stack names, one per line.  This
> action causes lcStackBrowser to re-evaluate the locked status of the
> specified stacks and adjust its display accordingly.  If the list of stack
> names is not provided, all stacks in the display will be re-evaluated.
> 
> 
> Pete
> lcSQL Software 
> ___
> 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: Speed of visual effect under iOS

2012-10-12 Thread Matthias Rebbe
Hi Chris,

thanks for your suggestions. I noticed this delay on an iphone 4 and iphone 3, 
not an ipad 3. I will check my preopencard handler. Maybe i can move something 
to the opencard handler.

Regards,

Matthias
--
Matthias Rebbe
matthias (at) rebbe.tk
Tel +49.5741.31
Tel +49.160.5504462
--
"Life is too short for boring code"







Am 11.10.2012 um 17:09 schrieb Chris Sheffield :

> Matthias,
> 
> Are you running on an iPad 3 by chance?
> 
> I'm not sure there's really much you can do. I've run into this same problem. 
> If it's iPad 3, the LC engine has to work extra hard to update the screen, 
> and that's what's causing the delay. It's my understanding that LiveCode does 
> not yet take advantage of the new graphics processor in the iPad 3, and 
> that's why visual effects like this appear to be slower. Hopefully sometime 
> soon we'll see an update that takes advantage of the new hardware. Until 
> then, one thing you could try would be to keep your code in preOpenCard as 
> minimal as possible. Move everything you possibly can to openCard instead. 
> This has actually helped me in some cases.
> 
> Good luck!
> 
> Chris
> 
> 
> --
> Chris Sheffield
> Read Naturally, Inc.
> www.readnaturally.com
> 
> 
> 
> On Oct 11, 2012, at 8:54 AM, Matthias Rebbe 
>  wrote:
> 
>> Hi,
>> 
>> i am using visual effects when going from one card to an other.
>> 
>> e.g.
>> lock screen for visual effects
>> go card "settings"
>> unlock screen with visual effect push up very fast
>> 
>> Without using visual effects the performance is good. But with using visual 
>> effects there is a delay of 1 to 2 seconds before 
>> the visual effed takes place. So the user first thinks nothing would happen.
>> 
>> Any idea if i can speed up this. Or should i show a busy indicator until the 
>> "move" to the next card is completed.
>> 
>> Regards,
>> 
>> Matthias 
>> 
>> 
>> 
>> --
>> Matthias Rebbe
>> matthias (at) rebbe.tk
>> Tel +49.5741.31
>> Tel +49.160.5504462
>> --
>> "Life is too short for boring code"
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> ___
>> 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


[ANN] lcStackBrowser V1.0.5

2012-10-12 Thread Peter Haworth
The above version of lcStackBrowser, a plugin alternative to the IDE
Application Browser, is now available at www.lcsql.com.  This release is
free to existing customers.

Bugs fixed in this release include:

   - New main stacks created from within lcStackBrowser and existing stacks
   opened from within lcStackBrowserwere not shown in the display.
   - New stacks created in lcStackBrowser did not observe the Livecode
   Preference for setting their destroyStack property.  As part of this fix,
   the size of stacks created within lcStackBrowser will be the same as those
   created in the IDE.
   - Sorting cards by number used an alpha sort instead of numeric.
   - Renaming a group resulted in an incorrect display of its members.
   - Made several internal changes to make things work more reliably.

In addition, there are two enhancements in this release:

   - When you select a control in the IDE, it will be highlighted in the
   lcStackBrowser display and vice versa.


   - lcStackBrowser now provides a way for you to request a update of its
   display.  This can be useful if your scripts trigger a change for which the
   IDE does not have an equivalent message.

To communicate with lcStackBrowser, send the message "lcsb_updateDisplay"
to the lcStackBrowser stack.  The message has one required parameter which
is the action to be taken by lcStackBrowser; other parameters may be
necessary depending on the action.



Currently, only one action is available - "resetLockedStatus". This action
has one optional parameter, a list of stack names, one per line.  This
action causes lcStackBrowser to re-evaluate the locked status of the
specified stacks and adjust its display accordingly.  If the list of stack
names is not provided, all stacks in the display will be re-evaluated.


Pete
lcSQL Software 
___
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: Unpopularity of global variables - why?

2012-10-12 Thread Mark Wieder
Bob-

Friday, October 12, 2012, 2:29:04 PM, you wrote:

> And may I add, if RunRev would get off their butts about the
> variable breakpoint CTD bug, it would be really simple to find out
> where a thing is going wrong! Set a breakpoint on a global, and when
> it changes unexpectedly, there you go! Honestly, for a feature that
> would prove so incredibly helpful, shouldn't they fix this first
> before releasing any more features?? (Or did they already? Am I like
> that old lady in SNL? "Oh, well then... NEVER MIND!")

According to my notes, that's bug #6506 and was fixed in build
4.5-dp2 (6 Feb 2010).

-- 
-Mark Wieder
 mwie...@ahsoftware.net


___
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: Another reason I so dislike the LC IDE

2012-10-12 Thread Bob Sneidar
I know! Without the IDE we would be forced to only use the example stacks that 
come with LC, and what good would that be??

Bob


On Oct 12, 2012, at 3:02 PM, dunb...@aol.com wrote:

> Hmmm.
> 
> 
> I LOVE the IDE.
> 
> 
> 
> Craig
> 
> 
> -Original Message-
> From: Richmond 
> To: How to use LiveCode 
> Sent: Fri, Oct 12, 2012 2:12 pm
> Subject: Re: Another reason I so dislike the LC  IDE
> 
> 
> On 10/12/2012 05:09 PM, FlexibleLearning.com wrote:
>> When I close a stack, the LC IDE insists on asking if I want to save it even
>> when unnecessary (auto-save is built in).
> 
> I'm not sure about that; Livecode is NOT Hypercard (lest we forget).
> 
>> 
>> I have tried these to no avail...
>> 
>> on closeStack
>>   lock messages
>> 
>> on suspendStack
>>   lock messages
>> 
>> on closeStackRequest
>>   lock messages
>> 
>> Anything else? The culprit looks like an IDE backscript, but darned if I can
>> find it and I cannot trace into it.
>> 
>> Any pointers to how to stop this damn dialog would be most welcome!
>> 
>> (As an asside, the MC IDE simply closes. No fuss, no intrusion.)
>> 
>> Hugh Senior
>> FLCo
>> 
>> 
>> ___
>> 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: Unpopularity of global variables - why?

2012-10-12 Thread Monte Goulding
Hmm... It's much better practice to use script locals and getters and setters. 
Or custom properties. I can't remember the last time I used a global.

--
M E R Goulding
Software development services

mergExt - There's an external for that!

On 13/10/2012, at 8:50 AM, Guglielmo Braguglia  wrote:

> *Holy words Bob !!!*
> 
> This would be the most sensible thing ...
> ... the "global" declared for one MainStack should be valid only in his 
> context and not for any mainStack opened !
> 
> But unfortunately is not like that so ... use with caution ! ;-)
> 
> Guglielmo
> 
> On 12.10.2012 23:25, Bob Sneidar wrote:
>> I don't think that globals are a bad thing, but I do think they should only 
>> apply to the stack they are defined in, or else have another class of 
>> globals called stack or application globals (or how about both!). That would 
>> solve the vast majority of cross globalization. (Hey I think I coined a new 
>> term!
> 
> ___
> 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: Unpopularity of global variables - why?

2012-10-12 Thread dunbarx
So you see there is nothing wrong with them, just be careful. They are both 
powerful and dangerous, like a firearm, but similarly, very useful in the 
appropriate situation.


I have an ancient personal distaste that derives from the fact that in HC, they 
persist in the variable watcher and cause clutter. But in LC, this can be 
addressed.


Craig Newman



-Original Message-
From: Guglielmo Braguglia 
To: How to use LiveCode 
Sent: Fri, Oct 12, 2012 5:56 pm
Subject: Re: Unpopularity of global variables - why?


*Holy words Bob !!!*

This would be the most sensible thing ...
... the "global" declared for one MainStack should be valid only in his 
context and not for any mainStack opened !

But unfortunately is not like that so ... use with caution ! ;-)

Guglielmo

On 12.10.2012 23:25, Bob Sneidar wrote:
> I don't think that globals are a bad thing, but I do think they should 
> only apply to the stack they are defined in, or else have another 
> class of globals called stack or application globals (or how about 
> both!). That would solve the vast majority of cross globalization. 
> (Hey I think I coined a new term!

___
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: Another reason I so dislike the LC IDE

2012-10-12 Thread dunbarx
Hmmm.


I LOVE the IDE.



Craig


-Original Message-
From: Richmond 
To: How to use LiveCode 
Sent: Fri, Oct 12, 2012 2:12 pm
Subject: Re: Another reason I so dislike the LC  IDE


On 10/12/2012 05:09 PM, FlexibleLearning.com wrote:
> When I close a stack, the LC IDE insists on asking if I want to save it even
> when unnecessary (auto-save is built in).

I'm not sure about that; Livecode is NOT Hypercard (lest we forget).

>
> I have tried these to no avail...
>
> on closeStack
>lock messages
>
> on suspendStack
>lock messages
>
> on closeStackRequest
>lock messages
>
> Anything else? The culprit looks like an IDE backscript, but darned if I can
> find it and I cannot trace into it.
>
> Any pointers to how to stop this damn dialog would be most welcome!
>
> (As an asside, the MC IDE simply closes. No fuss, no intrusion.)
>
> Hugh Senior
> FLCo
>
>
> ___
> 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: defaultcursor problem

2012-10-12 Thread dunbarx
Peter.


In my test, I also locked the cursor. Should have mentioned that.



Craig


-Original Message-
From: Peter M. Brigham 
To: How to use LiveCode 
Sent: Fri, Oct 12, 2012 10:17 am
Subject: Re: defaultcursor problem


That never works. Setting "the cursor" will only be very fleeting, as the 
cursor 
will revert to the defaultcursor at the next idle message, and it happens so 
fast you never even see a flicker You can set "the cursor" then lock the 
cursor, 
then unlock it in a mouseleave handler, and that will work, but I learned a 
long 
time ago that this leads to persistent locked cursors, since LC seems at times 
not to send "mouseleave" messages, eg when a modal dialog is invoked, and 
randomly otherwise too.

I can set the defaultcursor successfully in other circumstances, eg, in a 
mousemove handler over a button, to change it to "hand" to indicate to the user 
that what's called for is a click on the button. I want to do the same thing 
over an unlocked field when the commandkey is down, to indicate to the user 
that 
a click is called for. I used to be able to do this, but now it doesn't work 
any 
more.   

-- Peter

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

On Oct 12, 2012, at 9:36 AM, dunb...@aol.com wrote:

> Hi.
> 
> 
> Try this with "the cursor" instead of "the defaultCursor".
> 
> 
> Craig Newman
> 
> 
> 
> -Original Message-
> From: Peter M. Brigham 
> To: How to use LiveCode 
> Sent: Fri, Oct 12, 2012 9:07 am
> Subject: defaultcursor problem
> 
> 
> Anyone have an idea why this doesn't work? Put the following into the script 
of 
> an unlocked field:
> 
> on mousemove
>   put the commandkey is down into cmK
>   if cmK then
>  set the defaultcursor to hand
>   else
>  set the defaultcursor to empty
>   end if
> end mousemove
> 
> I want the cursor to become "hand" with the commandkey down, but it simply 
> remains a bar over an unlocked field. I swear this used to work, but for some 
> reason it no longer does. 2008 MacBook, OSX 10.7.4 (Lion), Rev Studio 4.5.3, 
> build 1210
> 
> -- Peter
> 
> Peter M. Brigham
> pmb...@gmail.com
> http://home.comcast.net/~pmbrig
> 
> 
> ___
> 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: Unpopularity of global variables - why?

2012-10-12 Thread Guglielmo Braguglia

*Holy words Bob !!!*

This would be the most sensible thing ...
... the "global" declared for one MainStack should be valid only in his 
context and not for any mainStack opened !


But unfortunately is not like that so ... use with caution ! ;-)

Guglielmo

On 12.10.2012 23:25, Bob Sneidar wrote:
I don't think that globals are a bad thing, but I do think they should 
only apply to the stack they are defined in, or else have another 
class of globals called stack or application globals (or how about 
both!). That would solve the vast majority of cross globalization. 
(Hey I think I coined a new term!


___
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: [UPDATE] Free 'Clearview' desktop clock v1.5

2012-10-12 Thread J. Landman Gay

On 10/12/12 3:54 PM, Bob Sneidar wrote:

Isn't this how Jacque's Time Travel stack started? Didn't she
distribute some kind of time stack freely to everyone, until they
reached critical mass and became sentient? Heck, maybe this is what
started (is starting/is going to start) everything! Time travel
paradoxes are so confusing!


I don't know how it started because it hasn't started yet. I did see it 
briefly yesterday when I was checking on next week, but it had already 
been started by then.


All that aside, I do question how many of us are sentient. But that's a 
different research project.


--
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


Seeking advice for iPad apps

2012-10-12 Thread Lars Brehmer
I have a fairly general question and a fairly specific question that I need 
advice on.

I am starting to make iPad versions of some of my apps and loving the process. 
However, I am not capable of using native controls and I design all graphics, 
icons, etc. myself. These are of course not scalable by iOS, so the general 
question is this;

I am starting with retina display, but there are of course a hell of a lot of 
on non-retina iPads out there. It seems that I have 2 choices to accommodate 
this. I could make 2 separate apps, on for retina and one for non-retina or I 
can construct the app in such a way that it essentially contains both, and the 
stacks that are saved into the documents folder on first launch are determined 
by the iPad resolution. Since there are a lot of graphics items, and they are 
already big on non-retina and positively huge on retina, the resulting app 
would have a very large file size and might be slow to launch.

Or again, two separate apps. The problem with this is that a user who has the 
non-retina app and later buys a retina iPad cannot just re-download it for free 
because it isn't the same app (I am assuming this). This is obviously very bad.

Has anyone faced this dilema and if so, what choice did you make and what was 
your reasoning behind the decision?

There more specific question deals with pop-up,pull-down, option buttons with 
sub-menus in iOS. At least in the simulator, pop-up and pull-downs don't work 
and an option menu button displays the options the way I am used to see it on 
my iPad, but the submenus of the choices don't seem to work. To clarify, I am 
talking about those option menu buttons where the options appear in a sort of 
frame. Touch an option in that frame and the submenu slides into place and a 
button pointing back to the option you chose appears on the top left of said 
frame. Very typical in iOS. Is this somehow possible to achieve in liveCode 
without using native controls? I have been thinking of ways to do this with 
code and non-native controls, and I am convinced that it isn't that hard to do, 
but it would be nice to avoid this if possible.

Any tips are as alway very welcome!

Cheers,

Lars

___
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: Unpopularity of global variables - why?

2012-10-12 Thread Bob Sneidar

On Oct 12, 2012, at 2:01 PM, Mark Wieder wrote:

> Graham-
> 
> Friday, October 12, 2012, 1:50:30 PM, you wrote:
> 
>> Obviously I'm missing the point - I know I am. It's probably my
>> age.
> 
> :-P
> 
>> But I'd like to see a more reasoned attack on globals before I
>> give them up.
> 
> Generally speaking (there are exceptions) the main reason global
> variables are a bad idea is that they have no protection. Any script
> in any stack can change the value of a global variable behind your
> back, and then it's a real pain trying to figure out what's going on.

And may I add, if RunRev would get off their butts about the variable 
breakpoint CTD bug, it would be really simple to find out where a thing is 
going wrong! Set a breakpoint on a global, and when it changes unexpectedly, 
there you go! Honestly, for a feature that would prove so incredibly helpful, 
shouldn't they fix this first before releasing any more features?? (Or did they 
already? Am I like that old lady in SNL? "Oh, well then... NEVER MIND!")

Bob
___
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: Unpopularity of global variables - why?

2012-10-12 Thread Bob Sneidar

On Oct 12, 2012, at 1:50 PM, Graham Samuel wrote:

> The discussion about Strict Compile Mode brought in a lot of stuff about 
> globals, and I sense that many people think they're a bad thing - I am not 
> talking about trick ways of using them, just regular globals that allow one 
> to refer quantities (numbers, strings, anything really) across scripts which 
> are housed in different objects in the same program (set of stacks).

Across ALL stacks in the IDE. That is the rub. If you only work on one 
application at a time, well and good. But what about library stacks? What about 
plug-ins? Use as a global something a plugin also uses as a global, and you 
could really begin to screw things up royally. 

I don't think that globals are a bad thing, but I do think they should only 
apply to the stack  they are defined in, or else have another class of globals 
called stack or application globals (or how about both!). That would solve the 
vast majority of cross globalization. (Hey I think I coined a new term!

Bob
___
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: Unpopularity of global variables - why?

2012-10-12 Thread Peter Haworth
What Mark said.  Plus I've spent many a happy hour debugging code that was
supposed to refer to a global variable except that I forgot to declare it
as such in my script so it was treated as a local variable (in the days
before realising that Strict Compile Mode is a good thing to do).  That's
my own stupidity of course but any time I find a way to protect myself from
my own mistakes, I'll take it!

Pete
lcSQL Software 



On Fri, Oct 12, 2012 at 1:50 PM, Graham Samuel  wrote:

> The discussion about Strict Compile Mode brought in a lot of stuff about
> globals, and I sense that many people think they're a bad thing - I am not
> talking about trick ways of using them, just regular globals that allow one
> to refer quantities (numbers, strings, anything really) across scripts
> which are housed in different objects in the same program (set of stacks).
>
> The thing is, I can't see the objection. Clearly any technique can become
> sufficiently messy and obscure as to negate its own usefulness, but what's
> wrong with the idea itself? If I want to maintain for example a status
> across a whole program, if I don't use a global, I am going to have to use
> a custom prop or a function to transmit that status across object
> boundaries, and that means more typing with no more security, so why do it?
> What's wrong with
>
>if gMy_Status is "open"...
>
> compared to
>
>if fMy_Status() is "open"…
>
> or
>
>get the cpMy_Status of stack "myStack"
>if it is "open"…
>
> Again, since the 'constant' command doesn't have global status, what's
> wrong with using globals to store program-wide constants? Is any other way
> cleaner?
>
> Obviously I'm missing the point - I know I am. It's probably my age. But
> I'd like to see a more reasoned attack on globals before I give them up.
>
> Graham
> ___
> 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: iOS Simulator

2012-10-12 Thread Dave McKee
Fixed by upgrading to latest XCode

Sent from my iPhone

On 2012-10-12, at 1:55 PM, Dave McKee  wrote:

> running mac osx lion 10.8.2
> using LC v5.5.3 RC2
> 
> have selected target as being; iPhone simulator 5.1
> 
> have app that was working ok in simulator but as of moving from 5.5.2 to 
> 5.5.3 rc2, have run into a strange bug (?).
> 
> test build the app, app opens in iOS simulator, when I quit app and then hold 
> down icon, to delete it, jiggle icon appears with (X) but if I;
>  1. hit home, then ok
>  2. hit (X), then app is not deleted and hitting home button is unresponsive
>  a. quit IOS simulator
>  b. restart iOS simulator, the test app is still there
> 
> Also;
>  I see exactly the same symptoms 1 to 2b if I launch Xcode and then iOS 
> Simulator
> 
> 
> 
> what form of Apple hell have I fallen into ?
> is there anyone who knows how to clear out the test app in the iOS Simulator 
> now that it has a death grip on it ?
> ___
> 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: Strict Compile Mode

2012-10-12 Thread Mark Wieder
Bob-

Friday, October 12, 2012, 1:49:33 PM, you wrote:

> Bloodlusting zombies then??

Well, I had in mind that it's stacks that have the problem, but point
taken. Bloodlusting zombies lead a relatively simple life, and little
things like global vars can really confuse them.

So be kind to your neighborhood bloodlusting zombies and avoid the use
of global variables.

-- 
-Mark Wieder
 mwie...@ahsoftware.net


___
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: Strict Compile Mode

2012-10-12 Thread Mark Wieder
stephen-

Friday, October 12, 2012, 11:27:22 AM, you wrote:

> this problem could be solved by using a single global ARRAY with the key
> being the stack name.

That solution would work even better if stack *names* were unique.

-- 
-Mark Wieder
 mwie...@ahsoftware.net


___
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: Unpopularity of global variables - why?

2012-10-12 Thread Mark Wieder
Graham-

Friday, October 12, 2012, 1:50:30 PM, you wrote:

> Obviously I'm missing the point - I know I am. It's probably my
> age.

:-P

> But I'd like to see a more reasoned attack on globals before I
> give them up.

Generally speaking (there are exceptions) the main reason global
variables are a bad idea is that they have no protection. Any script
in any stack can change the value of a global variable behind your
back, and then it's a real pain trying to figure out what's going on.

If you declare and use a global variable "myGlobal" in one stack, then
close that stack and create a new one, that variable is still in
memory. If you create a new script and say "global myGlobal" you've
automatically inherited the existing value without having put anything
into it.

The situation gets worse if you have both stacks in memory at the same
time and then they're fighting over the value of myGlobal. And worse
yet if you accidentally declare a global variable that's already in
use by one of the system stacks or plugins.

-- 
-Mark Wieder
 mwie...@ahsoftware.net


___
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: [UPDATE] Free 'Clearview' desktop clock v1.5

2012-10-12 Thread Bob Sneidar
Isn't this how Jacque's Time Travel stack started? Didn't she distribute some 
kind of time stack freely to everyone, until they reached critical mass and 
became sentient? Heck, maybe this is what started (is starting/is going to 
start) everything! Time travel paradoxes are so confusing! 

Bob


On Oct 12, 2012, at 12:08 PM, FlexibleLearning.com wrote:

> If your copy of the DigitalClock is not being restored to the state you left
> it between sessions, you can get the new one that does...
> 
> 
> Download v1.5 at www.FlexibleLearning.com/freeclock
> 
> 
> Available for Windows, Macs and Linuxes - 100% free - 100% recycled
> electrons.
> 
> 
> Hugh Senior


___
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


Unpopularity of global variables - why?

2012-10-12 Thread Graham Samuel
The discussion about Strict Compile Mode brought in a lot of stuff about 
globals, and I sense that many people think they're a bad thing - I am not 
talking about trick ways of using them, just regular globals that allow one to 
refer quantities (numbers, strings, anything really) across scripts which are 
housed in different objects in the same program (set of stacks).

The thing is, I can't see the objection. Clearly any technique can become 
sufficiently messy and obscure as to negate its own usefulness, but what's 
wrong with the idea itself? If I want to maintain for example a status across a 
whole program, if I don't use a global, I am going to have to use a custom prop 
or a function to transmit that status across object boundaries, and that means 
more typing with no more security, so why do it? What's wrong with

   if gMy_Status is "open"...

compared to

   if fMy_Status() is "open"…

or

   get the cpMy_Status of stack "myStack"
   if it is "open"…

Again, since the 'constant' command doesn't have global status, what's wrong 
with using globals to store program-wide constants? Is any other way cleaner?

Obviously I'm missing the point - I know I am. It's probably my age. But I'd 
like to see a more reasoned attack on globals before I give them up.

Graham
___
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: Repeat script does not work

2012-10-12 Thread Charles Szasz
Michael,

Thanks again for your help!

Charles Szasz
csz...@mac.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: Strict Compile Mode

2012-10-12 Thread Bob Sneidar
That's a great solution too!

On Oct 12, 2012, at 11:27 AM, stephen barncard wrote:

> this problem could be solved by using a single global ARRAY with the key
> being the stack name.
> 
> On Fri, Oct 12, 2012 at 11:15 AM, Mark Wieder wrote:
> 
>> Bob Sneidar  writes:
>> 
>>> I think globals make sense in a standalone.
>> 
>> OK - that could make sense, but you'd still have to develop them in the
>> IDE.
>> 
>>> It seems to be the IDE that people have problems with them.
>> 
>> Er... I don't think it's "people" that have problems with global vars.
>> 
>> --
>> Mark Wieder
>> mwie...@ahsoftware.net
>> 
>> 
>> 
>> ___
>> 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
>> 
> 
> 
> 
> -- 
> 
> 
> 
> Stephen Barncard
> San Francisco Ca. USA
> 
> more about sqb  
> ___
> 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: Strict Compile Mode

2012-10-12 Thread Bob Sneidar

On Oct 12, 2012, at 11:15 AM, Mark Wieder wrote:

> Bob Sneidar  writes:
> 
>> I think globals make sense in a standalone.
> 
> OK - that could make sense, but you'd still have to develop them in the IDE.
> 
>> It seems to be the IDE that people have problems with them.
> 
> Er... I don't think it's "people" that have problems with global vars.

Bloodlusting zombies then??



___
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: Repeat script does not work

2012-10-12 Thread Michael Kann
Charles,

You're right. The correct order of the last lines should probably be the 
following:
I was being called to dinner and didn't check carefully enough.

end repeat
end repeat
delete char -1 of theList
put theList into fld "recommendations"
end mouseUp

--- On Fri, 10/12/12, Michael Kann  wrote:

From: Michael Kann 
Subject: Re: Repeat script does not work
To: "How to use LiveCode" 
Date: Friday, October 12, 2012, 2:53 PM

Charles, 

Could it be this:


on mouseUp 

repeat with y = 1 to the num of cards

if the mark of card y = false
then next repeat
end if

put the num of btns of card y into nbr

repeat with n = 1 to nbr

if the style of btn n is "checkbox" and the hilite of btn n is true then

 put the uMyLabel of btn n into tName
 put tName & cr after theList
end if

end repeat
delete char -1 of theList

end repeat

put theList into fld "recommendations"

end mouseUp

Mike

--- On Fri, 10/12/12, Charles Szasz  wrote:

From: Charles Szasz 
Subject: Repeat script does not work
To: use-livecode@lists.runrev.com
Date: Friday, October 12, 2012, 2:20 PM

The following script works for finding a checkbox that is checked and putting 
its custom property (uMyLabel) into the field "recommendations" on the marked 
card that it is on. However, it fails to put the uMyLabel of another checked 
checkbox that is on another marked card into the field "recommendations".  What 
am I missing here!

on mouseUp  
   repeat with y = 1 to the number of cards
      if the mark of card y = true then
         put the number of buttons of card y into nbr
      end if
   end repeat
   
   repeat with n = 1 to nbr
      if the style of button n is "checkbox" and the hilite of button n is true 
then
         put the uMyLabel of button n into tName
         put tName & cr after theList
      end if
   end repeat
   delete char -1 of theList
   put theList into field "recommendations"
end mouseUp

Charles Szasz
csz...@mac.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
___
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: Repeat script does not work

2012-10-12 Thread Charles Szasz
Hi Mike,

Thanks for your suggestion! I was trying out your script but I could not get it 
to work. I think the end repeat is misplaced.

Charles Szasz
csz...@mac.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: Repeat script does not work

2012-10-12 Thread Charles Szasz
Pete,

I have thought of doing a repeat within a repeat but thought it would be 
simpler to keep them separate to avoid errors. But your script does work! As 
you indicated, the references to button n must be the problem. 

I am working on this script to use with a lot of marked cards. So, if it works 
for two marked cards in my sample stack, it should work for my other marked 
cards.

Thanks very much!

Charles Szasz
csz...@mac.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: Repeat script does not work

2012-10-12 Thread Michael Kann
Charles, 

Could it be this:


on mouseUp 

repeat with y = 1 to the num of cards

if the mark of card y = false
then next repeat
end if

put the num of btns of card y into nbr

repeat with n = 1 to nbr

if the style of btn n is "checkbox" and the hilite of btn n is true then

 put the uMyLabel of btn n into tName
 put tName & cr after theList
end if

end repeat
delete char -1 of theList

end repeat

put theList into fld "recommendations"

end mouseUp

Mike

--- On Fri, 10/12/12, Charles Szasz  wrote:

From: Charles Szasz 
Subject: Repeat script does not work
To: use-livecode@lists.runrev.com
Date: Friday, October 12, 2012, 2:20 PM

The following script works for finding a checkbox that is checked and putting 
its custom property (uMyLabel) into the field "recommendations" on the marked 
card that it is on. However, it fails to put the uMyLabel of another checked 
checkbox that is on another marked card into the field "recommendations".  What 
am I missing here!

on mouseUp  
   repeat with y = 1 to the number of cards
      if the mark of card y = true then
         put the number of buttons of card y into nbr
      end if
   end repeat
   
   repeat with n = 1 to nbr
      if the style of button n is "checkbox" and the hilite of button n is true 
then
         put the uMyLabel of button n into tName
         put tName & cr after theList
      end if
   end repeat
   delete char -1 of theList
   put theList into field "recommendations"
end mouseUp

Charles Szasz
csz...@mac.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: Repeat script does not work

2012-10-12 Thread Peter Haworth
I think you need to include the second repeat within the first repeat and
also fully qualify the references to button n, maybe something like this:

on mouseUp
   repeat with y = 1 to the number of cards of stack "xyz"
  if the mark of card y of stack "xyz"= true then
 put the number of buttons of card y of stack "xyz"into nbr
 repeat with n = 1 to nbr
if the style of button n of card y of stack "xyz" is "checkbox"
and the hilite of button n of card y of stack "xyz" is true then
   put the uMyLabel of button n of card y of stack "xyz" into
tName
  put tName & cr after theList
end if
 end repeat
  end if
   end repeat

   delete char -1 of theList
   put theList into field "recommendations"
end mouseUp

Pete
lcSQL Software 



On Fri, Oct 12, 2012 at 12:20 PM, Charles Szasz  wrote:

> The following script works for finding a checkbox that is checked and
> putting its custom property (uMyLabel) into the field "recommendations" on
> the marked card that it is on. However, it fails to put the uMyLabel of
> another checked checkbox that is on another marked card into the field
> "recommendations".  What am I missing here!
>
> on mouseUp
>repeat with y = 1 to the number of cards
>   if the mark of card y = true then
>  put the number of buttons of card y into nbr
>   end if
>end repeat
>
>repeat with n = 1 to nbr
>   if the style of button n is "checkbox" and the hilite of button n is
> true then
>  put the uMyLabel of button n into tName
>  put tName & cr after theList
>   end if
>end repeat
>delete char -1 of theList
>put theList into field "recommendations"
> end mouseUp
>
> Charles Szasz
> csz...@mac.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


Repeat script does not work

2012-10-12 Thread Charles Szasz
The following script works for finding a checkbox that is checked and putting 
its custom property (uMyLabel) into the field "recommendations" on the marked 
card that it is on. However, it fails to put the uMyLabel of another checked 
checkbox that is on another marked card into the field "recommendations".  What 
am I missing here!

on mouseUp  
   repeat with y = 1 to the number of cards
  if the mark of card y = true then
 put the number of buttons of card y into nbr
  end if
   end repeat
   
   repeat with n = 1 to nbr
  if the style of button n is "checkbox" and the hilite of button n is true 
then
 put the uMyLabel of button n into tName
 put tName & cr after theList
  end if
   end repeat
   delete char -1 of theList
   put theList into field "recommendations"
end mouseUp

Charles Szasz
csz...@mac.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


[UPDATE] Free 'Clearview' desktop clock v1.5

2012-10-12 Thread FlexibleLearning.com
If your copy of the DigitalClock is not being restored to the state you left
it between sessions, you can get the new one that does...


Download v1.5 at www.FlexibleLearning.com/freeclock


Available for Windows, Macs and Linuxes - 100% free - 100% recycled
electrons.


Hugh Senior
FLCo
The home of:
- ChartMaker www.FlexibleLearning.com/chartmaker
- DatePicker www.FlexibleLearning.com/datepicker
- The Scripter's Scrapbook www.FlexibleLearning.com/ssbk


___
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: Another reason I so dislike the LC IDE

2012-10-12 Thread J. Landman Gay

On 10/12/12 9:09 AM, FlexibleLearning.com wrote:

When I close a stack, the LC IDE insists on asking if I want to save it even
when unnecessary (auto-save is built in).

I have tried these to no avail...

on closeStack
   lock messages

on suspendStack
   lock messages

on closeStackRequest
   lock messages

Anything else? The culprit looks like an IDE backscript, but darned if I can
find it and I cannot trace into it.


That's the one thing that bugs me the most too. Here's the fix:

 put "" into gREVStackStatus[the short name of this stack]

The problem is that it will get reset quite a lot, and you can't trap it 
on closestack because the IDE gets the closestack message first. I don't 
try to fix it very often because you have to manage it everywhere, but I 
have a couple of stacks where LiveCode's dirty flag only occurs on 
closefield, and so I insert it into a closefield handler to clear things 
out.


Since I do open stacks in both LC and MC, I wrote this handler:

on clearRevGlobal
  if there is no stack "mctools" then
global gREVStackStatus
put "" into gREVStackStatus[the short name of this stack]
  end if
end clearRevGlobal

Then I just call that repeatedly as needed.

--
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: Strict Compile Mode

2012-10-12 Thread Peter Haworth
I've just removed the one global variable I had in lcStackBrowser and I'm
sure the visual nature of your analogy will remind me never to use them
again :-)
Pete
lcSQL Software 



On Fri, Oct 12, 2012 at 10:32 AM, Mark Wieder wrote:

> Global variables are always recipes for potential disasters.
> I almost never find a need to use a global variable, although as I
> mentioned,
> Chipp managed to look at the pile of horse turds and find a pony.
>
___
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: Strict Compile Mode

2012-10-12 Thread stephen barncard
this problem could be solved by using a single global ARRAY with the key
being the stack name.

On Fri, Oct 12, 2012 at 11:15 AM, Mark Wieder wrote:

> Bob Sneidar  writes:
>
> > I think globals make sense in a standalone.
>
> OK - that could make sense, but you'd still have to develop them in the
> IDE.
>
> > It seems to be the IDE that people have problems with them.
>
> Er... I don't think it's "people" that have problems with global vars.
>
> --
>  Mark Wieder
>  mwie...@ahsoftware.net
>
>
>
> ___
> 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
>



-- 



Stephen Barncard
San Francisco Ca. USA

more about sqb  
___
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: Strict Compile Mode

2012-10-12 Thread Mark Wieder
Bob Sneidar  writes:

> I think globals make sense in a standalone.

OK - that could make sense, but you'd still have to develop them in the IDE.

> It seems to be the IDE that people have problems with them.

Er... I don't think it's "people" that have problems with global vars.

-- 
 Mark Wieder
 mwie...@ahsoftware.net



___
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: Another reason I so dislike the LC IDE

2012-10-12 Thread Richmond

On 10/12/2012 05:09 PM, FlexibleLearning.com wrote:

When I close a stack, the LC IDE insists on asking if I want to save it even
when unnecessary (auto-save is built in).


I'm not sure about that; Livecode is NOT Hypercard (lest we forget).



I have tried these to no avail...

on closeStack
   lock messages

on suspendStack
   lock messages

on closeStackRequest
   lock messages

Anything else? The culprit looks like an IDE backscript, but darned if I can
find it and I cannot trace into it.

Any pointers to how to stop this damn dialog would be most welcome!

(As an asside, the MC IDE simply closes. No fuss, no intrusion.)

Hugh Senior
FLCo


___
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: Strict Compile Mode

2012-10-12 Thread Bob Sneidar
I think globals make sense in a standalone. It seems to be the IDE that people 
have problems with them. 

Bob


On Oct 12, 2012, at 10:32 AM, Mark Wieder wrote:

> Peter Haworth  writes:
> 
>> That seems like a recipe for potential disaster,
> 
> Global variables are always recipes for potential disasters.
> I almost never find a need to use a global variable, although as I mentioned,
> Chipp managed to look at the pile of horse turds and find a pony.
> 
> -- 
> Mark Wieder


___
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


iOS Simulator

2012-10-12 Thread Dave McKee
running mac osx lion 10.8.2
using LC v5.5.3 RC2

have selected target as being; iPhone simulator 5.1

have app that was working ok in simulator but as of moving from 5.5.2 to 5.5.3 
rc2, have run into a strange bug (?).

test build the app, app opens in iOS simulator, when I quit app and then hold 
down icon, to delete it, jiggle icon appears with (X) but if I;
  1. hit home, then ok
  2. hit (X), then app is not deleted and hitting home button is unresponsive
  a. quit IOS simulator
  b. restart iOS simulator, the test app is still there

Also;
  I see exactly the same symptoms 1 to 2b if I launch Xcode and then iOS 
Simulator



what form of Apple hell have I fallen into ?
is there anyone who knows how to clear out the test app in the iOS Simulator 
now that it has a death grip on it ?
___
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: Strict Compile Mode

2012-10-12 Thread Mark Wieder
Peter Haworth  writes:

> That seems like a recipe for potential disaster,

Global variables are always recipes for potential disasters.
I almost never find a need to use a global variable, although as I mentioned,
Chipp managed to look at the pile of horse turds and find a pony.

-- 
 Mark Wieder
 mwie...@ahsoftware.net




___
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: Strict Compile Mode

2012-10-12 Thread Ben Rubinstein

On 11/10/2012 22:21, Peter Haworth wrote:

Thanks for the idea - it worked for me too!  Don;t worry, I won;t ask why -
I've given up trying to figure out why LC does some things :-)

On Thu, Oct 11, 2012 at 11:35 AM, Guglielmo Braguglia wrote:

this happen very often also to me ...

... I don't know, but ... if you are debugging your code
stepping-by-stepping and you stop the execution, some time LiveCode create
this problem.

The only solution is to save the stack, close LiveCode (/is not sufficient
to close the stack/) and restart ... your stack is ok, your code also and
if you compile ... NO ERRORS!


With all the people pointing out that this issue could arise legitimately by 
use of globals, I was hesitant to stick my head up - but I also think that 
there is an actual bug that can arise, almost certainly linked to use of 
debugger, where LC gets it into its head that there are two uses of a declared 
local though there aren't - a problem that can only be fixed, as Guglielmo and 
Pete confirm, by quitting and restarting LiveCode.


Unfortunately by it's nature I don't think there can be a recipe bug - so how 
can we report this in the RQCC?


Ben

___
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: Help! PlayCommand Agent X

2012-10-12 Thread René Micout
Thierry,
J'ai lu tous les derniers mails sur le sujet... Que de courage !  ;-)
René

Le 12 oct. 2012 à 17:41, Thierry Douez  a écrit :

> 2012/10/12 Peter M. Brigham :
>> Instead of delving into PlayCommand Agent X (whatever that is, and my 
>> ignorance may make this comment useless), could you not just write your own 
>> simpler custom play command in LC, to mirror what you get from shakobox, 
>> something along the lines of:
>> 
>> local tChannel, tVolume, tNote, tInstrument, tID, tTempo
>> 
>> on mbPlay tInstrument, tTempo, tNotes
>>   -- handle default assignments here
>>   -- get duration from the tTempo variable
>>   repeat for each item tNote in tNotes
>>  SunnYmidi.Play tChannel, tDuration, tVolume, tNote
>>   end repeat
>> end mbPlay
>> 
>> Probably too crude, but you get the idea. Am I out in left field thinking 
>> I'm playing soccer?
>> I usually look for an LC-native way of doing things.
> 
> Yes Peter, you are right.
> 
> Here is the code I posted yesterday on my 3 minutes to emulate Agent X,
> which just do what you are saying:
> 
> on SBplay instrument, _tempo, notestring
>   sunnYmidi.Set 1, "instrument", instrumentID( instrument)
>   sunnymidi.HCplay 1, _tempo, notestring
> end SBplay
> 
> on SBstartNote instrument, pitch, velocity
>   sunnYmidi.Set 1, "instrument", instrumentID( instrument)
>   sunnYmidi.Play, 1, -1, velocity, pitch
> end SBstartNote
> 
> on SBstopNote instrument,pitch
>   sunnYmidi.Set 1, "instrument", instrumentID( instrument)
>   sunnYmidi.Play, 1, 0, 0, pitch
> end SBstopNote
> 
> private function  instrumentID instrument
>   -- assuming the ID is correct
>   if instrument is a number then return instrument
>   -- custom prop containing on each line:  IDinstrument,InstrumentName
>   get the GM_Instruments of this stack
>   filter IT with "*," & instrument
>   if IT is empty then return 1 -- piano
>   return item 1 of IT -- the ID
> end instrumentID
> 
> With the proof: ( copy-paste this script from Shakobox documentation)
> 
> on mouseup
>  --"Nic's Russian Tune (Katyushka)" from "Knit Your Own Yoghurt"
>  put "e4q. f#4e g4q. e4e gq f#e ee f#q b3q f#q. ge aq. f#e aq ge f#eeq rq " & 
> \
>"b4q e5q d5q e5e d5e c5q b4e a4e b4q e4q c5q. a4e b4q. g4e a4q
> g4ef# 4e e4h " & \
>"g4q. a4e b4q. g4e b4q a4e g4e f#4q a4q a4q. b4e c5q. b4e c5q b4e
> a4e g4q rq " & \
>"e5q g5q b4q b4e d5e e5q d5e c5e e5q b4q e5q. c5e e4q. b4e d#5q
> e5e f#5e e5h"  \
>into theSong
>  sbplay 24,125,theSong
> end mouseup
> 
> 
> Thierry
> 
> ___
> 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: Strict Compile Mode

2012-10-12 Thread Bob Sneidar
Read my other post on this. If you want it to be visible only to your stack, 
store it in a property, then write a function called getGlobal() (or something 
like) and pass it a local variable name as a reference. Have the function 
retrieve the global in the referenced variable. You will also have to have a 
setGlobal() function (or something like). 

Bob


On Oct 12, 2012, at 9:29 AM, Peter Haworth wrote:

>> Hi Pete,
>> 
>> if you declare a variable "global",the variable IS GLOBAL FOR ANY STACK
>> and is "*persistent*". This means that the variable and its value exist
>> regardless of the stack that created. If you liketo see do just a simple
>> test ...
>> 
> 
> Wow, so a global declared in one stack can be accessed by a completely
> different stack, even if the declaring stack is not in memory.  That seems
> like a recipe for potential disaster, especially if you are writing plugins
> that are used by customers to access their own stacks.


___
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: defaultcursor problem

2012-10-12 Thread Bob Sneidar
Lock the cursor first. If you don't, it will revert the first idle it gets. As 
someone mentioned use the cursor. Locking it will prevent the reversion you are 
seeing. (It actually is changing but so fast you can't see it.)

Bob


On Oct 12, 2012, at 6:06 AM, Peter M. Brigham wrote:

> Anyone have an idea why this doesn't work? Put the following into the script 
> of an unlocked field:
> 
> on mousemove
>   put the commandkey is down into cmK
>   if cmK then
>  set the defaultcursor to hand
>   else
>  set the defaultcursor to empty
>   end if
> end mousemove
> 
> I want the cursor to become "hand" with the commandkey down, but it simply 
> remains a bar over an unlocked field. I swear this used to work, but for some 
> reason it no longer does. 2008 MacBook, OSX 10.7.4 (Lion), Rev Studio 4.5.3, 
> build 1210
> 
> -- Peter
> 
> Peter M. Brigham
> pmb...@gmail.com
> http://home.comcast.net/~pmbrig
> 
> 
> ___
> 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: Strict Compile Mode

2012-10-12 Thread Peter Haworth
On Thu, Oct 11, 2012 at 11:37 PM, Guglielmo Braguglia <
guglie...@braguglia.ch> wrote:

> Hi Pete,
>
> if you declare a variable "global",the variable IS GLOBAL FOR ANY STACK
> and is "*persistent*". This means that the variable and its value exist
> regardless of the stack that created. If you liketo see do just a simple
> test ...
>

Wow, so a global declared in one stack can be accessed by a completely
different stack, even if the declaring stack is not in memory.  That seems
like a recipe for potential disaster, especially if you are writing plugins
that are used by customers to access their own stacks.


> ... create a stack and create different scripts (e.g. some scriptfor some
> buttons). On the different scripts define "local" variable on the TOP of
> the script, before handlers. Assigns them a value. Now, if you insert some
> breakpoints (on the different scripts) you will see, still looking into the
> "Variables" TAB, that, when the script stop because reach the breakpoint
> (so the script is the current script), you will find the local variable of
> the script with the correct value.
>

I use script local variables a lot and often instead of global variables.
 A script local variable plus a set of handlers to read and write from it
seems a lot easier to deal with than global definitions in every script
that needs them, especially now I know about the cross-stack global
availability issue mentioned above.

I've also taken to using script local variables/access handlers instead of
using custom properties in locked stacks so users can't change the values
of critical information by simply bringing up the Inspector window.  I
still find it odd that password protecting a stack prevents access to its
scripts but not its custom properties; there at least ought to be an option
to apply password protection to custom properties.


>
> Please note that, also if this rules remain valid, the behavior of
> LiveCode is different if your "Strict Compile Mode" is ON or OFF !!! ...
> and this creates more confusion !!!
>
> With "Strict Compile Mode" ON ... you are obliged to declare the variable
> and LiveCode verify the "collisions" and give you error if one local have
> the same name of a global, BUT, if "Strict Compile Mode" is OFF, LiveCode
> don't verify the "collisions" and the same variable can be a local or a
> global depending on whether you declare it "global" or not :o ... and this
> is really ridiculous !!!
>

That's the crux of the question I posted in response to Mark's post.  The
whole implementation of globals in LC is really strange.  Especially since
it appears that LC "knows" about a global as soon as it is declared - why
then force people to re-declare them in every script that addresses them.
 I rarely use globals now but "rarely use" will change to "never" pretty
quickly!


>
> Hope this clarify the situation ... :-)
>

Yes, thanks Guglielmo.

>
> Guglielmo
>
___
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: Another reason I so dislike the LC IDE

2012-10-12 Thread Bob Sneidar
Try on closeStack;save this stack;pass closeStack;end closeStack

maybe try closeStackRequest

Bob


On Oct 12, 2012, at 7:09 AM, FlexibleLearning.com wrote:

> When I close a stack, the LC IDE insists on asking if I want to save it even
> when unnecessary (auto-save is built in).
> 
> I have tried these to no avail...
> 
> on closeStack
>  lock messages
> 
> on suspendStack
>  lock messages
> 
> on closeStackRequest
>  lock messages
> 
> Anything else? The culprit looks like an IDE backscript, but darned if I can
> find it and I cannot trace into it.
> 
> Any pointers to how to stop this damn dialog would be most welcome!
> 
> (As an asside, the MC IDE simply closes. No fuss, no intrusion.)
> 
> Hugh Senior
> FLCo
> 
> 
> ___
> 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: Strict Compile Mode

2012-10-12 Thread Bob Sneidar
Right. I have said before, I think there should be a stack or application 
global so that an application and it's substacks have access to it, but not 
foreign stacks. This is where things can go catawonkers if you are running two 
database enabled apps. It is recommended by RunRev to store your database id in 
a global. If I am in the habit of using the same variable name in all my 
database enabled stacks (which indeed I am), I will get into trouble, at least 
running them in the IDE. (Of course, because I use the method of opening the 
connection when I need it and closing it when I am done or idling, I don't have 
a problem.) 

The solution at present is to store the database ID in a stack property. Sure, 
I guess that will work. But it deviates from the recommended methodology is all 
I am saying. 

Bob


On Oct 11, 2012, at 11:37 PM, Guglielmo Braguglia wrote:

> Hi Pete,
> 
> if you declare a variable "global",the variable IS GLOBAL FOR ANY STACK and 
> is "*persistent*". This means that the variable and its value exist 
> regardless of the stack that created. If you liketo see do just a simple test 
> ...


___
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: [OT] Where ill conceived copyright laws can lead

2012-10-12 Thread Bob Sneidar
It's my understanding that the foundation of copyright is that the moment you 
author or create something, assuming you are the first one, your rights are in 
effect. Everything else is to quantify and execute that protection. It has been 
said that there are only 15 or so unique story lines. Apparently it's not the 
story lines that are protected, but rather the way in which the story is told. 
I suppose you could say the same thing about software. Word Processing is not 
copyrighted, but the method of delivering it is. 

Simply changing the names of everything in a story is not sufficient to 
distinguish it from the original. The new story must be uniquely different. So 
also with software. Changing all the variables and references to them is not 
enough to establish a new work. What they look for is methodology in coding. 
That this is somewhat of a grey area is not due to flaws in the principle of 
Copyrights, but rather the seemingly inexhaustible means by which men are 
capable of covering their tracks. 

Also, a copyright does not last in perpetuity. There is a time limit beyond 
which if it is not renewed, it will become nullified. So although the thread 
has been entertaining, it's rather baseless. 

Bob


On Oct 11, 2012, at 10:50 PM, Peter Haworth wrote:

> That's not copyright, that's patent, different thing although just as weird!
> 
> One problem with copyright laws is that, as with a lot of laws, they are
> different in every country.
> 
> Pete
> lcSQL Software 
> 
> 
> 
> On Thu, Oct 11, 2012 at 8:50 PM, Richmond wrote:
> 
>> The recent spat over whether one of the major mobile devices has nicked
>> parts of their GUI from
>> another is an example of how copyright is not used to protect but to bully.
>> 
> ___
> 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: [OT] Where ill conceived copyright laws can lead

2012-10-12 Thread Bob Sneidar
Don't forget the thousand concubines. I can only say he was warned not to do 
that. But it was I think mostly a way to secure peace with the surrounding 
tribes and peoples. Back then marrying another potentates daughter was a kind 
of peace treaty. And by the way, they kept really, really good records on that 
sort of thing, him being king and all. 

Bob


On Oct 11, 2012, at 8:50 PM, Richmond wrote:

> It's funny really, when he supposedly have hundreds of wives, how hard it is 
> to track down anybody
> who can actually, honestly say they are descended from him . . . LOL.


___
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: Help! PlayCommand Agent X

2012-10-12 Thread Thierry Douez
2012/10/12 Peter M. Brigham :
> Instead of delving into PlayCommand Agent X (whatever that is, and my 
> ignorance may make this comment useless), could you not just write your own 
> simpler custom play command in LC, to mirror what you get from shakobox, 
> something along the lines of:
>
> local tChannel, tVolume, tNote, tInstrument, tID, tTempo
>
> on mbPlay tInstrument, tTempo, tNotes
>-- handle default assignments here
>-- get duration from the tTempo variable
>repeat for each item tNote in tNotes
>   SunnYmidi.Play tChannel, tDuration, tVolume, tNote
>end repeat
> end mbPlay
>
> Probably too crude, but you get the idea. Am I out in left field thinking I'm 
> playing soccer?
>  I usually look for an LC-native way of doing things.

Yes Peter, you are right.

Here is the code I posted yesterday on my 3 minutes to emulate Agent X,
which just do what you are saying:

on SBplay instrument, _tempo, notestring
   sunnYmidi.Set 1, "instrument", instrumentID( instrument)
   sunnymidi.HCplay 1, _tempo, notestring
end SBplay

on SBstartNote instrument, pitch, velocity
   sunnYmidi.Set 1, "instrument", instrumentID( instrument)
   sunnYmidi.Play, 1, -1, velocity, pitch
end SBstartNote

on SBstopNote instrument,pitch
   sunnYmidi.Set 1, "instrument", instrumentID( instrument)
   sunnYmidi.Play, 1, 0, 0, pitch
end SBstopNote

private function  instrumentID instrument
   -- assuming the ID is correct
   if instrument is a number then return instrument
   -- custom prop containing on each line:  IDinstrument,InstrumentName
   get the GM_Instruments of this stack
   filter IT with "*," & instrument
   if IT is empty then return 1 -- piano
   return item 1 of IT -- the ID
end instrumentID

With the proof: ( copy-paste this script from Shakobox documentation)

on mouseup
  --"Nic's Russian Tune (Katyushka)" from "Knit Your Own Yoghurt"
  put "e4q. f#4e g4q. e4e gq f#e ee f#q b3q f#q. ge aq. f#e aq ge f#eeq rq " & \
"b4q e5q d5q e5e d5e c5q b4e a4e b4q e4q c5q. a4e b4q. g4e a4q
g4ef# 4e e4h " & \
"g4q. a4e b4q. g4e b4q a4e g4e f#4q a4q a4q. b4e c5q. b4e c5q b4e
a4e g4q rq " & \
"e5q g5q b4q b4e d5e e5q d5e c5e e5q b4q e5q. c5e e4q. b4e d#5q
e5e f#5e e5h"  \
into theSong
  sbplay 24,125,theSong
end mouseup


Thierry

___
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: Help! PlayCommand Agent X

2012-10-12 Thread Thierry Douez
Hi Marty,

2012/10/12 Marty Billingsley :
> Thanks Jon, I had looked at the tutorial. I personally find the interface 
> easy enough to use, but not suited to my curriculum, which is aimed at 
> 13-year-old beginning programmers. The curriculum progression that we go 
> through really wants some of the shakobox functionality, such as setting the 
> instrument at the same time as playing the note.  It also depends on the fact 
> that shakobox puts in default note durations and octaves, so we can start 
> very simply and add the complexity as students move through the project.

Write a LC handler which hides this to your student,

> Students can start with a command that has only one "mystery number" -- 
> "sbPlay 'harpsichord', 100, c' -- and go from there.


Have you read my last email (yesterday) ?

   3 minutes to emulate PlayCommand agent X on (Mountain) Lion

You could see that  few lines of LC code do that:  sbPlay,
'harpishord', 100, c

 I did copy from Shakobox doc a full tune, paste it in LC and play it!


If you don't like the Midi notation, simply transform your pitch name
in a LC handler.
LiveCode is for that.

> Too many mystery numbers in SunnYmidi.Play.

Mistery ?  channel, velocity, note ?

Again, as a Livecode user you certainly know that you can write any
command/fucntion you like,
set default values to whatever variable ?

If you want I can write a handler so your students can just type:

  myHarpishord 'high', 'C'

which is even less myterious than the  sbPlay ... above.


> sunnYmidi is great (and really flexible),
>  but not useful in the teaching environment I need it for.

Actually, 80% of sunnYmidi users  are musician teachers and as far as I know,
they enjoy it and the kids too.



>
> Thanks for all the replies.  Jacque pointed me to the source code
> -- thanks, Jacque -- so perhaps I can update PlayCommand Agent X.  If so, 
> I'll let y'all know.

I had this code 2 years ago before developping sunnYmidi. (Jacque sent it to me)
I choose to put it aside and to start from scratch.

I will be very interested to know how much time you spend on this road,
instead of writing your own wrapper in LC on the top of an existing external.

Anyway, good luck with your project.

Regards,

Thierry



> Jonathan Adams wrote:
>
>> Hi Marty,
>>
>> I am finding sunnYmidi extremely easy to use. Of course, because it has so 
>> many options it is easy to miss it but:
>>
>> 1) On startup, turn it on with: SunnYmidi.Start user, key--user and key 
>> are provided when you purchase.
>> 2) when quiting, you should turn it off with: SunnYmidi.Stop
>>
>> 3) To play notes it is: SunnYmidi.Play channel, duration, volume, note  
>> --put 1 into channel unless you need multiple channels, duration is 
>> milliseconds, volume 1-128 and pitch (60 is middle C)
>>
>> 4) Finally, you can change the instrument assigned to any channel with 
>> SunnYmidi.Set channel, "instrument", id  --id being standard GM voices (1 is 
>> piano, 74 is flute, etc.)
>>
>> Lots of other commands that you could use if you want but probably aren't 
>> necessary for what you want to do. You might however want to look at the 
>> command that emulates the hypercard player: sunnYmidi.HCplay channel, 
>> volume, "c3w d3h e3q f3e"  --although I haven't actually tried this command.
>>
>> Hope that helps,
>>
>> Jon

___
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: defaultcursor problem

2012-10-12 Thread André Bisseret
Bonjour Peter,

Below is the handlers that I am using in my stacks (thanks to Éric Chatonet)

I just added the case 2 (corresponding to your need)
Here (MacBook Pro 10.0.8 ; Rev 5.0.2) case 2 seems to work, as you are 
expecting.

Best regards from Grenoble

André

From Éric Chatonet
on mouseMove
switch
case "button" is in the target
ShowHandCursor #
break
---
case "field" is in the target and the lockText of the target is true\
and the listBehavior of the target is true
ShowHandCursor
break
case "field" is in the target and the lockText of the target is false
if the commandKey is down then
ShowHandCursor
end if
break
case the mouseText is "#" and the imageSource of the mouseText is not empty
ShowHandCursor
break
---
case the mouseText = empty --important!
unlock cursor
break
case "link" is in the textStyle of the mouseChunk
ShowHandCursor #
break
default
ResetCursor #
end switch
end mouseMove
--
on mouseLeave
 ResetCursor #
end mouseLeave
--
on ShowHandCursor
 set the cursor to hand
 lock cursor
end ShowHandCursor
--
on ResetCursor
unlock cursor
end ResetCursor
-



Le 12 oct. 2012 à 16:17, Peter M. Brigham a écrit :

> That never works. Setting "the cursor" will only be very fleeting, as the 
> cursor will revert to the defaultcursor at the next idle message, and it 
> happens so fast you never even see a flicker You can set "the cursor" then 
> lock the cursor, then unlock it in a mouseleave handler, and that will work, 
> but I learned a long time ago that this leads to persistent locked cursors, 
> since LC seems at times not to send "mouseleave" messages, eg when a modal 
> dialog is invoked, and randomly otherwise too.
> 
> I can set the defaultcursor successfully in other circumstances, eg, in a 
> mousemove handler over a button, to change it to "hand" to indicate to the 
> user that what's called for is a click on the button. I want to do the same 
> thing over an unlocked field when the commandkey is down, to indicate to the 
> user that a click is called for. I used to be able to do this, but now it 
> doesn't work any more.   
> 
> -- Peter
> 
> Peter M. Brigham
> pmb...@gmail.com
> http://home.comcast.net/~pmbrig
> 
> On Oct 12, 2012, at 9:36 AM, dunb...@aol.com wrote:
> 
>> Hi.
>> 
>> 
>> Try this with "the cursor" instead of "the defaultCursor".
>> 
>> 
>> Craig Newman
>> 
>> 
>> 
>> -Original Message-
>> From: Peter M. Brigham 
>> To: How to use LiveCode 
>> Sent: Fri, Oct 12, 2012 9:07 am
>> Subject: defaultcursor problem
>> 
>> 
>> Anyone have an idea why this doesn't work? Put the following into the script 
>> of 
>> an unlocked field:
>> 
>> on mousemove
>>  put the commandkey is down into cmK
>>  if cmK then
>> set the defaultcursor to hand
>>  else
>> set the defaultcursor to empty
>>  end if
>> end mousemove
>> 
>> I want the cursor to become "hand" with the commandkey down, but it simply 
>> remains a bar over an unlocked field. I swear this used to work, but for 
>> some 
>> reason it no longer does. 2008 MacBook, OSX 10.7.4 (Lion), Rev Studio 4.5.3, 
>> build 1210
>> 
>> -- Peter
>> 
>> Peter M. Brigham
>> pmb...@gmail.com
>> http://home.comcast.net/~pmbrig
>> 
>> 
>> ___
>> 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: defaultcursor problem

2012-10-12 Thread Peter M. Brigham
That never works. Setting "the cursor" will only be very fleeting, as the 
cursor will revert to the defaultcursor at the next idle message, and it 
happens so fast you never even see a flicker You can set "the cursor" then lock 
the cursor, then unlock it in a mouseleave handler, and that will work, but I 
learned a long time ago that this leads to persistent locked cursors, since LC 
seems at times not to send "mouseleave" messages, eg when a modal dialog is 
invoked, and randomly otherwise too.

I can set the defaultcursor successfully in other circumstances, eg, in a 
mousemove handler over a button, to change it to "hand" to indicate to the user 
that what's called for is a click on the button. I want to do the same thing 
over an unlocked field when the commandkey is down, to indicate to the user 
that a click is called for. I used to be able to do this, but now it doesn't 
work any more.   

-- Peter

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

On Oct 12, 2012, at 9:36 AM, dunb...@aol.com wrote:

> Hi.
> 
> 
> Try this with "the cursor" instead of "the defaultCursor".
> 
> 
> Craig Newman
> 
> 
> 
> -Original Message-
> From: Peter M. Brigham 
> To: How to use LiveCode 
> Sent: Fri, Oct 12, 2012 9:07 am
> Subject: defaultcursor problem
> 
> 
> Anyone have an idea why this doesn't work? Put the following into the script 
> of 
> an unlocked field:
> 
> on mousemove
>   put the commandkey is down into cmK
>   if cmK then
>  set the defaultcursor to hand
>   else
>  set the defaultcursor to empty
>   end if
> end mousemove
> 
> I want the cursor to become "hand" with the commandkey down, but it simply 
> remains a bar over an unlocked field. I swear this used to work, but for some 
> reason it no longer does. 2008 MacBook, OSX 10.7.4 (Lion), Rev Studio 4.5.3, 
> build 1210
> 
> -- Peter
> 
> Peter M. Brigham
> pmb...@gmail.com
> http://home.comcast.net/~pmbrig
> 
> 
> ___
> 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


Another reason I so dislike the LC IDE

2012-10-12 Thread FlexibleLearning.com
When I close a stack, the LC IDE insists on asking if I want to save it even
when unnecessary (auto-save is built in).

I have tried these to no avail...

on closeStack
  lock messages

on suspendStack
  lock messages

on closeStackRequest
  lock messages

Anything else? The culprit looks like an IDE backscript, but darned if I can
find it and I cannot trace into it.

Any pointers to how to stop this damn dialog would be most welcome!

(As an asside, the MC IDE simply closes. No fuss, no intrusion.)

Hugh Senior
FLCo


___
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: defaultcursor problem

2012-10-12 Thread dunbarx
Hi.


Try this with "the cursor" instead of "the defaultCursor".


Craig Newman



-Original Message-
From: Peter M. Brigham 
To: How to use LiveCode 
Sent: Fri, Oct 12, 2012 9:07 am
Subject: defaultcursor problem


Anyone have an idea why this doesn't work? Put the following into the script of 
an unlocked field:

on mousemove
   put the commandkey is down into cmK
   if cmK then
  set the defaultcursor to hand
   else
  set the defaultcursor to empty
   end if
end mousemove

I want the cursor to become "hand" with the commandkey down, but it simply 
remains a bar over an unlocked field. I swear this used to work, but for some 
reason it no longer does. 2008 MacBook, OSX 10.7.4 (Lion), Rev Studio 4.5.3, 
build 1210

-- Peter

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


___
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: Help! PlayCommand Agent X

2012-10-12 Thread Peter M. Brigham
Instead of delving into PlayCommand Agent X (whatever that is, and my ignorance 
may make this comment useless), could you not just write your own simpler 
custom play command in LC, to mirror what you get from shakobox, something 
along the lines of:

local tChannel, tVolume, tNote, tInstrument, tID, tTempo

on mbPlay tInstrument, tTempo, tNotes
   -- handle default assignments here
   -- get duration from the tTempo variable
   repeat for each item tNote in tNotes
  SunnYmidi.Play tChannel, tDuration, tVolume, tNote
   end repeat
end mbPlay

Probably too crude, but you get the idea. Am I out in left field thinking I'm 
playing soccer? I usually look for an LC-native way of doing things.

-- Peter

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


On Oct 12, 2012, at 9:06 AM, Marty Billingsley wrote:

> Thanks Jon, I had looked at the tutorial. I personally find the interface 
> easy enough to use, but not suited to my curriculum, which is aimed at 
> 13-year-old beginning programmers. The curriculum progression that we go 
> through really wants some of the shakobox functionality, such as setting the 
> instrument at the same time as playing the note.  It also depends on the fact 
> that shakobox puts in default note durations and octaves, so we can start 
> very simply and add the complexity as students move through the project.  
> Students can start with a command that has only one "mystery number" -- 
> "sbPlay 'harpsichord', 100, c' -- and go from there.  Too many mystery 
> numbers in SunnYmidi.Play.
> 
> sunnYmidi is great (and really flexible), but not useful in the teaching 
> environment I need it for.  
> 
> Thanks for all the replies.  Jacque pointed me to the source code -- thanks, 
> Jacque -- so perhaps I can update PlayCommand Agent X.  If so, I'll let y'all 
> know.
> 
> cheers,
> - marty
> 
> --
> Marty Billingsley
> Department of Computer Science
> The University of Chicago Laboratory Schools
> 
> Jonathan Adams wrote:
> 
>> 
>> 
>>> The sunnYmidie interface looks a LOT more complicated than the interface of 
>>> shakobox (which uses PlayCommand Agent X).  I'm basically looking for 
>>> something that will mimic the old Hypercard "play" command, which wanted an 
>>> instrument, a tempo, and a note or list of notes.  Unless I'm misreading 
>>> the tutorial, sunnYmidi is way too complicated for my students.
>> 
>> Hi Marty,
>> 
>> I am finding sunnYmidi extremely easy to use. Of course, because it has so 
>> many options it is easy to miss it but:
>> 
>> 1) On startup, turn it on with: SunnYmidi.Start user, key--user and key 
>> are provided when you purchase.
>> 2) when quiting, you should turn it off with: SunnYmidi.Stop
>> 
>> 3) To play notes it is: SunnYmidi.Play channel, duration, volume, note  
>> --put 1 into channel unless you need multiple channels, duration is 
>> milliseconds, volume 1-128 and pitch (60 is middle C)
>> 
>> 4) Finally, you can change the instrument assigned to any channel with 
>> SunnYmidi.Set channel, "instrument", id  --id being standard GM voices (1 is 
>> piano, 74 is flute, etc.)
>> 
>> Lots of other commands that you could use if you want but probably aren't 
>> necessary for what you want to do. You might however want to look at the 
>> command that emulates the hypercard player: sunnYmidi.HCplay channel, 
>> volume, "c3w d3h e3q f3e"  --although I haven't actually tried this command.
>> 
>> Hope that helps,
>> 
>> Jon
>> 
>> 
> 
> ___
> 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: Help! PlayCommand Agent X

2012-10-12 Thread Marty Billingsley
Thanks Jon, I had looked at the tutorial. I personally find the interface easy 
enough to use, but not suited to my curriculum, which is aimed at 13-year-old 
beginning programmers. The curriculum progression that we go through really 
wants some of the shakobox functionality, such as setting the instrument at the 
same time as playing the note.  It also depends on the fact that shakobox puts 
in default note durations and octaves, so we can start very simply and add the 
complexity as students move through the project.  Students can start with a 
command that has only one "mystery number" -- "sbPlay 'harpsichord', 100, c' -- 
and go from there.  Too many mystery numbers in SunnYmidi.Play.

sunnYmidi is great (and really flexible), but not useful in the teaching 
environment I need it for.  

Thanks for all the replies.  Jacque pointed me to the source code -- thanks, 
Jacque -- so perhaps I can update PlayCommand Agent X.  If so, I'll let y'all 
know.

cheers,
 - marty

--
Marty Billingsley
Department of Computer Science
The University of Chicago Laboratory Schools

Jonathan Adams wrote:

> 
> 
>> The sunnYmidie interface looks a LOT more complicated than the interface of 
>> shakobox (which uses PlayCommand Agent X).  I'm basically looking for 
>> something that will mimic the old Hypercard "play" command, which wanted an 
>> instrument, a tempo, and a note or list of notes.  Unless I'm misreading the 
>> tutorial, sunnYmidi is way too complicated for my students.
> 
> Hi Marty,
> 
> I am finding sunnYmidi extremely easy to use. Of course, because it has so 
> many options it is easy to miss it but:
> 
> 1) On startup, turn it on with: SunnYmidi.Start user, key--user and key 
> are provided when you purchase.
> 2) when quiting, you should turn it off with: SunnYmidi.Stop
> 
> 3) To play notes it is: SunnYmidi.Play channel, duration, volume, note  --put 
> 1 into channel unless you need multiple channels, duration is milliseconds, 
> volume 1-128 and pitch (60 is middle C)
> 
> 4) Finally, you can change the instrument assigned to any channel with 
> SunnYmidi.Set channel, "instrument", id  --id being standard GM voices (1 is 
> piano, 74 is flute, etc.)
> 
> Lots of other commands that you could use if you want but probably aren't 
> necessary for what you want to do. You might however want to look at the 
> command that emulates the hypercard player: sunnYmidi.HCplay channel, volume, 
> "c3w d3h e3q f3e"  --although I haven't actually tried this command.
> 
> Hope that helps,
> 
> Jon
> 
> 

___
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


defaultcursor problem

2012-10-12 Thread Peter M. Brigham
Anyone have an idea why this doesn't work? Put the following into the script of 
an unlocked field:

on mousemove
   put the commandkey is down into cmK
   if cmK then
  set the defaultcursor to hand
   else
  set the defaultcursor to empty
   end if
end mousemove

I want the cursor to become "hand" with the commandkey down, but it simply 
remains a bar over an unlocked field. I swear this used to work, but for some 
reason it no longer does. 2008 MacBook, OSX 10.7.4 (Lion), Rev Studio 4.5.3, 
build 1210

-- Peter

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


___
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