Snippet to show status bar on mobile

2017-01-26 Thread Sannyasin Brahmanathaswami via use-livecode
Do we have control over the layer of the native device top status status bar?

is it always on topmost layer?  if so then we have to dynamically hide and show 
it if we want to occupy the whole screen

OR

is it always on the background layer

if so then we simply have some objects on higher top layer go all the way to top

Your experience with this, share here will be helpful

Thanks!


___
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


Script editor chops "end handler" to "nd handler"

2017-01-26 Thread Sannyasin Brahmanathaswami via use-livecode
I have a bug report on this but HQ says they cannot replicate it.

Today I think I have a definitive recipe. Can you try and confirm?

Symptom:

the "e" at the beginning of the last line end of handlers is getting chopped off

on closeStack
if the environment is "mobile" then
scroller_Delete "scrolling lesson field" # not actually used
end if
pass closeStack
end closeStack   # Ok put your cursor right here immediately after closestack 
and hit return and we get this

on closeStack
if the environment is "mobile" then
scroller_Delete "scrolling lesson field" # not actually used
end if
pass closeStack
nd closeStack
# cursor is here now. but the word "end" above has become "nd"

first seen in 8*  (I think)  and persists in 8.1.3


Can anyone else replicate this? (mac Sierre lc 8*

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

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

Thank you, Klaus!

On 1/26/17 9:51 pm, Klaus major-k via use-livecode wrote:

Hi Richmond,


Am 26.01.2017 um 20:46 schrieb Richmond Mathewson via use-livecode 
:

I'm trying to disable copying from textFields throughout a stack and tried this 
in
the stackScript:

on copyKey
  answer "Hard Cheese, Buster; this is a Demo!"
  pass copyKey
end copyKey

copying of selectedText in a field still occurred . . .
I tried it in a cardScript . . .  nix
and I tried it in the script of the textField I was trying to copy from . . .
[all this on Linux]
does anybody know where I am going wrong, as I seem to be
following the instructions in the Documentation?

just like the "pastekey" message, "copykey" is trapped by the IDE and will
only work in a standalone or with "Suspend LiveCode UI" turned on in the
Development menu.
1. I was reading the Documentation and getting the bit about "Suspend 
LiveCode UI"

completely wrong.

2. And, because of your message I . . . finally . . . realised what 
"Suspend LiveCode UI" was for!


Wonderful Help!

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: Run processes/effects simultaneously with a visual effect ?

2017-01-26 Thread Sannyasin Brahmanathaswami via use-livecode
Ha! Klaus.. Jai Ganesha! Awesome this works (yet to test on mobile)


on mouseUp
  
set the effectrate to 500

   lock screen for visual effect

   put the long Id of image "stone" into pHiddenImage
   put the long Id of image "night" into pVisibleImage

   show tHiddenImage 
   hide tVisibleImage 

   unlock screen with visual effect dissolve very slowly

end mouseUp


so we can set up a "command crossFade pImg1, pImg2" in a library and pass the 
long ID's to it

command crossFade pHiddenImage,pVisibleImage

set the effectrate to 500

lock screen for visual effect
show pHiddenImage
hide pVisibleImage

unlock screen with visual effect dissolve very slowly

end crossFade

let me see how much trouble this gets me into ☺  while trying to do other 
things before and after the fade… 

Brahmanathaswami


 
Klaus major- wrote:

Yes, visual effects are in fact blocking unfortunately!

But maybe you can use something like:
...
set the effectrate to 500
lock screen for visual effect
show image "burger"
hide image "shot"
unlock screen with visual effect dissolve very slowly
...
?

___
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-26 Thread Sannyasin Brahmanathaswami via use-livecode
Others can please chime in here… I'm not sure exactly why the new dictionary is 
"irritating" but it is. 

let's say I want to see all the properties for buttons. I think the old 
dictionary gave us that option.

Now if I click on "association "button"  and click type "properties" I get the 
button props, but the top window on the right only shows a only a few

there was a view in the older dictionary that had a much longer list… I would 
prefer myself a left column that was really long so I can see at a glance all 
the props that the vertical column height will allow, depending on how the user 
has the window sized… and the definitions on the right take up the whole 
vertical space i.e. split window horizontally.  

IMHO we get: 
1) to see a longer list of dictionary entries with out scrolling and
 2) can read more of the definition without scrolling.  to conserve screen 
space I could narrow the window and the definition area on the right panel 
would narrow responsively.

OK now if I type "htmltext" into the search, it comes up empty… why? well of 
course… I am now "stuck" in

associations: "button"
type: "property"

I'm scratching my head… what is happening?  Let's say I have a misconception 
that htmltext has something to do with buttons (it does not, but newbies will 
not know that) so I'm just stuck… my search gave me nothing.. I'm trying to 
understand buttons.  the right and left arrow don’t do anything… 

In the far left column you need a "clear" button or something… I could click 
that, and then my search for "htmltext" would return results (without having to 
type again.)  Only now as I test did I discover that the way to dismiss the 
filters is to click on the filter label "button" or "properties" to "back out" 
of where you are… that is UI "mysterious hidden behavior" that breaks all the 
rules for any good UI design… at least put a small X  top the right of each 
filter or a "clear all" or something.  I don't mind a few "mystery meat" icons… 
any 8 year old today just clicks on everything.. but you don't even have a 
control to reset the space back to "top.. 

OK so I dismiss the filters on the left (but inadvertently leave my search 
string  "htmlText" in the box top right) click on group filter, database list 
of terms is empty… Oh.. .duh I have to go up and manually delete my search 
string…*now* the list appears again..

Then there's the two little arrows at the top next ot a clock… what do they do? 
hmm, I go to  control structure filter… click on  the left arrow at the top and 
takes me to "revCloseCursor"  Why?  Oh wait, I guess that was my previous view… 


It just feels more like a "burden" now to look for information. Perhaps others 
with more UI/UX experience can offer thoughts on this.  I'm using it more and 
more now that I'm away from server side code and code the UI again (too much 
fun…) Maybe its just me… and I need to "get used to it" like riding a motor 
cycle instead of a bike….

On 1/26/17, 1:32 PM, "use-livecode on behalf of Ali Lloyd via use-livecode" 
 wrote:

Hi Brahma,
Goes without saying perhaps but it would be extremely helpful if you could
articulate *why* you find this information harder to come by in the current
dictionary. Thanks!



___
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: 8.1.3 (RC1) Invoking Script Editor Failing Everywhere

2017-01-26 Thread Sannyasin Brahmanathaswami via use-livecode
Turns out it was one of my plug ins… you can see the bug report where the 
problem was attributed to the DataGrid Helper… but I don't use the DGH and I 
had problems with an old old stack I've had for 15 years called 
"Favorites.livecode" build circa 2000 or earlier and migrating forward over 
time. Small toolbox, with launch menu, some buttons for testing "stuff" etc… 

there's really nothing unusual about its properties, it's not lock or 
cantDelete or anything like that. no odd open stack or preopenstack handlers 
that would do weird things, but if it is in my plugins folder 8.1.3 "dies in 
chaos"  take it out, put in others (like your 4thworld ones andsome of Scotts) 
it works just fine.

I sent the stack in with the bug report.  It *is* quite possible that there is 
some horrible legacy code in a button for a test done in 2002 or something… and 
the handler contains lines that are "bad code" from 8.1.3… but I don't think 
the IDE steaps through *all* the code of every plugin… so??

lead me to the question: we know here that some legacy documents that were, for 
example created in Quark Express, then exported to InDesign then used as 
templates over several years.. will gradually become corrupt in mysterious ways 
are indiscernable to the user… presumably at some binary level that does not 
actually cause the program to crash but enough to cause a lot of trouble

could the same be with old, old, old LC stacks?

We'll see it will be interesting to find out what HQ spots….

> -- from the Project Browser, double clicking on in the icon with the
>number of lines in a script does not invoke that script in the SE
> -- opening the PI for an object with an assigne behavior: click "edit
> script" the script for the assigne behavior does not open

I'm unable to reproduce those last two; both work as expected here.

___
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-26 Thread Ali Lloyd via use-livecode
Hi Brahma,
Goes without saying perhaps but it would be extremely helpful if you could
articulate *why* you find this information harder to come by in the current
dictionary. Thanks!

On Thu, 26 Jan 2017 at 20:37, BNig via use-livecode <
use-livecode@lists.runrev.com> wrote:


> @Bernd: is your dictionary plug in working in the latest 8+ versions of
> LC?

That is Björnke who did the plug in.

Kind regards
Bernd



--
View this message in context:
http://runtime-revolution.278305.n4.nabble.com/Delete-element-from-array-tp4711916p4711957.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: SubMenu

2017-01-26 Thread J. Landman Gay via use-livecode
I don't see a way to add submenus to the left-hand list. That might be 
the problem. Only the menu items on the right side allow that. If you 
want to create submenus in the main menus on the left, I think you have 
to do it manually in the property inspector by adding tabs in front of 
submenu items.


On 1/26/17 1:31 AM, Yves COPPE via use-livecode wrote:

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




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

2017-01-26 Thread BNig via use-livecode

> @Bernd: is your dictionary plug in working in the latest 8+ versions of
> LC? 

That is Björnke who did the plug in.

Kind regards
Bernd



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Delete-element-from-array-tp4711916p4711957.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: copyKey

2017-01-26 Thread Klaus major-k via use-livecode
Hi Richmond,

> Am 26.01.2017 um 20:51 schrieb Klaus major-k via use-livecode 
> :
> 
> Hi Richmond,
> 
>> Am 26.01.2017 um 20:46 schrieb Richmond Mathewson via use-livecode 
>> :
>> 
>> I'm trying to disable copying from textFields throughout a stack and tried 
>> this in
>> the stackScript:
>> 
>> on copyKey
>> answer "Hard Cheese, Buster; this is a Demo!"
>> pass copyKey
>> end copyKey
>> 
>> copying of selectedText in a field still occurred . . .
>> I tried it in a cardScript . . .  nix
>> and I tried it in the script of the textField I was trying to copy from . . .
>> [all this on Linux]
>> does anybody know where I am going wrong, as I seem to be
>> following the instructions in the Documentation?
> 
> just like the "pastekey" message, "copykey" is trapped by the IDE and will 
> only work in a standalone or with "Suspend LiveCode UI" turned on in the 
> Development menu.

AND, what Peter Bogdanoff already noted, do not "pass copykey"! :-)

>> Richmond.
> 
> Best
> 
> Klaus

--
Klaus Major
http://www.major-k.de
kl...@major-k.de


___
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: copyKey

2017-01-26 Thread Klaus major-k via use-livecode
Hi Richmond,

> Am 26.01.2017 um 20:46 schrieb Richmond Mathewson via use-livecode 
> :
> 
> I'm trying to disable copying from textFields throughout a stack and tried 
> this in
> the stackScript:
> 
> on copyKey
>  answer "Hard Cheese, Buster; this is a Demo!"
>  pass copyKey
> end copyKey
> 
> copying of selectedText in a field still occurred . . .
> I tried it in a cardScript . . .  nix
> and I tried it in the script of the textField I was trying to copy from . . .
> [all this on Linux]
> does anybody know where I am going wrong, as I seem to be
> following the instructions in the Documentation?

just like the "pastekey" message, "copykey" is trapped by the IDE and will 
only work in a standalone or with "Suspend LiveCode UI" turned on in the 
Development menu.

> Richmond.

Best

Klaus

--
Klaus Major
http://www.major-k.de
kl...@major-k.de


___
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: copyKey

2017-01-26 Thread Peter Bogdanoff via use-livecode
I think you don’t want to pass copyKey, but trap it.


> On Jan 26, 2017, at 2:46 PM, Richmond Mathewson via use-livecode 
>  wrote:
> 
> I'm trying to disable copying from textFields throughout a stack and tried 
> this in
> the stackScript:
> 
> on copyKey
>  answer "Hard Cheese, Buster; this is a Demo!"
>  pass copyKey
> end copyKey
> 
> copying of selectedText in a field still occurred . . .
> 
> I tried it in a cardScript . . .  nix
> 
> and I tried it in the script of the textField I was trying to copy from . . .
> 
> [all this on Linux]
> 
> does anybody know where I am going wrong, as I seem to be
> following the instructions in the Documentation?
> 
> 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


___
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

copyKey

2017-01-26 Thread Richmond Mathewson via use-livecode
I'm trying to disable copying from textFields throughout a stack and 
tried this in

the stackScript:

on copyKey
  answer "Hard Cheese, Buster; this is a Demo!"
  pass copyKey
end copyKey

copying of selectedText in a field still occurred . . .

I tried it in a cardScript . . .  nix

and I tried it in the script of the textField I was trying to copy from 
. . .


[all this on Linux]

does anybody know where I am going wrong, as I seem to be
following the instructions in the Documentation?

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


modTableField mobile

2017-01-26 Thread Mike Kerner via use-livecode
Has anyone messed around with modTableField on mobile?  I've always used
DG's with scrollers, but the performance is sketchy.

-- 
On the first day, God created the heavens and the Earth
On the second day, God created the oceans.
On the third day, God put the animals on hold for a few hours,
   and did a little diving.
And God said, "This is good."
___
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-26 Thread Malte Brill via use-livecode
Hey Trevor,

https://github.com/trevordevore/levure 
this is looking like a potential winner. I would love to see how involved it is 
to move an existing application over to the framework. I have a rather big 
application that uses a couple of substacks which I want to make VCS friendly. 
Up until now it does not use any frameworks at all (besides the stuff that I 
wrote myself) so this shall be interesting.

I am not claiming to understand what you set up as yet, so I guess this 
requires quite a bit of investigation and would not be a quick shot. At first I 
was aiming at something lightweight that would work for my personal usecase, 
however I see the benefits of structuring work using a framework. Very very 
interesting.


Cheers,

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


Re: Run processes/effects simultaneously with a visual effect ?

2017-01-26 Thread Klaus major-k via use-livecode
Hi Swami,

> Am 26.01.2017 um 19:09 schrieb Sannyasin Brahmanathaswami via use-livecode 
> :
> 
> I'm looking to "dress" up our new app with more elegant visuals.
> I was using send in time to a handle that changes the blendlevel of small 
> objects… this works well and is none blocking.
> But someone asked "Why don't you just use dissolve?"
> Duh.. the dictionary doesn't give the platforms that work with dissolve but 
> apparently, it runs just fine on iOS and Android.

works also on the desktop (Mac and Win)!

> So,  I did some tests…wondering about the engine's timing work with visual 
> effects:

Use "the effectrate" to set the duration of the "very slowly" (sic!) visual 
effect.
Mentally a bit challenging, but works! :-D

> ...
> Are simultaneous visual effects + some process even possible? The dictionary 
> does not explicitly declare visual effect to be blocking. But all my tests 
> indicate it is.  I hope I am wrong.

Yes, visual effects are in fact blocking unfortunately!

But maybe you can use something like:
...
set the effectrate to 500
lock screen for visual effect
show image "burger"
hide image "shot"
unlock screen with visual effect dissolve very slowly
...
?

> BR

Best

Klaus

--
Klaus Major
http://www.major-k.de
kl...@major-k.de


___
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

Run processes/effects simultaneously with a visual effect ?

2017-01-26 Thread Sannyasin Brahmanathaswami via use-livecode
I'm looking to "dress" up our new app with more elegant visuals.

I was using send in time to a handle that changes the blendlevel of small 
objects… this works well and is none blocking.

But someone asked "Why don't you just use dissolve?"

Duh.. the dictionary doesn't give the platforms that work with dissolve but 
apparently, it runs just fine on iOS and Android.

So,  I did some tests…wondering about the engine's timing work with visual 
effects:

create stack
place image
put two buttons "hide"  "show" and one field "bool"

Btn 1:
on mouseUp
put empty into fld "bool"
hide image burger with visual effect dissolve very slowly
put "false" into fld "bool"
answer "Are U Hidden Yet?" with "Yes" or "No"
end mouseUp

btn 2:
on mouseUp
put empty into fld "bool"
show image burger with visual effect dissolve very slowly
put "true" into fld "bool"
answer "Are U Showing Yet?" with "Yes" or "No"
end mouseUp

that visual effect is blocking. The commands that follow do not run until the 
visual effect is done, effectively visual effect is a "wait"

Also the dictionary says if you put two visual effects one after another they 
run consecutively.

but what if you want 2 visual effects to run simultaneously  and also have 
another process (like type txt or invoke a dialog etc) occur at the same time?

typical example:, let's say I want to create a cross fade between two images. 
The show and hide for each one with dissolve would need to run simultaneously.  
I'm using "very slowly" for testing, in a real app we would probably use very 
fast or fast.

img 1: "burger:
img 2: "shot"

on mouseUp
hide image burger with visual effect dissolve very slowly
show image shot with visual effect dissolve very slowly
end mouseUp


on mouseUp
put empty into fld "bool"
show image burger with visual effect dissolve very slowly
hide image shot with visual effect dissolve very slowly
put "true" into fld "bool"
answer "Are U Showing Yet?" with "Yes" or "No"
end mouseUp

in both cases the first effect runs and then the next one.. I don't get a 
"cross fade"  effect. in the latter, first the hidden image appears (behind the 
one in front) then the front one dissolves, then the fld is filled and then the 
answer dialog opens…

locking and unlocking the screen doesn't help

Are simultaneous visual effects + some process even possible? The dictionary 
does not explicitly declare visual effect to be blocking. But all my tests 
indicate it is.  I hope I am wrong.

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

2017-01-26 Thread Sannyasin Brahmanathaswami via use-livecode
Thank. Yes.. it is there in the dictionary but I glossed over it somehow. Not 
sure the new dictionary is an improvement of the one we had all these years… 

@Bernd: is your dictionary plug in working in the latest 8+ versions of LC? 


 

On 1/24/17, 5:04 PM, "use-livecode on behalf of Phil Davis via use-livecode" 
 wrote:

delete variable tMyArray["this key"]



___
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: can't open file on web server

2017-01-26 Thread Malte Brill via use-livecode
Hi Tiemo,

did you try the URL directly without using the binfile keyword?

put URL „http://www.somServer/someImage.jpg 
“ into img „myImage“ ? This works here. If 
you are using either the file or binfile keyword you are indicating file access 
to the engine, which might work with a UNC path, not if the protocoll for 
transmission is http though. 

Hope that helps,

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

RE: Dumb deployment question

2017-01-26 Thread Erik Beugelaar via use-livecode
The Levure framework will be a big step forward for starters building LiveCode 
apps in a structured way. It also explains the Message Path filosophy in the 
current framework just by reading the code.

Trevor, you have my vote  to publish an article of it in the next blog post on 
the website of LiveCode.

Cheers,
Erik 

-Original Message-
From: use-livecode [mailto:use-livecode-boun...@lists.runrev.com] On Behalf Of 
Trevor DeVore via use-livecode
Sent: donderdag 26 januari 2017 00:19
To: How to use LiveCode 
Cc: Trevor DeVore 
Subject: Re: Dumb 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 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


___
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

can't open file on web server

2017-01-26 Thread Tiemo Hollmann TB via use-livecode
Hello,

I have a field "MediaFileLink", the content is a URL to an image on a web
server like "http://myServer/myPath/myImage.jpg";

this works in IDE:

*set the filename of img "productimage" to field "MediaFileLink"*

This works not in IDE:

*put URL ("binfile:" & field "MediaFileLink) into image "productimage"*

Also not hard coded:

*put URL ("binfile:http://myServer/myPath/myImage.jpg";) into image
"productimage"*

I get as a result "can't open file"

 

Any idea, why those images can't be opened by LiveCode with the keyword URL
(I am not aware of having locked those images on the server) and why it
works by setting the filename?

Thanks

Tiemo

 

 

 

 

___
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