Re: snapshot and animation capture

2016-01-29 Thread [-hh]
Hi,

I've made a stack for the Raspi collection, that does the following:

Creates a *resizable* rectangle frame (window shape of a non-opaque rectangle), 
currently set as systemWindow. You can drag that around the screen and trigger 
a small button on the frame. Then a screenshot of the visible interior of the 
frame is made and saved as PNG. You can open and view these 'shots' in the 
stack, if it is switched to non-window-shaped.

It's all "intermediate" Livecode, runs on Mac/Win/Linux and is fast enough on a 
Raspi. On Win/Linux resizing "flickers", you may play there with the 
'update-beat' (currently 4 ticks), but it works.

I didn't publish it until now, because "window-shaping" is currently/not yet 
possible in the available Raspi IDE's or standalones.

If this is (partly) what you want, then I'll post it (or a link to it) in a few 
hours in the sub-forum "Rich Media". Just tell me.


Hermann
___
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: Selecting text in single-line entry fields - small UI issue

2016-01-29 Thread Roland Huettmann
Sorry -  mistyped: I wanted to write: "Is it possible ?"

On 29 January 2016 at 11:45, Roland Huettmann 
wrote:

> Question: textcolor when text is selected
>
> It is possible to set the textcolor when the text is hilited? I could not
> find a way doing this.
>
> Roland
>
>
>
> On 29 January 2016 at 10:21, Roland Huettmann 
> wrote:
>
>> Paul, yes, autohilite does it. ) But nevertheless, to perform some
>> action, I need a trigger while tabbing.
>>
>> I am using LC 7.1, Windows 8.1
>>
>> The actual question was another one:
>>
>> The text is highlighted - yes - in both cases.
>>
>> But the single-line field rectangle is not, just the text itself.
>>
>> I would like to have the visual effect showing a fully highlighted field
>> (not the text itself) where the text is visible and selected - and ideally
>> the color showing is set apart more than just 1 pixel from the border of
>> the field boundaries.
>>
>> This simply looks better than a chunk of text being selected.
>>
>> This can somehow be done tabbing into the field and then setting the
>> backgroundcolor of field.
>>
>> But setting the backgroundcolor to the hilitecolor will make the text
>> chunk disappear.
>>
>> Example:
>>
>> // The text chunk only appears when tabbing out or deselecting it.
>> Setting the hilitecolor to empty does not make a difference. //
>>
>> on tabkey
>>set the hilitecolor of field "Test1" to blue
>>set the backgroundcolor of field "Test1" to the hilitecolor of field
>> "Test1"
>>select the text of field "Test1" // The text DISAPPEARS
>> end tabkey
>>
>> One way of achieving the desired effect is with a trick:
>>
>> Set the actual field to be transparent. Put a graphic or another control
>> (field..) behind. Selecting the text of the transparent field will change
>> the color of the control behind it and the visual effect will be as desired
>> if the hilitecolor is set to the same color as the backgroundcolor in the
>> control behind.
>>
>> But of course - this is not something I would like to do for all my
>> fields. )
>>
>> Roland
>>
>>
>>
>>
>>
>>
>>
>> On 28 January 2016 at 22:26, Paul Hibbert  wrote:
>>
>>> On Jan 28, 2016, at 4:07 AM, Roland Huettmann <
>>> roland.huettm...@gmail.com> wrote:
>>> >
>>> > Maybe I am missing something, but I need to script this with "on
>>> > tabkey"-event handlers, "on textchanged" handlers, " on deletekey"
>>> handlers
>>> > and go with "select the text of..." or "select line 1 of...".
>>> Otherwise the
>>> > cursor is always placed behind the text - and I do not want that
>>> except for
>>> > multi-line fields. Could there not be a built-in attribute how
>>> selection
>>> > should occur?
>>>
>>> Check the autoTab property in the inspector, or if you want to set it by
>>> script…
>>>
>>> set the autoTab of field “myField" to true
>>>
>>> I’m not seeing any issue with text changing colour when selected, but
>>> you didn’t say which version of Livecode or which platform you are seeing
>>> this on, this info may help track down the problem.
>>>
>>> Paul
>>> ___
>>> 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: LC Server Call Javascript Function?

2016-01-29 Thread Peter W A Wood
Scott

> On 29 Jan 2016, at 18:30, Scott Rossi  wrote:
> 
> Can a LiveCode server script call a Javascript function?
> 
> I want to write some text into a div in an LC server web page without
> refreshing the entire page.  AFAICT, generating any text from a LiveCode
> server script will replace the contents of page, but cannot target a a
> specific DOM element on the page.  Since Javascript can do this, is there
> any way to trigger a Javascript function from an LC server script?

It is easy enough to do, if the JavaScript calls the LC Server Script. I 
believe that pushing content from the server to the browser can be achieved 
using the HTML5 WebSocket API (which will be a lot more complicated).

Regards

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


Re: LC Server Call Javascript Function?

2016-01-29 Thread Peter TB Brett

On 2016-01-29 11:30, Scott Rossi wrote:

Can a LiveCode server script call a Javascript function?

I want to write some text into a div in an LC server web page without
refreshing the entire page.  AFAICT, generating any text from a 
LiveCode

server script will replace the contents of page, but cannot target a a
specific DOM element on the page.  Since Javascript can do this, is 
there

any way to trigger a Javascript function from an LC server script?


The normal way to do this would be to write some JavaScript that 
performs an XMLHttpRequest to the LiveCode server script, and then sets 
the innerHTML of the  element.


Don't forget that JavaScript runs on the client, and LiveCode runs on 
the server.  There are things you can do in a LiveCode server script 
that you can't in JavaScript, and vice versa.


  Peter

--
Dr Peter Brett 
LiveCode Open Source Team

LiveCode on reddit! 

___
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: Selecting text in single-line entry fields - small UI issue

2016-01-29 Thread Roland Huettmann
Question: textcolor when text is selected

It is possible to set the textcolor when the text is hilited? I could not
find a way doing this.

Roland



On 29 January 2016 at 10:21, Roland Huettmann 
wrote:

> Paul, yes, autohilite does it. ) But nevertheless, to perform some action,
> I need a trigger while tabbing.
>
> I am using LC 7.1, Windows 8.1
>
> The actual question was another one:
>
> The text is highlighted - yes - in both cases.
>
> But the single-line field rectangle is not, just the text itself.
>
> I would like to have the visual effect showing a fully highlighted field
> (not the text itself) where the text is visible and selected - and ideally
> the color showing is set apart more than just 1 pixel from the border of
> the field boundaries.
>
> This simply looks better than a chunk of text being selected.
>
> This can somehow be done tabbing into the field and then setting the
> backgroundcolor of field.
>
> But setting the backgroundcolor to the hilitecolor will make the text
> chunk disappear.
>
> Example:
>
> // The text chunk only appears when tabbing out or deselecting it. Setting
> the hilitecolor to empty does not make a difference. //
>
> on tabkey
>set the hilitecolor of field "Test1" to blue
>set the backgroundcolor of field "Test1" to the hilitecolor of field
> "Test1"
>select the text of field "Test1" // The text DISAPPEARS
> end tabkey
>
> One way of achieving the desired effect is with a trick:
>
> Set the actual field to be transparent. Put a graphic or another control
> (field..) behind. Selecting the text of the transparent field will change
> the color of the control behind it and the visual effect will be as desired
> if the hilitecolor is set to the same color as the backgroundcolor in the
> control behind.
>
> But of course - this is not something I would like to do for all my
> fields. )
>
> Roland
>
>
>
>
>
>
>
> On 28 January 2016 at 22:26, Paul Hibbert  wrote:
>
>> On Jan 28, 2016, at 4:07 AM, Roland Huettmann 
>> wrote:
>> >
>> > Maybe I am missing something, but I need to script this with "on
>> > tabkey"-event handlers, "on textchanged" handlers, " on deletekey"
>> handlers
>> > and go with "select the text of..." or "select line 1 of...". Otherwise
>> the
>> > cursor is always placed behind the text - and I do not want that except
>> for
>> > multi-line fields. Could there not be a built-in attribute how selection
>> > should occur?
>>
>> Check the autoTab property in the inspector, or if you want to set it by
>> script…
>>
>> set the autoTab of field “myField" to true
>>
>> I’m not seeing any issue with text changing colour when selected, but you
>> didn’t say which version of Livecode or which platform you are seeing this
>> on, this info may help track down the problem.
>>
>> Paul
>> ___
>> 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

Questions: Setting the borderWidth (lineSize) of a graphic through script

2016-01-29 Thread Roland Huettmann
Using LC 7.1 / Windows 8.1

I am trying to find a way of setting the borderwidth and bordercolor of a
newly created graphic through script. It does not work.

But it is possible using the Property Inspector.

The following instructions fail:

on mouseUp
   set the borderwidth of graphic "XY" to 10
   set the bordercolor of graphic "XY" to red
end mouseUp

Strangely enough, when I am asking for the these property values (put the
borderwidth of graphic "XY") then it is the set value and will be 10 in
this case. It renders visually with 1 or 2, and the Property Inspector
gives a value of 2.

But setting other properties such as background color etc. is working.

Maybe I am overlooking something?

Roland
___
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: Questions: Setting the borderWidth (lineSize) of a graphic through script

2016-01-29 Thread Roland Huettmann
Hello Scott

Borderwidth or linesize are synonyms according to the Dictionary, and I
tried all without success.

I want to script the borderwidth (linesize) and it's appearance. It is a
specific task drawing rectangles representing windows with frames where the
"frames" are my border lines.And those border line widths (frame widths)
are changing all the time.

What I do as a work-around is drawing a rectangle, setting it's properties
with the Property Inspector and then copying the properties to the newly
created rectangle. But this requires in advance defining such template
objects.

But should it not work just using script?

On 29 January 2016 at 12:30, Roland Huettmann  wrote:

> Hello Scott
>
> Borderwidth or linesize are synonyms according to the Dictionary, and I
> tried all without success.
>
> I want to script the borderwidth (linesize) and it's appearance. It is a
> specific task drawing rectangles representing windows with frames where the
> "frames" are my border lines.And those border line widths (frame widths)
> are changing all the time.
>
> What I do as a work-around is drawing a rectangle, setting it's properties
> with the Property Inspector and then copying the properties to the newly
> created rectangle. But this requires in advance defining such template
> objects.
>
> But should it not work just using script?
>
> Roland
>
>
>
> On 29 January 2016 at 12:18, Scott Rossi  wrote:
>
>> Do you really want to adjust the border property instead of the lineSize /
>> foreColor?
>>
>> set the lineSize of grc "XY" to 10
>> set the foreColor of grc "XY" to "red"
>>
>> Regards,
>>
>> Scott Rossi
>> Creative Director
>> Tactile Media, UX/UI Design
>>
>>
>>
>>
>> On 1/29/16, 3:01 AM, "use-livecode on behalf of Roland Huettmann"
>> > roland.huettm...@gmail.com> wrote:
>>
>> >Using LC 7.1 / Windows 8.1
>> >
>> >I am trying to find a way of setting the borderwidth and bordercolor of a
>> >newly created graphic through script. It does not work.
>> >
>> >But it is possible using the Property Inspector.
>> >
>> >The following instructions fail:
>> >
>> >on mouseUp
>> >   set the borderwidth of graphic "XY" to 10
>> >   set the bordercolor of graphic "XY" to red
>> >end mouseUp
>> >
>> >Strangely enough, when I am asking for the these property values (put the
>> >borderwidth of graphic "XY") then it is the set value and will be 10 in
>> >this case. It renders visually with 1 or 2, and the Property Inspector
>> >gives a value of 2.
>> >
>> >But setting other properties such as background color etc. is working.
>> >
>> >Maybe I am overlooking something?
>> >
>> >Roland
>> >___
>> >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: Questions: Setting the borderWidth (lineSize) of a graphic through script

2016-01-29 Thread Scott Rossi
Do you really want to adjust the border property instead of the lineSize /
foreColor?

set the lineSize of grc "XY" to 10
set the foreColor of grc "XY" to "red"

Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design




On 1/29/16, 3:01 AM, "use-livecode on behalf of Roland Huettmann"
 wrote:

>Using LC 7.1 / Windows 8.1
>
>I am trying to find a way of setting the borderwidth and bordercolor of a
>newly created graphic through script. It does not work.
>
>But it is possible using the Property Inspector.
>
>The following instructions fail:
>
>on mouseUp
>   set the borderwidth of graphic "XY" to 10
>   set the bordercolor of graphic "XY" to red
>end mouseUp
>
>Strangely enough, when I am asking for the these property values (put the
>borderwidth of graphic "XY") then it is the set value and will be 10 in
>this case. It renders visually with 1 or 2, and the Property Inspector
>gives a value of 2.
>
>But setting other properties such as background color etc. is working.
>
>Maybe I am overlooking something?
>
>Roland
>___
>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


[OT] Blowing up your Mac laptops

2016-01-29 Thread Richmond

Please could anybody who has a Macintosh laptop read this:

http://www.bbc.com/news/technology-35432682

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


LC Server Call Javascript Function?

2016-01-29 Thread Scott Rossi
Can a LiveCode server script call a Javascript function?

I want to write some text into a div in an LC server web page without
refreshing the entire page.  AFAICT, generating any text from a LiveCode
server script will replace the contents of page, but cannot target a a
specific DOM element on the page.  Since Javascript can do this, is there
any way to trigger a Javascript function from an LC server script?

Thanks for any ideas.

Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design




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


Re: Explicit Variables

2016-01-29 Thread [-hh]
What about the following?

on mouseUp
  do "local tvar=1.2"
  put 2*tvar
end mouseUp

Should NOT work. But this should work (as do recompiles?):

on mouseUp
  do "local tvar=1.2"
  do "put 2*tvar"
end mouseUp


___
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: Selecting text in single-line entry fields - small UI issue

2016-01-29 Thread Roland Huettmann
Paul, yes, autohilite does it. ) But nevertheless, to perform some action,
I need a trigger while tabbing.

I am using LC 7.1, Windows 8.1

The actual question was another one:

The text is highlighted - yes - in both cases.

But the single-line field rectangle is not, just the text itself.

I would like to have the visual effect showing a fully highlighted field
(not the text itself) where the text is visible and selected - and ideally
the color showing is set apart more than just 1 pixel from the border of
the field boundaries.

This simply looks better than a chunk of text being selected.

This can somehow be done tabbing into the field and then setting the
backgroundcolor of field.

But setting the backgroundcolor to the hilitecolor will make the text chunk
disappear.

Example:

// The text chunk only appears when tabbing out or deselecting it. Setting
the hilitecolor to empty does not make a difference. //

on tabkey
   set the hilitecolor of field "Test1" to blue
   set the backgroundcolor of field "Test1" to the hilitecolor of field
"Test1"
   select the text of field "Test1" // The text DISAPPEARS
end tabkey

One way of achieving the desired effect is with a trick:

Set the actual field to be transparent. Put a graphic or another control
(field..) behind. Selecting the text of the transparent field will change
the color of the control behind it and the visual effect will be as desired
if the hilitecolor is set to the same color as the backgroundcolor in the
control behind.

But of course - this is not something I would like to do for all my fields.
)

Roland







On 28 January 2016 at 22:26, Paul Hibbert  wrote:

> On Jan 28, 2016, at 4:07 AM, Roland Huettmann 
> wrote:
> >
> > Maybe I am missing something, but I need to script this with "on
> > tabkey"-event handlers, "on textchanged" handlers, " on deletekey"
> handlers
> > and go with "select the text of..." or "select line 1 of...". Otherwise
> the
> > cursor is always placed behind the text - and I do not want that except
> for
> > multi-line fields. Could there not be a built-in attribute how selection
> > should occur?
>
> Check the autoTab property in the inspector, or if you want to set it by
> script…
>
> set the autoTab of field “myField" to true
>
> I’m not seeing any issue with text changing colour when selected, but you
> didn’t say which version of Livecode or which platform you are seeing this
> on, this info may help track down the problem.
>
> Paul
> ___
> 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: Selecting text in single-line entry fields - small UI issue

2016-01-29 Thread J. Landman Gay
The focusborder property will outline the currently active field with a color. 
If you use that, you won't have to set the field's backcolor. 

If you do want to script the behavior, you can use either the openfield or 
focusIn message as the trigger. When focus is lost, a focusOut message is sent 
as well as either closefield or exitfield, which you can use to reset the field 
appearance. 

I've had to work around the disappearing selection text on Windows before (it 
doesn't happen on Mac) and found that for black text, the best background color 
is a pale shade. I think I used a very light yellow. 

On January 29, 2016 3:21:29 AM CST, Roland Huettmann 
 wrote:
>Paul, yes, autohilite does it. ) But nevertheless, to perform some
>action,
>I need a trigger while tabbing.
>
>I am using LC 7.1, Windows 8.1
>
>The actual question was another one:
>
>The text is highlighted - yes - in both cases.
>
>But the single-line field rectangle is not, just the text itself.
>
>I would like to have the visual effect showing a fully highlighted
>field
>(not the text itself) where the text is visible and selected - and
>ideally
>the color showing is set apart more than just 1 pixel from the border
>of
>the field boundaries.
>
>This simply looks better than a chunk of text being selected.
>
>This can somehow be done tabbing into the field and then setting the
>backgroundcolor of field.
>
>But setting the backgroundcolor to the hilitecolor will make the text
>chunk
>disappear.
>
>Example:
>
>// The text chunk only appears when tabbing out or deselecting it.
>Setting
>the hilitecolor to empty does not make a difference. //
>
>on tabkey
>   set the hilitecolor of field "Test1" to blue
>   set the backgroundcolor of field "Test1" to the hilitecolor of field
>"Test1"
>   select the text of field "Test1" // The text DISAPPEARS
>end tabkey
>
>One way of achieving the desired effect is with a trick:
>
>Set the actual field to be transparent. Put a graphic or another
>control
>(field..) behind. Selecting the text of the transparent field will
>change
>the color of the control behind it and the visual effect will be as
>desired
>if the hilitecolor is set to the same color as the backgroundcolor in
>the
>control behind.
>
>But of course - this is not something I would like to do for all my
>fields.
>)
>
>Roland
>
>
>
>
>
>
>
>On 28 January 2016 at 22:26, Paul Hibbert  wrote:
>
>> On Jan 28, 2016, at 4:07 AM, Roland Huettmann
>
>> wrote:
>> >
>> > Maybe I am missing something, but I need to script this with "on
>> > tabkey"-event handlers, "on textchanged" handlers, " on deletekey"
>> handlers
>> > and go with "select the text of..." or "select line 1 of...".
>Otherwise
>> the
>> > cursor is always placed behind the text - and I do not want that
>except
>> for
>> > multi-line fields. Could there not be a built-in attribute how
>selection
>> > should occur?
>>
>> Check the autoTab property in the inspector, or if you want to set it
>by
>> script…
>>
>> set the autoTab of field “myField" to true
>>
>> I’m not seeing any issue with text changing colour when selected, but
>you
>> didn’t say which version of Livecode or which platform you are seeing
>this
>> on, this info may help track down the problem.
>>
>> Paul
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>___
>use-livecode mailing list
>use-livecode@lists.runrev.com
>Please visit this url to subscribe, unsubscribe and manage your
>subscription preferences:
>http://lists.runrev.com/mailman/listinfo/use-livecode

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

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

Re: Questions: Setting the borderWidth (lineSize) of a graphic through script

2016-01-29 Thread Roland Huettmann
Mark is right,

I tested again and it is obviously a documentation error.

Tested on Windows 8.1, LC 7.1 and LC 8.0 dp 13:

ShowBorder was set to true in all cases.
ThreeD must be set to false in the case of buttons, etc.

LineSize: Works exclusively on graphics, NOT on other objects

BorderWidth works on objects such as fields, buttons, etc. but NOT on
graphics.

According to Dictionary borderwWdth and lineSize are synonyms and even an
example is given which does not work.

I will file a little documentation error report.

Roland



On 29 January 2016 at 16:32, Mark Waddingham  wrote:

> On 2016-01-29 16:05, BNig wrote:
>
>> I tried "set the borderwidth of grc "x" to y" on MacOSX 10.9.5 in LC 7.1
>> and
>> 8 DP13 and it did not work. However "set the lineSize of grc "x" to y" did
>> work.
>>
>
> The borderWidth property specifies the width of the border around the
> control - whether this is visible or not depends on the value of the
> showBorder property.
>
> The lineSize property is distinct and is specific to graphic objects - it
> sets the stroke width used to render the graphic's shape.
>
> Warmest Regards,
>
> Mark.
>
> --
> Mark Waddingham ~ m...@livecode.com ~ http://www.livecode.com/
> LiveCode: Everyone can create apps
>
>
> ___
> 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: Questions: Setting the borderWidth (lineSize) of a graphic through script

2016-01-29 Thread BNig
Hello Roland,


RH wrote
> Borderwidth or linesize are synonyms according to the Dictionary, and I
> tried all without success.
> .
> But should it not work just using script?

I tried "set the borderwidth of grc "x" to y" on MacOSX 10.9.5 in LC 7.1 and
8 DP13 and it did not work. However "set the lineSize of grc "x" to y" did
work.

According to the dictionary borderwidth should work, either a documentation
error or a bug.

Maybe someone could test this on Windows 8.1.

Kind regards
Bernd



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Questions-Setting-the-borderWidth-lineSize-of-a-graphic-through-script-tp4700532p4700538.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: Questions: Setting the borderWidth (lineSize) of a graphic through script

2016-01-29 Thread Mark Waddingham

On 2016-01-29 16:05, BNig wrote:
I tried "set the borderwidth of grc "x" to y" on MacOSX 10.9.5 in LC 
7.1 and
8 DP13 and it did not work. However "set the lineSize of grc "x" to y" 
did

work.


The borderWidth property specifies the width of the border around the 
control - whether this is visible or not depends on the value of the 
showBorder property.


The lineSize property is distinct and is specific to graphic objects - 
it sets the stroke width used to render the graphic's shape.


Warmest Regards,

Mark.

--
Mark Waddingham ~ m...@livecode.com ~ http://www.livecode.com/
LiveCode: Everyone can create apps

___
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: Selecting text in single-line entry fields - small UI issue

2016-01-29 Thread Roland Huettmann
Hello J. Thank you. Helpful. Especially the triggers mentioned.

Unfortunately the focusborder property does not work in WIndows. In the
Dictionary Window 92 is mentioned (uh...?) but it also does not work in 8.1
(and I guess in Windows 10). Of course I can set the borderwidth and
bordercolor when entering the field and when exiting it.

WINDOWS:

It seems that this problem loosing the selection (I had this before in
older versions) is gone. Or at least, currently I do not have this any
longer. That is already very fortunate! (I remember that this was the
reason why I worked with the tabkey solution to keep the focus on the field
not loosing the selection. I was wondering why I did it.Yes, it was this
problem loosing the selection before.

I love the way some fields in other programs are selecting the text. Look
at FileMaker. Setting the field property selecting the field content means
that the whole field is showing a selection, not just the text. Such
examples make it clear, not my many words ).

Here is my test button to try to indicate the selection changing the
backgroundcolor:

on mouseUp
   if the shiftkey is down then
  set the texthilite of field test3 to white
  set the backgroundcolor of field test3 to black
  select the text of field test3 // NOTHING IS SHOWN but the text is
there
   else
  set the texthilite of field test3 to black
  set the backgroundcolor of field test3 to white
  select the text of field test3 // NOTHING IS SHOWN but the text is
there
   end if
end mouseUp

In both cases, it does not work. The text disappears ! So, it also
disappears when tabbing into the field. Only selecting the text manually it
will show, and reverse the selection color.

All I am trying to explain is that the current way of text selection is not
looking as nice as the field selection in other programs. And I would like
to work on such level of detail. It is not critical to have it. I agree.

So far this effect seems only possible using a transparent field on top of
another control, and this control behind shows the selection in the same
color as the text selection so that the visual effect is as I want it. It
can even be made small enough so that the visual effect will be associated
with the actual text and the whole width of the selected field. But it is
neither perfect, nor desirable to use such work-around everywhere as even a
transparent or empty selectioncolor shows off and looks disturbing or just
not quite right. And it is not really the text selection itself (which is
hidden here using the same selectioncolor as the control behind but still
not completely unnoticed).

I assume now that what I am trying to achieve is currently not possible. I
hope that it will be possible to do on such level of detail using widgets.
I did not explored these new possibilities yet. And I need more guidance to
learn LCB. )))

Roland
___
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: Questions: Setting the borderWidth (lineSize) of a graphic through script

2016-01-29 Thread Mark Waddingham

On 2016-01-29 17:33, Roland Huettmann wrote:

ShowBorder was set to true in all cases.
ThreeD must be set to false in the case of buttons, etc.

LineSize: Works exclusively on graphics, NOT on other objects

BorderWidth works on objects such as fields, buttons, etc. but NOT on
graphics.

According to Dictionary borderwWdth and lineSize are synonyms and even 
an

example is given which does not work.


Well, this is a little tricky.

For all non-graphic objects, penWidth, penHeight, lineSize and 
borderWidth are all synonyms.


For graphic objects, penWidth, penHeight and lineSize are synonyms, 
borderWidth is the same as borderWidth on non-graphic objects.


(Basically the graphic object 'overrides' the lineSize, penWidth and 
penHeight properties mapping them all to the strokeWidth).


I'm not entirely sure the best way to document this relationship as 
these keywords aren't exactly synonyms, as what they are synonymous with 
depends on the object type!


BorderWidth works fine on graphics here - you set the showBorder to 
true, and set the borderWidth. You'll get the original shape inset by 
the borderWidth with the border drawn around it.


Warmest Regards,

Mark.

--
Mark Waddingham ~ m...@livecode.com ~ http://www.livecode.com/
LiveCode: Everyone can create apps

___
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: snapshot and animation capture

2016-01-29 Thread Richmond

On 28/01/16 13:22, Richmond wrote:

On 28/01/16 00:27, Scott Rossi wrote:

I thought this might make an interesting read, so the demo stack is
included in an article:



Hope this works for you.


Well, I'll certainly see: I'll see if it can grab a few images from my 
USB microscope connected
to a computer running Xubuntu - at least it will be a happy 
alternative from endless Grammar

exercises for the kids I'm teaching this afternoon!

Expect a report later today.

Richmond.


I must be slightly stupid because, although I could see a resizable 
rectangle I could not

for the life of me work out how to trigger the actual snapshot.

Richmond.




Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design




On 1/27/16, 11:55 AM, "use-livecode on behalf of Scott Rossi"
 wrote:


Hi Matt:

I have a method for a resizable masked window that requires LC7 -- I'll
try to post something later today or tomorrow.  As far as image 
animation

goes, I have a very vague memory that LC used to be able to export
animated GIF images, but that may have been static images only.  You 
may
indeed need to go with a 3rd party option -- hopefully somebody else 
has a

suggestion for this.

Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design




On 1/27/16, 11:38 AM, "use-livecode on behalf of Matt Maier"


wrote:


I need to be able to easily capture stuff the user is seeing on their
screen so that they can import it into my application without 
having to

navigate the file manager multiple times. There's some good screen
capture
stuff already in Livecode, but what I'm picturing is an actual window
with
a hole in it the user can position and leave there so they know what's
going to be captured multiple times. Like gifcam
http://blog.bahraniapps.com/gifcam/

There doesn't seem to be a way to set the background of a window to
transparent. There is a way to mask the window using a transparent 
.png,

but that won't allow the user to resize the window. At the moment the
only
mechanism I can come up with is to screencap what's behind the window
every
time the user moves or resizes it and display that in the window so 
that

it
looks like it's transparent. Is there a better way?

Also, in addition to capturing still images, I'd like the user to 
be able

to capture animated images (as an alternative to video). So, that part
would be exactly like gifcam. The only mechanism I've found for 
that is

to
export each frame and then use something external like imagemagik to
stitch
them together into an animation.

- Matt



___
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


Ken Burn's Effect Library for Livecode

2016-01-29 Thread Sannyasin Brahmanathaswami
Before I launch into this from ground zero.. has anyone developed a library for 
Ken Burns effects for still imagery in LiveCode?

Scott sent me a cool thing for zooming in and out… so then we just need to move 
the image along a path at the same time.

typical use case is the subtle and slow easing in of a photo or image as it 
enlarges or shrinks, normally this is done slowly enough so as not to be too 
jarring, with some narration. Entire feature length documentaries have been 
done with just moving stills and voice over.  I want to develop a set of 
generic tools and plan to use AnimationEngine to help… but  if there anyone has 
this already built, can you share?

e.g. Photograph fills the card window.. then slowly moves down to the left as 
we zoom in on some element in the upper right area of the photo.  Simple enough.

The toolbox would “log” a few actions just like you do in most video editors…

something like

1) snap current loc of image (store value)
2) Adjust photo to new zoom level an location
3) snap final location (store value)
4) prompt for time to move

Save as an array with something like

tween-image_temple-under-tree[“start”]
tween-image_temple-under-tree[“end”]
tween-image_temple-under-tree[“time”]

then you have a generic function

on runKenBurns tween-image_temple-under-tree

# run code here - that’s the art I’m going to build in the next day or so… 
unless someone has it already written

end runKenBurns



BR


___
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: Global Warming Reader App, Recruiting Collaborators

2016-01-29 Thread William Prothero
Jim:
A pertinent topic. I’m a bit unsure of what the goal of the app is, though. It 
seems to be an index of web sites related to global warming. I could see a use 
for something that organizes and educates. Would this be like an expanded 
version of RealClimate.com? So, I’m wondering what the goal of the app is and 
how it might educate folks more than the available info already available on 
the web?

Best,
Bill

William Prothero, Ph.D.
University of California, Santa Barbara, Emeritus
proth...@earthednet.org



> On Jan 29, 2016, at 1:52 PM, James Little  wrote:
> 
> 
> Hi Livecoders,
> 
> The U.N. COP21 Conference in Paris this past December secured a remarkable 
> international agreement of over 190 nations to cut carbon emissions and to 
> limit global warming to less than 2 deg C.  But now the hard part begins, to 
> ensure that individuals, corporations and nations limit carbon emissions and 
> transition to clean energy.  This requires mass education, dialogue and 
> political action.  It requires correcting misinformation.  My hope is that 
> Livecode programmers can play a role is assisting with this challenging 
> global transition. 
> I’ve posted a project on MIT Climate CoLab to develop a Global Warming Reader 
> App using Livecode.  I invite all to register and add comments.  We have 30 
> days to finalize this project.
> 
> http://climatecolab.org/web/guest/plans/-/plans/contestId/1303501/phaseId/1313706/planId/1327125
> 
> I’ve posted a beta Global Warming Reader App at  
> GlobalWarmingApps.org/downloads.html  with downloads for Mac & Windows 
> desktop.  The Mac download mostly works by my testing, though there are still 
> some bugs.  I’ve not been able to test the Windows version, as yet.  Please 
> let me know of any bugs you find.  
> 
> My son Todd says the user interface is old school.  I’m beginning to use the 
> push button and tree view widgets to try to modernize the UI.  
> 
> If you would like to improve on this app, please email me 
> (j...@globalwarmingapps.org) and I will send you a link to download the 
> livecode file.  It is being developed using 8.0 DP12.  
> 
> The basic idea of the MIT Climate CoLab project is to develop the best 
> possible Global Warming Reader App over the next 6 months.  Please consider 
> improving on the app that I’ve started or starting anew and developing an app 
> from scratch. 
> 
> Regards,
> 
> Jim L
> 
> 
> 
> ___
> 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


Import Vector to Graphic object

2016-01-29 Thread Sannyasin Brahmanathaswami
if we want to use Animation Engine’s Morph or morphGradient, we have to target 
a grc object. I presume because AE can extract points from a graphic object. 
But if we want to use this on a PNG… it’s obviously won’t work.

What image format can we use that, upon import, becomes a native LC graphic?

The import options in the dictionary include gif jpg png amp pwd rpm ppm ppm 
and eps

I am unable to import my eps logos. the files I have are reporting anderror on 
import

BR

___
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

Global Warming Reader App, Recruiting Collaborators

2016-01-29 Thread James Little

Hi Livecoders,

The U.N. COP21 Conference in Paris this past December secured a remarkable 
international agreement of over 190 nations to cut carbon emissions and to 
limit global warming to less than 2 deg C.  But now the hard part begins, to 
ensure that individuals, corporations and nations limit carbon emissions and 
transition to clean energy.  This requires mass education, dialogue and 
political action.  It requires correcting misinformation.  My hope is that 
Livecode programmers can play a role is assisting with this challenging global 
transition. 
I’ve posted a project on MIT Climate CoLab to develop a Global Warming Reader 
App using Livecode.  I invite all to register and add comments.  We have 30 
days to finalize this project.

http://climatecolab.org/web/guest/plans/-/plans/contestId/1303501/phaseId/1313706/planId/1327125

I’ve posted a beta Global Warming Reader App at  
GlobalWarmingApps.org/downloads.html  with downloads for Mac & Windows desktop. 
 The Mac download mostly works by my testing, though there are still some bugs. 
 I’ve not been able to test the Windows version, as yet.  Please let me know of 
any bugs you find.  

My son Todd says the user interface is old school.  I’m beginning to use the 
push button and tree view widgets to try to modernize the UI.  

If you would like to improve on this app, please email me 
(j...@globalwarmingapps.org) and I will send you a link to download the 
livecode file.  It is being developed using 8.0 DP12.  

The basic idea of the MIT Climate CoLab project is to develop the best possible 
Global Warming Reader App over the next 6 months.  Please consider improving on 
the app that I’ve started or starting anew and developing an app from scratch. 

Regards,

Jim L



___
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: Free Let's Encrypt SSL Certificates for On-Rev?

2016-01-29 Thread Simon Smith
You can also look at using cloudflare.com for adding https - no need to buy
a security certficate.

On Thu, Jan 28, 2016 at 7:04 AM, Alex Shaw  wrote:

> Opps, my bad.
>
> That requires ssh access too.
>
> regards
> alex
>
>
> On 28/01/2016 2:58 PM, Alex Shaw wrote:
>
>> Yes, the official LE client requires shell access plus a range of python
>> dependences.
>>
>> Also, if the SSL/TLS Manager module was accessible from on-rev cpanel you
>> could try..
>>
>> https://github.com/diafygi/gethttpsforfree
>>
>> regards
>> alex
>>
>> On 28/01/2016 2:34 PM, Mark Wieder wrote:
>>
>>> On 01/27/2016 07:23 PM, Alex Shaw wrote:
>>>
 As far as I can tell Let's Encrypt issues certificates for domain names.

 The LE install client script asks for domain name/s and I found a
 mention here regarding that..

 https://community.letsencrypt.org/t/certificate-for-static-ip/84

>>>
>>> That's true, but when I tried it for my on-rev domain I got rejected
>>> because I don't have privileges for the on-rev server. Or that's how I
>>> interpreted the error message, at any rate. I'd be happy to be wrong.
>>>
>>>
>>
>> ___
>> 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
>



-- 

Carpe diem

*Simon Smith*
m. +27 83 306 7862
___
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: Import Vector to Graphic object

2016-01-29 Thread J. Landman Gay

On 1/29/2016 4:10 PM, Sannyasin Brahmanathaswami wrote:

if we want to use Animation Engine’s Morph or morphGradient, we have
to target a grc object. I presume because AE can extract points from
a graphic object. But if we want to use this on a PNG… it’s obviously
won’t work.

What image format can we use that, upon import, becomes a native LC
graphic?


Can you use an opaque graphic and set its backgroundPattern to the image ID?

--
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: snapshot and animation capture

2016-01-29 Thread [-hh]
Richmond,

"import" of the error message relates to the rect (see the wording in the 
dictionary), so char 1 means the superfluous quote (as Dame jacque says).

Whatever you test here, you could use 'from rect  of this card' or 'from 
rect of img "border.png"' if you wish to have a local coords shot of 
'border.png', else you'll get a *global* coords shot (from the tools window or 
whatever).

Thanks again for your "throwing a spanner in the works" (I like your unusual 
phrasing and wording), indeed you did exactly the opposite.

hh
___
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: Global Warming Reader App, Recruiting Collaborators

2016-01-29 Thread James Little

Hi Bill,

Thanks for your input.

The current Global Warming Reader App consists of 2 lists of websites, 
organized by category (Activism, Communication, Denial, Economics, Global, 
Individual, National, News, Oceans, Solutions, Science, …).  One list includes 
“All" the sites that I’ve found that I thought were useful.  The second list is 
a selected list of what I thought were the “Best” sites.  They can be launched 
in the user’s browser or in a widget browser within the app.  

The other component is a list of notes, organized by topic (Advocacy, 
BlogComments, Communication, Economics, Justice, Politics, Science, Solutions … 
).

The user can add or delete from either list of websites and can add or delete 
notes.  Thus, they can customize the app to their locale and their particular 
interests.  The website lists and notes are stored as arrays in custom 
properties of card 1 of the substack.

I find this reader particularly useful for keeping up on news about global 
warming and for taking personal notes. I find it useful for writing comments 
about an on-line article and writing letters to editors.  I try to look at the 
website under the category “News” of the “Best” list everyday and take notes 
from anything that looks particularly worthy.  Once per week I try to look at 
all the websites in the “Best” list.  Below are the websites under “News” in 
the “Best” list that I check daily:

CascadiaClimatection.org  … a calendar of climate change activism in the 
Seattle area   

CommonDreams.org/climate/ … a news site with commentary by many well-known 
activists

DailyClimate.org … a fairly complete news site, including editorials and op-eds 
from major newspapers 

Sightline.org/news/ … a news site for climate activism in the Pacific NW 

SkepticalScience.com … a more technical climate science focused news site

TheGuardian.com/environment/ … environmental news with a UK focus  

So, this is a news reader app to keep up with the latest on global warming.  
Perhaps it’s a useful initial tool to develop in Livecode.  It needs 
improvement.  It still has bugs.  The user interface can be improved.  Perhaps 
there should be a way to share urls or notes between users via a server.  
Perhaps there are other features that we can consider.  Perhaps others would 
like to start anew to develop a global warming new reader.  I would like to 
support these efforts in whatever way I can, either by taking the lead or by 
assisting.  I want to support any and all tools that we can develop in Livecode 
to address the challenges of climate change.  

Is it useful to list it as a project on the MIT Climate CoLab site under the 
Public Attitudes and Behaviors Workspace?  My hope is that this will make it 
more publicly known and perhaps draw in some outsiders to Livecode.  The more 
up votes that we get on the MIT Climate CoLab site, the more attention we will 
receive. I believe folks need to register and sign in to vote.   

Regards, 

Jim 


On Jan 29, 2016, at 4:47 PM, William Prothero  wrote:

> Jim:
> A pertinent topic. I’m a bit unsure of what the goal of the app is, though. 
> It seems to be an index of web sites related to global warming. I could see a 
> use for something that organizes and educates. Would this be like an expanded 
> version of RealClimate.com? So, I’m wondering what the goal of the app is and 
> how it might educate folks more than the available info already available on 
> the web?
> 
> Best,
> Bill
> 
> William Prothero, Ph.D.
> University of California, Santa Barbara, Emeritus
> proth...@earthednet.org
> 
> 
> 
>> On Jan 29, 2016, at 1:52 PM, James Little  wrote:
>> 
>> 
>> Hi Livecoders,
>> 
>> The U.N. COP21 Conference in Paris this past December secured a remarkable 
>> international agreement of over 190 nations to cut carbon emissions and to 
>> limit global warming to less than 2 deg C.  But now the hard part begins, to 
>> ensure that individuals, corporations and nations limit carbon emissions and 
>> transition to clean energy.  This requires mass education, dialogue and 
>> political action.  It requires correcting misinformation.  My hope is that 
>> Livecode programmers can play a role is assisting with this challenging 
>> global transition. 
>> I’ve posted a project on MIT Climate CoLab to develop a Global Warming 
>> Reader App using Livecode.  I invite all to register and add comments.  We 
>> have 30 days to finalize this project.
>> 
>> http://climatecolab.org/web/guest/plans/-/plans/contestId/1303501/phaseId/1313706/planId/1327125
>> 
>> I’ve posted a beta Global Warming Reader App at  
>> GlobalWarmingApps.org/downloads.html  with downloads for Mac & Windows 
>> desktop.  The Mac download mostly works by my testing, though there are 
>> still some bugs.  I’ve not been able to test the Windows version, as yet.  
>> Please let me know of any bugs you find.  
>> 
>> My son Todd says the user interface is old 

Re: Explicit Variables

2016-01-29 Thread Kay C Lan
On Sat, Jan 30, 2016 at 2:52 AM, Mark Waddingham  wrote:

>
>> Heh - no - I misread Kay's post... Whenever I see 'explicitVariables'
> mentioned I tend to think of 'Strict Compilation Mode'.
>

But you read my mind. I also see one and think the other. Thanks all for
responses, they're perfect for the intended purpose.
___
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: inserting Data into CustomProp array

2016-01-29 Thread Mark Wieder

On 01/29/2016 09:15 PM, Sannyasin Brahmanathaswami wrote:


OK… I’m good to good, but any advice in this area is appreciated.


That will do the trick.
An alternate way of retrieving the data is

set the custompropertyset of image  to "uMyEffects"
put the startsize of image 
set the custompropertyset of image  to empty

...and of course the same could be done for setting the custom property 
array.


--
 Mark Wieder
 ahsoftw...@gmail.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: inserting Data into CustomProp array

2016-01-29 Thread J. Landman Gay

On 1/29/2016 11:15 PM, Sannyasin Brahmanathaswami wrote:

apparently this:


on mouseUp

put the rect of the last image into tRect

set the uMyEffects["startsize"] of the last image to tRect

CheckEffects

end mouseUp


created a custompropertyset


If you want the array in a single custom property rather than in its own 
property set, first create the array and then store it:


  put the rect of the last image into tArray["startsize"]
  set the uEffects of the last image to tArray

To get things back out:

  put the uEffects of this cd into tArray
  put tArray["startsize"]

Property sets work too, so it's mostly a matter of personal preference.

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


inserting Data into CustomProp array

2016-01-29 Thread Sannyasin Brahmanathaswami
What is the best practice for progressively adding data to a customProperty 
that you want to be an array?  both inserting new keys into that property as 
well as changing values in the existing keys.

In this case i want an image(s) in a stack to have a custom property containing 
the necessary info for Animation Engine to do some effects. This seems like a 
good way to store this vs saving it anywhere else.

1) create image
2) add new custom property “uMyEffects”

on a button I have this:


on mouseUp

   put the rect of the last image into tRect

   set the uMyEffects["startsize"] of the last image to tRect

   CheckEffects



end mouseUp


command CheckEffects

   put the uMyEffects of the last image into tEffects

   put the keys of tEffects

end CheckEffects


result is nothing…I’m expecting to see the key


startsize


 so I’m not doing the right thing to insert a new key + data into the 
customProperty… Note that I would also want to later poke another value into 
the some custom property like


uMyEffects[“finalLoc”]



BR
___
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: inserting Data into CustomProp array

2016-01-29 Thread Sannyasin Brahmanathaswami
Hhmm serendipity happens

I was reading through all the dict entries on customproperties and custom 
property sets… a bit esoteric at first.

There was no explicity guide “how to create a custompropertyset”

But when I went back to my image and check… apparently this:


on mouseUp

   put the rect of the last image into tRect

   set the uMyEffects["startsize"] of the last image to tRect

   CheckEffects



end mouseUp


created a custompropertyset


and this extracts it


command CheckEffects

   put the customProperties["uMyEffects"] of the last image into tEffects

   put the keys of tEffects

end CheckEffects


OK… I’m good to good, but any advice in this area is appreciated.



http://www.himalayanacademy.com/apps/gurudeva


On January 29, 2016 at 7:01:14 PM, Sannyasin Brahmanathaswami 
(bra...@hindu.org) wrote:

What is the best practice for progressively adding data to a customProperty 
that you want to be an array?  both inserting new keys into that property as 
well as changing values in the existing keys.

In this case i want an image(s) in a stack to have a custom property containing 
the necessary info for Animation Engine to do some effects. This seems like a 
good way to store this vs saving it anywhere else.
___
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: FlockOBoids

2016-01-29 Thread Roger Guay
Building on Scott Rossi’s Swarm stack, I’ve managed to build my version of 
swarming Boids. In my FlockOBoids stack, boids are given a diverse set of 
initial velocity vectors, and then they are subject to 3 simple rules: First 
they all try to fly to the center of the flock. Second, they try to buddyup if 
they get close enough to each other, and third, they avoid colliding with other 
boids.

You can see and play with this here:


https://www.dropbox.com/s/c93ocic5mwaafuy/FlockOBoids.livecode?dl=0



Thanks for the idea, Scott.


Cheers,

Roger
___
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: snapshot and animation capture

2016-01-29 Thread J. Landman Gay

On 1/29/2016 1:35 PM, Richmond wrote:

So, I thought I'd have a bash at rolling my own, but got stuck:

on mouseUp
put topleft of img "border.png" & "," & the bottomright of img
"border.png" into 
put quote &  & quote into fld "guff"
put fld "guff" into 
export snapshot from rect  of stack "Super Snap" to file
".png" as PNG
end mouseUp

the thing gets stuck on the "export snapshot" line . . . cannot think
why . . .

image "snapBTN.png": execution error at line 5 (import: error in
expression), char 1

that stuff about "char 1" makes NO sense at all.


I think in general it means the line won't compile at all, there's no 
specific place it errors.


By adding quotes to the variable, you are specifying a string rather 
than a rect. Omit the quotes from the field.


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


Something's up in Github...

2016-01-29 Thread Richard Gaskin

Check out the recent pull requests for LC:
https://github.com/livecode/livecode/pulse

Lots of appearance-related stuff -- yoohoo!

Very nice to see those addressed, and so many of them!

Great work, team!

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

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


Re: Selecting text in single-line entry fields - small UI issue

2016-01-29 Thread Paul Hibbert
Roland,

The best I can come up with is using the openField and closeField messages to 
set the colour of the line within the field, instead of setting the background 
colour of the field, this gives you a little more control over the position of 
the ‘highlighted' area. Something like this in a behaviour button then applied 
to the required fields:

on openField
   set the hilitecolor of me to Blue
   set the backgroundcolor of line 1 of me to the hilitecolor of me
   set the padding of line 1 of me to 4
   set the textColor of me to "255,255,255"
   select the text of me
end openField

on exitField
   set the backgroundcolor of line 1 of me to "255,255,255"
   set the textColor of me to "0,0,0"
end exitField

Sorry I can’t test for the disappearing text because I’m on Mac.

As Jacque suggested, I also expected the focusIn and focusOut messages would be 
helpful, but it seems they are not triggered buy opening or closing an unlocked 
field (see comment in the dictionary).

This lesson explains a little more so maybe helpful:
http://lessons.livecode.com/m/4071/l/58674-how-do-i-style-paragraphs-in-a-field-in-livecode-5-5

Paul
___
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: Explicit Variables

2016-01-29 Thread Mark Waddingham

On 2016-01-29 19:34, Richard Gaskin wrote:

Mark Waddingham wrote:
Is my understanding correct, or has the engine implementation of
explicitVars changed?


Heh - no - I misread Kay's post... Whenever I see 'explicitVariables' 
mentioned I tend to think of 'Strict Compilation Mode'.


As you point out, turning on explicitVars for an entire session is never 
a good idea unless you control every single line of code in your project 
since you don't know whether code written by someone else is 
'explicitVar' safe or not. Since explicitVars *only* affects 'do', 
'value', 'set the script of' and the compilation of scripts the first 
time they are used there really isn't ever a need to set the property 
anything other than locally to where you are doing that kind of thing. 
(It is also only really worthwhile for the 'set the script of' uses).


Warmest Regards,

Mark.

--
Mark Waddingham ~ m...@livecode.com ~ http://www.livecode.com/
LiveCode: Everyone can create apps

___
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: snapshot and animation capture

2016-01-29 Thread Richmond

At the risk of throwing a spanner in the works I want to refer you
to this:

http://lists.runrev.com/pipermail/use-livecode/2014-January/196782.html

"Hi all, Some weeks ago,
I reported that windowShape was not working in my Lubuntu Linux setup.
After looking around and testing many recipes,
finally I found the program that works in my setup.
The windowshape property was not working in Lubuntu Linux because it 
does not include,

by default a composite manager."

posted by someone wiser than me.

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: Explicit Variables

2016-01-29 Thread Richard Gaskin

Mark Waddingham wrote:
> That should work fine. The explicitVars property is only set in
> the IDE around code which compiles / sets object scripts (i.e.
> In the script editor). It is false the rest of the time.

Is Kay using explicitVars or the IDE's "Strict Compilation Mode"?

My understanding is that the engine's explicitVars property works as it 
does in SuperCard where it came from, that it's persistent throughout 
the session.


In contrast, Strict Compilation Mode only applies explicitVars 
momentarily for compilation to catch the sorts of things it's good for, 
then turning it off again so it doesn't conflict with any other scripts 
that may be running that don't conform to explicitVars' requirements.


Is my understanding correct, or has the engine implementation of 
explicitVars changed?


>> On 29 Jan 2016, at 02:45, Kay C Lan wrote:
>>
>> Not a discussion about the pros and cons, or a discussion on arrays,
>> I just need a simple answer.
>>
>> put "apple,orange,banana" into tFruit
>> repeat with x = 1 to the number of items in tFruit
>>  do "put item x of tFruit into tVar" & x --create a dynamic variable 
name

>> end repeat
>> put tVar2
>>
>> I assume creating dynamic variable names will not work with
>> explicitVariables set in the IDE but it will actually work in a
>> standalone.

As noted above, AFAIK the IDE currently has no means of setting the 
explicitVars global property, at least not in any way that can affect 
things beyond the moment of compilation.  So unless you're turning on 
explicitVars in one of your scripts you should be fine.


Too bad arrays are excluded from this discussion, as they're the perfect 
fit for cases like this where the number or names of variables can't be 
known in advance - simpler to write, faster to run.


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


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


Re: snapshot and animation capture

2016-01-29 Thread Richard Gaskin

Richmond wrote:
> At the risk of throwing a spanner in the works I want to refer you
> to this:
>
> http://lists.runrev.com/pipermail/use-livecode/2014-January/196782.html
>
> "Hi all, Some weeks ago,
> I reported that windowShape was not working in my Lubuntu Linux setup.
> After looking around and testing many recipes,
> finally I found the program that works in my setup.
> The windowshape property was not working in Lubuntu Linux because it
> does not include,
> by default a composite manager."
>
> posted by someone wiser than me.

That was Alejandro, and AFAIK he and I are among the very few people in 
the LC community using Lubuntu specifically (and in all fairness I only 
run it on my oldest computer; everything else runs Ubuntu which includes 
the Compiz compositor).


If the chart showing number of users running different Linux distros in 
the middle of this page is any guide, not much of an issue:



Of the ones shown there, AFAIK only Xubuntu lacks a compositor; Lubuntu 
isn't even on the list.  Like Puppy Linux and other slim distros, both 
Xubuntu and Lubuntu are designed to run on older machines or in 
configurations that don't meet the minimum requirements for more 
fully-features distros like Fedora, Ubuntu, or Mint.  Of the two Lubuntu 
is slightly leaner in its disk and RAM requirements, so I'm not sure why 
Xubuntu is more popular, but regardless consider them both in the bigger 
picture:


Windows: ~85%
Mac: ~10%
Linux:~5%

With Xubuntu at probably less than 5% of Linux' 5% of desktop computers, 
the number of affected users among the total addressable market is very, 
very small.


If we were to look at Xubuntu, Lubuntu, Puppy Linux, and other such 
distros combined, I'd be surprised if the lot of them totaled more than 
0.01% of desktops in use.


And even then, not much to worry about since we choose these lightweight 
distros for specific reasons, and we know what we're in for.  Software 
that requires compositing generally only runs on beefier hardware, so 
when we choose a lightweight distro we understand we're not going to 
have as many apps available to us, and that's generally okay for the 
cases where we want a light OS.


When we need a compositor we know where to get it - after all, how else 
could we run the cube? :)



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


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


Re: snapshot and animation capture

2016-01-29 Thread Richmond

So, I thought I'd have a bash at rolling my own, but got stuck:

on mouseUp
   put topleft of img "border.png" & "," & the bottomright of img 
"border.png" into 

   put quote &  & quote into fld "guff"
   put fld "guff" into 
   export snapshot from rect  of stack "Super Snap" to file 
".png" as PNG

end mouseUp

the thing gets stuck on the "export snapshot" line . . . cannot think 
why . . .


image "snapBTN.png": execution error at line 5 (import: error in 
expression), char 1


that stuff about "char 1" makes NO sense at all.

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: snapshot and animation capture

2016-01-29 Thread [-hh]
Richmond wrote:
> At the risk of throwing a spanner in the works I want to refer you to this:
> http://lists.runrev.com/pipermail/use-livecode/2014-January/196782.html
> "Hi all, Some weeks ago,
> I reported that windowShape was not working in my Lubuntu Linux setup.
> After looking around and testing many recipes,
> finally I found the program that works in my setup.
> The windowshape property was not working in Lubuntu Linux because it 
> does not include, by default a composite manager."
> posted by someone wiser than me.
> Richmond.

What a valuable hint from Alejandro! And what a valuable hint to that hint.
May nearly all your sins be forgiven for that, Richmond:

Based on that I found the way of how to have windowshape on RaspberryPi,
running Raspbian. See here my first screenshot of a LC "frame"-stack
(the skyBlue line is the stack) that makes screenshots.

http://forums.livecode.com/viewtopic.php?f=76=26397

Thank you both very much for that.

Hermann


___
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: Questions: Setting the borderWidth (lineSize) of a graphic through script

2016-01-29 Thread Sannyasin Brahmanathaswami
On January 29, 2016 at 8:21:41 AM, Mark Waddingham 
(m...@livecode.com) wrote:
BorderWidth works fine on graphics here - you set the showBorder to
true, and set the borderWidth. You'll get the original shape inset by
the borderWidth with the border drawn around it.


An interesting caveat here is that is possibly a bug that I should report

LC 7.1.1  recently I created a grp for a nav bar to run at the bottom of the 
app. I would set the bottom of the group to the height of the stack and there 
was this transparent 2 pixel space underneath the group with the background. 
Later I discovered that the the border width was defaulting to 2. I had to 
manually set it to 0 and make sure that show border and 3D were off. There are 
other subtle issues


I tried to replicate this today… make new stack default height 400 ; 2 radio 
buttons group, set bottom to 400. So far so good… I don’t see any space 
underneath. set background color of group to yellow, background of stack to 
red, border color of group to black.  ?? border does not appear…huh?  Oh.. 
yeah.. check “showBorder” Border still does not appear… (blink)… turn off 3D 
and aha! it appears

But... Hmm interesting, with no intervention on my part, the group bottom is 
now 402 I can’t see the bottom border. I go back to colors, clear the border in 
the inspector… what? the black border is still showing even though I cleared 
it.  I have to actually  set the border width to 0… OK *now* the border goes 
away.. and if I set it to 2 again, the black is now gone… so it seems that the 
properties of the group may not always respond to a change in the property 
inspector until you take “some other” action. I suspect this is why I had a 
border that was transparent and made it look as if the group was floating 2 
pixels up from the bottom even though I had cleared the border color and 
unchecked “showBorder”  … I had to uncheck 3D and *then* the transparent area 
went away

This probably needs fixing, but the issues are so subtle as to make it even 
hard to define a report.
___
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