Re: SubMenu

2017-01-25 Thread Yves COPPE via use-livecode
Hi,

I’ve tried it as you say but this (two) icons with 3 bars are disabled and so 
it doesn’t luck
Any idea ?

Cordialement.

Yves COPPE
yvesco...@mac.com





> Le 26 janv. 2017 à 00:42, J. Landman Gay via use-livecode 
>  a écrit :
> 
> On 1/25/17 2:34 PM, Yves COPPE via use-livecode wrote:
>> How can I create a submenu with the Menu Builder in LiveCode 8.1.2 ?
> 
> Create a new menu item in the right-side column. Select the new item and 
> click the icon with 3 bars and a right-pointing arrow just above the column. 
> (It's under the "Delete Item" button.) That moves it into a submenu.
> 
> Really all it does is add a tab before the menu item name. You can do that 
> manually too by editing the menu button contents.
> 
> -- 
> Jacqueline Landman Gay | jac...@hyperactivesw.com
> HyperActive Software   | http://www.hyperactivesw.com
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

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

Re: Detecting clicks in Segmented Control widget

2017-01-25 Thread hlowe via use-livecode
Thank you for the detailed reply. I will take a look at this possible
solution.

Henry



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Detecting-clicks-in-Segmented-Control-widget-tp4711930p4711943.html
Sent from the Revolution - User mailing list archive at Nabble.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: use-livecode Digest, Vol 160, Issue 48

2017-01-25 Thread Trevor DeVore via use-livecode
On Wed, Jan 25, 2017 at 6:05 PM, Peter Thirkell via use-livecode <
use-livecode@lists.runrev.com> wrote:

> Thanks Trevor for a very informative posting. It deserves a wider audience
> as well, perhaps on the Livecode Forum?
>
> I have been wondering about the move to script-only stacks as well, so
> this is timely advice. In terms of the application framework that you
> mention - Levure - does this essentially replace your  use of the GLX
> framework?
>

 Yes, Levure will replace the GLX App Framework going forward. The
framework supports “helpers” which are folders containing stacks,
extensions, or externals that add functionality to an app. I extracted a
number of features from the GLX App framework, updated them, and turned
them into helpers that are included in the download. You can see them here:

https://github.com/trevordevore/levure/tree/master/framework/helpers

There is still some documentation work to do before inviting a large
audience to take a look at it. The README contains the notes I made while
designing the framework but leaves much to be desired. Of course if anyone
wants to jump in and do code reviews or otherwise contribute that would be
very helpful.

-- 
Trevor DeVore
Outcome & ScreenSteps
www.outcomeapp.io - www.screensteps.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: use-livecode Digest, Vol 160, Issue 48

2017-01-25 Thread Peter Thirkell via use-livecode
Thanks Trevor for a very informative posting. It deserves a wider audience as 
well, perhaps on the Livecode Forum?

I have been wondering about the move to script-only stacks as well, so this is 
timely advice. In terms of the application framework that you mention - Levure 
- does this essentially replace your  use of the GLX framework?

Peter Thirkell

Re:
> Message: 16
> Date: Wed, 25 Jan 2017 17:19:08 -0600
> From: Trevor DeVore 
> To: How to use LiveCode 
> Subject: Re: Deployment question
> 
> On Wed, Jan 25, 2017 at 2:49 PM, Malte Brill via use-livecode <
> use-livecode@lists.runrev.com> wrote:
> 
>> Now, I would really like to make the first serious standalone using 8.x
>> (final might be using 9.x). This is still a bit ahead, but I want to
>> prepare. I would really like to work with script only stacks. But what do
>> we need to do to have them available as library in a standalone. Right now
>> I am being lazy with my project and make regular stacks a substack of my
>> mainstack, which I then start using. How would I go about this with a
>> Script only stack, which appears to be only a text file, right? Upside
>> until now was quasi single file distribution, but I could very well live
>> with breaking that. Any good tips on deployment?
>> 
> 
> Hi Malte,
> 
> I bit the bullet in early November and started moving ScreenSteps over to
> script only stacks. My goal was to store my files in a VCS-friendly way (as
> much as possible). I moved all code over 3-5 lines out stacks and into
> script only stacks. To facilitate this I added some utilities to the PI in
> LC 9 that make it easy to create script only stacks from stacks you have
> open in the IDE. If you are going to convert an existing app over then I
> would suggest doing the conversion in LC 9. You can then go back to LC 8 if
> you want for working on the app.
> 
> I?ll describe the basics of what I did.
> 
> All of my libraries are individual script only stack files. When I package
> up the application I create a ?Libraries? stack and make all script script
> only stacks that are libraries a sub stack of this stack. The standalone
> just loads a single stack file. I do the same for front and back scripts as
> well.
> 
> For script only stacks used as behaviors it depends. For behaviors that are
> used generally I treat them as library stacks and package them up into a
> single stack. Every stack used for UI was moved into its own folder with a
> ?behaviors? folder that sits alongside the stack file. All code related to
> the UI stack goes into script only stack files in that ?behaviors? folder.
> These behaviors are just converted to regular stack files when I package up
> for distribution. The behavior stack files are assigned to the stackfiles
> property of the UI stack using relative paths. They are automatically
> loaded by the engine when the UI stack opens.
> 
> Having all of the code in text files has worked really well so far. Working
> with git has become really easy for scripts and I have been keeping an
> exact history of changes through git commits. Having everything in git
> makes it really easy to move between computers as well. Just checkout the
> latest and I?m ready to get to work. The stack files are another story but
> that is a problem for another day. Script only stacks also allowed me to
> move over to Sublime Text for all of my script editing. I put together a
> LiveCode plugin and linter and coding is much faster as I can jump around
> in the code really quickly. The plugin also communicates with my LiveCode
> app and refreshes scripts whenever I save in Sublime Text so I can edit
> while editing my app in LiveCode.
> 
> In order to make managing a script only stack-centric application easier I
> created a new application framework - Levure. You can see what I?ve done so
> far here:
> 
> https://github.com/trevordevore/levure
> 
> It use YAML for configuration and has a modular design. It manages building
> standalones and packaging everything up for deployment. I?ve been refining
> it over the last 2 1/2 months and there is still more work to do. I will be
> building an app to distribute to customers before the end of January though.
> 
> Let me know if you have any further questions.
> 
> -- 
> Trevor DeVore
> Outcome & ScreenSteps
> www.outcomeapp.io - www.screensteps.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: SubMenu

2017-01-25 Thread dunbarx via use-livecode
I assume that v8 works the same as v6.

The menuItems are just the contents of a button. So in any of the button
types that suit you, subMenus are distinguished by preceding tab characters:

A
B
(tab) c
(tab) d
E
F

Her the "c" and "d' will be a submenu of "B".

Check out the user guide. There are other control characters that allow you
to customize menuItems.

Craig



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/SubMenu-tp4711935p4711940.html
Sent from the Revolution - User mailing list archive at Nabble.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: SubMenu

2017-01-25 Thread J. Landman Gay via use-livecode

On 1/25/17 2:34 PM, Yves COPPE via use-livecode wrote:

How can I create a submenu with the Menu Builder in LiveCode 8.1.2 ?


Create a new menu item in the right-side column. Select the new item and 
click the icon with 3 bars and a right-pointing arrow just above the 
column. (It's under the "Delete Item" button.) That moves it into a submenu.


Really all it does is add a tab before the menu item name. You can do 
that manually too by editing the menu button contents.


--
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: Dumb deployment question

2017-01-25 Thread Trevor DeVore via use-livecode
Where Monte = Malte.

Sorry about that.

-- 
Trevor DeVore

On Wed, Jan 25, 2017 at 5:19 PM Trevor DeVore 
wrote:

> On Wed, Jan 25, 2017 at 2:49 PM, Malte Brill via use-livecode <
> use-livecode@lists.runrev.com> wrote:
>
> Now, I would really like to make the first serious standalone using 8.x
> (final might be using 9.x). This is still a bit ahead, but I want to
> prepare. I would really like to work with script only stacks. But what do
> we need to do to have them available as library in a standalone. Right now
> I am being lazy with my project and make regular stacks a substack of my
> mainstack, which I then start using. How would I go about this with a
> Script only stack, which appears to be only a text file, right? Upside
> until now was quasi single file distribution, but I could very well live
> with breaking that. Any good tips on deployment?
>
>
> Hi Monte,
>
> I bit the bullet in early November and started moving ScreenSteps over to
> script only stacks. My goal was to store my files in a VCS-friendly way (as
> much as possible). I moved all code over 3-5 lines out stacks and into
> script only stacks. To facilitate this I added some utilities to the PI in
> LC 9 that make it easy to create script only stacks from stacks you have
> open in the IDE. If you are going to convert an existing app over then I
> would suggest doing the conversion in LC 9. You can then go back to LC 8 if
> you want for working on the app.
>
> I’ll describe the basics of what I did.
>
> All of my libraries are individual script only stack files. When I package
> up the application I create a “Libraries” stack and make all script script
> only stacks that are libraries a sub stack of this stack. The standalone
> just loads a single stack file. I do the same for front and back scripts as
> well.
>
> For script only stacks used as behaviors it depends. For behaviors that
> are used generally I treat them as library stacks and package them up into
> a single stack. Every stack used for UI was moved into its own folder with
> a “behaviors” folder that sits alongside the stack file. All code related
> to the UI stack goes into script only stack files in that “behaviors”
> folder. These behaviors are just converted to regular stack files when I
> package up for distribution. The behavior stack files are assigned to the
> stackfiles property of the UI stack using relative paths. They are
> automatically loaded by the engine when the UI stack opens.
>
> Having all of the code in text files has worked really well so far.
> Working with git has become really easy for scripts and I have been keeping
> an exact history of changes through git commits. Having everything in git
> makes it really easy to move between computers as well. Just checkout the
> latest and I’m ready to get to work. The stack files are another story but
> that is a problem for another day. Script only stacks also allowed me to
> move over to Sublime Text for all of my script editing. I put together a
> LiveCode plugin and linter and coding is much faster as I can jump around
> in the code really quickly. The plugin also communicates with my LiveCode
> app and refreshes scripts whenever I save in Sublime Text so I can edit
> while editing my app in LiveCode.
>
> In order to make managing a script only stack-centric application easier I
> created a new application framework - Levure. You can see what I’ve done so
> far here:
>
> https://github.com/trevordevore/levure
>
> It use YAML for configuration and has a modular design. It manages
> building standalones and packaging everything up for deployment. I’ve been
> refining it over the last 2 1/2 months and there is still more work to do.
> I will be building an app to distribute to customers before the end of
> January though.
>
> Let me know if you have any further questions.
>
> --
> Trevor DeVore
> Outcome & ScreenSteps
> www.outcomeapp.io - www.screensteps.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: Dumb deployment question

2017-01-25 Thread Trevor DeVore via use-livecode
On Wed, Jan 25, 2017 at 2:49 PM, Malte Brill via use-livecode <
use-livecode@lists.runrev.com> wrote:

> Now, I would really like to make the first serious standalone using 8.x
> (final might be using 9.x). This is still a bit ahead, but I want to
> prepare. I would really like to work with script only stacks. But what do
> we need to do to have them available as library in a standalone. Right now
> I am being lazy with my project and make regular stacks a substack of my
> mainstack, which I then start using. How would I go about this with a
> Script only stack, which appears to be only a text file, right? Upside
> until now was quasi single file distribution, but I could very well live
> with breaking that. Any good tips on deployment?
>

Hi Monte,

I bit the bullet in early November and started moving ScreenSteps over to
script only stacks. My goal was to store my files in a VCS-friendly way (as
much as possible). I moved all code over 3-5 lines out stacks and into
script only stacks. To facilitate this I added some utilities to the PI in
LC 9 that make it easy to create script only stacks from stacks you have
open in the IDE. If you are going to convert an existing app over then I
would suggest doing the conversion in LC 9. You can then go back to LC 8 if
you want for working on the app.

I’ll describe the basics of what I did.

All of my libraries are individual script only stack files. When I package
up the application I create a “Libraries” stack and make all script script
only stacks that are libraries a sub stack of this stack. The standalone
just loads a single stack file. I do the same for front and back scripts as
well.

For script only stacks used as behaviors it depends. For behaviors that are
used generally I treat them as library stacks and package them up into a
single stack. Every stack used for UI was moved into its own folder with a
“behaviors” folder that sits alongside the stack file. All code related to
the UI stack goes into script only stack files in that “behaviors” folder.
These behaviors are just converted to regular stack files when I package up
for distribution. The behavior stack files are assigned to the stackfiles
property of the UI stack using relative paths. They are automatically
loaded by the engine when the UI stack opens.

Having all of the code in text files has worked really well so far. Working
with git has become really easy for scripts and I have been keeping an
exact history of changes through git commits. Having everything in git
makes it really easy to move between computers as well. Just checkout the
latest and I’m ready to get to work. The stack files are another story but
that is a problem for another day. Script only stacks also allowed me to
move over to Sublime Text for all of my script editing. I put together a
LiveCode plugin and linter and coding is much faster as I can jump around
in the code really quickly. The plugin also communicates with my LiveCode
app and refreshes scripts whenever I save in Sublime Text so I can edit
while editing my app in LiveCode.

In order to make managing a script only stack-centric application easier I
created a new application framework - Levure. You can see what I’ve done so
far here:

https://github.com/trevordevore/levure

It use YAML for configuration and has a modular design. It manages building
standalones and packaging everything up for deployment. I’ve been refining
it over the last 2 1/2 months and there is still more work to do. I will be
building an app to distribute to customers before the end of January though.

Let me know if you have any further questions.

-- 
Trevor DeVore
Outcome & ScreenSteps
www.outcomeapp.io - www.screensteps.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

Dumb deployment question

2017-01-25 Thread Malte Brill via use-livecode
Folks, please forgive me. I have not yet deployed with one of the current 
engines. Las standalone was built using 7 (gnashing my teeth a little bit).
Now, I would really like to make the first serious standalone using 8.x (final 
might be using 9.x). This is still a bit ahead, but I want to prepare. I would 
really like to work with script only stacks. But what do we need to do to have 
them available as library in a standalone. Right now I am being lazy with my 
project and make regular stacks a substack of my mainstack, which I then start 
using. How would I go about this with a Script only stack, which appears to be 
only a text file, right? Upside until now was quasi single file distribution, 
but I could very well live with breaking that. Any good tips on deployment?

Thanks a heap,

Malte


___
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


SubMenu

2017-01-25 Thread Yves COPPE via use-livecode
Hello,

How can I create a submenu with the Menu Builder in LiveCode 8.1.2 ?

Thanks.

Greetings.

Yves COPPE
yvesco...@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: Detecting clicks in Segmented Control widget

2017-01-25 Thread Mike Bonner via use-livecode
If you don't mind the message on re-click being another "hiliteChanged"
message, you can tweak it on your own.

If you're on windows, go to your x86 programs folder/runrev/ then the
version you're using. Guessing 8.1.1.  Then extensions
Copy the segmented control folder out to where you can work on it safely
(and I renamed it to com.livecode.widget.segmented2)
Then with a text editor, edit the lcb file inside.

Change the metadata for the title to segmented control2 (or whatever)
Change the version (start at 1.0.0?)

Then find the onClick handler and make it look like this:

public handler OnClick() returns nothing

variable tLabel as String
variable tSegment
variable tCount as Integer

variable tX as Integer
put clickPosToComponent(the click position) into tX

if tX is 0 then
return
end if

if mMultiSelect is false then
-- if cannot multiselect, then need to select the clicked-on segment and
deselect the currently selected segment
-- if the clicked-on segment is already selected, then do nothing
* if not (tX is in mSelectedSegments) then*
* setSelection([tX])*
* else*
* post "hiliteChanged" -- if the segment was already hilited, send a
hilitechanged anyway*
* end if*
else
-- if can multiselect, then select the clicked-on segment if it is
unselected or unselect if its selected
  if tX is in mSelectedSegments then
removeFromSelection(tX)
else
addToSelection(tX)
end if
end if
end handler

If you have it set for multi hilites, it should toggle segments on and off
as expected and you should see a hiliteChanged in those instances still.

I can get the version in 9 dp2 to pop out a mouseup but haven't been able
to do so in 8 versions so this is my best answer. (despite it not being the
best way i'm sure)

once the file is changed, save it.  Start up LC.

Go to tools and choose extension bulder.

Click the folder icon near the top, and browse to where the modified lcb
file is located and choose it.

At this point you can click test and it should pop up a stack with the
control already placed. Or click "install" and a second segmented control
should show up in your toolbar.

Drag it out and set up the hilite changed handler so that you know its
firing (like maybe have it output a random number so you can see it change)
  Then click the same segment and see if it works as expected.

Since I'm still clueless about lcb, you might have to do some hoop jumping
to track if it IS actually the same segment each time, but you can track
the hiliteditems and hilitednames of the control so it should be easy to
do.

If things don't work as expected, you can go to the extension manager and
uninstall your new control.

Also, I'd recommend against trying to edit the current one in place.
Various things went missing on me when I tried that (including the whole
folder for that extension!) and i've no clue where they went. (Learning is
FUN!)

On Wed, Jan 25, 2017 at 11:13 AM, hlowe via use-livecode <
use-livecode@lists.runrev.com> wrote:

> I am switching over from a home-grown segmented control to LC's Segmented
> Control widget. This widget receives a "hiliteChanged" message when the
> selected segment changes but (apparently) no message is received by the
> widget if the user clicks in the currently selected segment. I need to
> respond to the user clicking in the currently selected segment of the
> widget. Anyone know if it is possible to detect this event in the Segmented
> Control widget? The widget does not appear to receive MouseUp or MouseDown
> messages when clicked.
>
> Thanks,
>
> Henry
>
>
>
> --
> View this message in context: http://runtime-revolution.
> 278305.n4.nabble.com/Detecting-clicks-in-Segmented-
> Control-widget-tp4711930.html
> Sent from the Revolution - User mailing list archive at Nabble.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: set the menubar activates in-window menu on mac

2017-01-25 Thread J. Landman Gay via use-livecode

On 1/24/17 6:50 PM, Dr. Hawkins via use-livecode wrote:

set the menubar of stack st to stMen

This causes a X-style menu to appear in the stack window, not what I was
aiming for . . .

According to the dictionary, this should simply set the menu, not override.


If the menu should be available to all stacks (on OS X) then you should 
set the defaultMenubar.


If the menu should only be available to a single stack, set the menubar 
as you are doing now, and set the editMenus of the stack to false. This 
will cause the stack to truncate slightly as it scrolls up to hide the 
menu group.


An alternate approach is to simply set the menubar of the stack to a 
hidden menu group. That way no scrolling occurs.


--
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: Storing and object reference in a var

2017-01-25 Thread Sannyasin Brahmanathaswami via use-livecode
Edit;

get a grip on creating custom visual effect that I can use "all over the place" 
by creating an external script/text stack


-
Exactly

I'm studying scripts by some "pros" (Jacque, David, Malte-animation engine)

in order to get a group on creating custom visual effect that I can use 
"all over the place" but creating an external script/text stack

I've been doing server side script for so many years, the whole UI coding 
is all new but a lot more fun!

so If you want "safe" generic handlers… and you don’t' want to worry about 
the name space collisions you need to use the long ID

to drive things like this

put the long id of  grp "lessonTextControl"  into pEffectsTarget
send "object_FadeOut pEffectsTarget,0, 2, 20" to me 
wait for 2 seconds with messages


#then in your library:

command object_FadeIn  pEffectsTarget, newBlendLevel, someIncrement, 
someDelay
   set the blendLevel of  pEffectsTarget  to newBlendLevel
   if newBlendLevel > 0 then
  subtract someIncrement from newBlendLevel
  send "object_FadeIn pEffectsTarget, 
newBlendLevel,someIncrement,someDelay" to me in someDelay milliseconds
   else
  set the blendLevel of pEffectsTarget to 0
   end if
end object_FadeIn

command object_FadeOut  pEffectsTarget, newBlendLevel, someIncrement, 
someDelay
   set the blendLevel of  pEffectsTarget  to newBlendLevel
   if newBlendLevel <100 then
  add someIncrement to newBlendLevel
  send "object_FadeOut pEffectsTarget, 
newBlendLevel,someIncrement,someDelay" to me in someDelay milliseconds
   else
  set the blendLevel of pEffectsTarget to 100
   end if
end object_FadeOut

Disclaimer: I am not a real programmer and I don't really know what I am 
doing, but because it is LiveCode I can still reach my goals ☺

___
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: dateitems day-of-week disjunction

2017-01-25 Thread Devin Asay via use-livecode
Fix submitted.

https://github.com/livecode/livecode/pull/5118

Devin


On Jan 25, 2017, at 10:28 AM, panagiotis merakos via use-livecode 
mailto:use-livecode@lists.runrev.com>> wrote:

It was confirmed as a docs bug some time ago:

http://quality.livecode.com/show_bug.cgi?id=16044

Panos
--

On Wed, Jan 25, 2017 at 5:23 PM, Bob Sneidar via use-livecode <
use-livecode@lists.runrev.com> wrote:

I believe it depends on the system settings. If your localization is set
to where Sunday is the 1st day of the week, then Wednesday would in fact be
the 4th.

Bob S


On Jan 25, 2017, at 09:16 , Ben Rubinstein via use-livecode <
use-livecode@lists.runrev.com>
wrote:

The dictionary says that the seventh item of dateitems is
the numeric day of the week where Monday is day 1, Tuesday is day 2, and
so forth

When I try this I find that today, Wednesday, the seventh item is 4.  If I
change the date to Sunday, it's 1.

(Both docs and behaviour are consistent with 6.7.11 or 8.1.3 (rc 1) or
versions in between.)

Is this an error in the documentation, or an error in the code (in which
case too long standing to change, so it might as well be treated as an
error in the docs); or is it due to some setting somewhere?

TIA.

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

___
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

Devin Asay
Director
Office of Digital Humanities
Brigham Young University

___
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


Detecting clicks in Segmented Control widget

2017-01-25 Thread hlowe via use-livecode
I am switching over from a home-grown segmented control to LC's Segmented
Control widget. This widget receives a "hiliteChanged" message when the
selected segment changes but (apparently) no message is received by the
widget if the user clicks in the currently selected segment. I need to
respond to the user clicking in the currently selected segment of the
widget. Anyone know if it is possible to detect this event in the Segmented
Control widget? The widget does not appear to receive MouseUp or MouseDown
messages when clicked.

Thanks,

Henry



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Detecting-clicks-in-Segmented-Control-widget-tp4711930.html
Sent from the Revolution - User mailing list archive at Nabble.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: Storing and object reference in a var

2017-01-25 Thread Sannyasin Brahmanathaswami via use-livecode
Exactly

I'm studying scripts by some "pros" (Jacque, David, Malte-animation engine)

in order to get a group on creating custom visual effect that I can use "all 
over the place" but creating an external script/text stack

I've been doing server side script for so many years, the whole UI coding is 
all new but a lot more fun!

so If you want "safe" generic handlers… and you don’t' want to worry about the 
name space collisions you need to use the long ID

to drive things like this

put the long id of  grp "lessonTextControl"  into pEffectsTarget
send "object_FadeOut pEffectsTarget,0, 2, 20" to me 
wait for 2 seconds with messages


#then in your library:

command object_FadeIn  pEffectsTarget, newBlendLevel, someIncrement, someDelay
   set the blendLevel of  pEffectsTarget  to newBlendLevel
   if newBlendLevel > 0 then
  subtract someIncrement from newBlendLevel
  send "object_FadeIn pEffectsTarget, 
newBlendLevel,someIncrement,someDelay" to me in someDelay milliseconds
   else
  set the blendLevel of pEffectsTarget to 0
   end if
end object_FadeIn

command object_FadeOut  pEffectsTarget, newBlendLevel, someIncrement, someDelay
   set the blendLevel of  pEffectsTarget  to newBlendLevel
   if newBlendLevel <100 then
  add someIncrement to newBlendLevel
  send "object_FadeOut pEffectsTarget, 
newBlendLevel,someIncrement,someDelay" to me in someDelay milliseconds
   else
  set the blendLevel of pEffectsTarget to 100
   end if
end object_FadeOut

Disclaimer: I am not a real programmer and I don't really know what I am doing, 
but because it is LiveCode I can still reach my goals ☺

BR




 

On 1/25/17, 5:44 AM, "use-livecode on behalf of Bob Sneidar via use-livecode" 
 wrote:

I want to create a variable called tTargetField so I use

put "Hello" into tTargetField

Now I want to put something into a field so I create a variable called 
tTargetField2 and
put the long id of field "foo" into tTargetfield2

Then to put something into the field I
put "Hello" into tTargetField2

Now do you see? All I am doing here is replacing the value of tTargetField2 
that used to contain the long id of field "foo" with the word "Hello". How does 
the engine know what you mean? It's Ambiguous.

Bob S



___
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: dateitems day-of-week disjunction

2017-01-25 Thread panagiotis merakos via use-livecode
It was confirmed as a docs bug some time ago:

http://quality.livecode.com/show_bug.cgi?id=16044

Panos
--

On Wed, Jan 25, 2017 at 5:23 PM, Bob Sneidar via use-livecode <
use-livecode@lists.runrev.com> wrote:

> I believe it depends on the system settings. If your localization is set
> to where Sunday is the 1st day of the week, then Wednesday would in fact be
> the 4th.
>
> Bob S
>
>
> On Jan 25, 2017, at 09:16 , Ben Rubinstein via use-livecode <
> use-livecode@lists.runrev.com>
> wrote:
>
> The dictionary says that the seventh item of dateitems is
> the numeric day of the week where Monday is day 1, Tuesday is day 2, and
> so forth
>
> When I try this I find that today, Wednesday, the seventh item is 4.  If I
> change the date to Sunday, it's 1.
>
> (Both docs and behaviour are consistent with 6.7.11 or 8.1.3 (rc 1) or
> versions in between.)
>
> Is this an error in the documentation, or an error in the code (in which
> case too long standing to change, so it might as well be treated as an
> error in the docs); or is it due to some setting somewhere?
>
> TIA.
>
> 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
>
___
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: dateitems day-of-week disjunction

2017-01-25 Thread Bob Sneidar via use-livecode
I believe it depends on the system settings. If your localization is set to 
where Sunday is the 1st day of the week, then Wednesday would in fact be the 
4th.

Bob S


On Jan 25, 2017, at 09:16 , Ben Rubinstein via use-livecode 
mailto:use-livecode@lists.runrev.com>> wrote:

The dictionary says that the seventh item of dateitems is
the numeric day of the week where Monday is day 1, Tuesday is day 2, and so 
forth

When I try this I find that today, Wednesday, the seventh item is 4.  If I 
change the date to Sunday, it's 1.

(Both docs and behaviour are consistent with 6.7.11 or 8.1.3 (rc 1) or versions 
in between.)

Is this an error in the documentation, or an error in the code (in which case 
too long standing to change, so it might as well be treated as an error in the 
docs); or is it due to some setting somewhere?

TIA.

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


dateitems day-of-week disjunction

2017-01-25 Thread Ben Rubinstein via use-livecode

The dictionary says that the seventh item of dateitems is

 the numeric day of the week where Monday is day 1, Tuesday is day 2, and so 
forth


When I try this I find that today, Wednesday, the seventh item is 4.  If I 
change the date to Sunday, it's 1.


(Both docs and behaviour are consistent with 6.7.11 or 8.1.3 (rc 1) or 
versions in between.)


Is this an error in the documentation, or an error in the code (in which case 
too long standing to change, so it might as well be treated as an error in the 
docs); or is it due to some setting somewhere?


TIA.

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: Storing and object reference in a var

2017-01-25 Thread Bob Sneidar via use-livecode
I want to create a variable called tTargetField so I use

put "Hello" into tTargetField

Now I want to put something into a field so I create a variable called 
tTargetField2 and
put the long id of field "foo" into tTargetfield2

Then to put something into the field I
put "Hello" into tTargetField2

Now do you see? All I am doing here is replacing the value of tTargetField2 
that used to contain the long id of field "foo" with the word "Hello". How does 
the engine know what you mean? It's Ambiguous.

Bob S


On Jan 24, 2017, at 19:15 , dunbarx via use-livecode 
mailto:use-livecode@lists.runrev.com>> wrote:

I am not sure what you mean.

Both lines of code seem fine. What is not working?

Craig Newman

___
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: Delete element from array

2017-01-25 Thread Bob Sneidar via use-livecode
delete variable aArrayName ["Element"]

Bob S


> On Jan 24, 2017, at 18:54 , Sannyasin Brahmanathaswami via use-livecode 
>  wrote:
> 
> how do you remove a key from an array?
> 
> ___
> 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


New Educational Magazine

2017-01-25 Thread Richmond Mathewson via use-livecode

https://www.raspberrypi.org/helloworld

Richmond.
___
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: Storing and object reference in a var

2017-01-25 Thread dunbarx via use-livecode
Hmmm.

SetProps notwithstanding, one could;

on mouseUp
   put the name of fld 1 into hh
   set the abc of hh to "xyz"
end mouseUp

This will indeed create a custom property (abc) of field 1 and set it to
"xyz". In this case LC evaluates the variable "hh" as an object reference. I
would have thought that a "do" construction would have been required here,
but not so.

Craig



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Storing-and-object-reference-in-a-var-tp4711908p4711922.html
Sent from the Revolution - User mailing list archive at Nabble.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