Seeking clarification on which Android versions to build against in LC 9.5.0 (dp 1)

2019-06-03 Thread Terry Judd via use-livecode
OK - so I'm trying out 9.5.0 (dp 1) and am loving the fact that we now have a 
functional emulator (I'm using Android Studio) that we can use to test Android 
apps. Thanks dev team! But, I'm not entirely clear which processors I need to 
build against in order to publish the app. I'm *not* distributing the app via a 
store but am instead just allowing users (students) to download and install it 
directly. In the past I just had to select to build against 'Android' but now 
there are 4 possible build options. I'm assuming that I can ignore both x86 
ones unless I am using the emulator, which leaves me with armv7 and arm64 (same 
as armv8?) to choose from. Do I need both, and if I do, how might I go about 
advising our students which one they should download and install?

Terry...

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


Black boxes replace images in Mojave (Was "No subject")

2019-06-03 Thread Tom Bodine via use-livecode
Thanks, HH and Marty.

Marty wrote:

Are you setting the “ink” to something other than the standard srcCopy?

I am using srcCopy. Other settings are: don't dither ON, Buffer OFF. Resize
quality: Best. Blend Lvl: 0 Layer mode: Static.

HH wrote:

Did you already try to
   set the paintcompression to PNG
in the standalone?

Or set it to the paintcompression of the imported image?

The black boxes result possibly from alpha data problems
because a standalone's paintcompression is RLE by default ...

I will try that. If I set that globally, does it automatically apply to all
image controls in the stack?

Thanks!

Tom Bodine

Original Post:

I'm troubleshooting a rare image issue and hope you can help.

The issue is that some (not all) images used in a LC standalone app appear
as black boxes.

Details:

* Only happens if user is on Mac Mojave.

* All pictures appeared normally for the users before upgrading to Mojave.
After upgrading to Mojave, the black boxes appeared for certain pictures.
(Other pictures in the same game work fine.)

* For one user, pictures that failed to render were all screenshots done on
her Mac.

* For another user, failing pictures were all composite images from
photographs. (He arranged one or more images on his screen and use Grab or
Photoshop to capture them as a composite image.)

* The issue can happen with either jpg or png files.

* I am certain the picture paths are valid, because LC is finding them and
sizing the image control's rect to the aspect ratio of the images.

* The app in use is a LC standalone built on Mac with LC 8.1.10.

* The app allows users to select images to add to a quiz. Images are stored
in a media folder and loaded as needed into an image control for display.
Only one image file is shown at a time. (This has worked reliably for many
years.) The full path to the image file is provided to the image control.

Have you seen any similar issue or do you have a theory about what's going
on?
___
use-livecode mailing list
use-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: A question about openCard

2019-06-03 Thread Richard Gaskin via use-livecode

Simon Knight wrote:

> "Is there some simple way that an openCard handler can branch based on
> what card it is coming from?"
>
> My solution would be to give each card a customprop named say
> “uCalledBy".  Then when the app changes cards I set this prop e.g.
>
> Set the uCalledBy of Card 42 to “HitchHikers”
> Go to Card 42
>
> Then in Card 42 ’s  opencard or anywhere else
>
> If the uCalledBy of me is “HitchHikers” then
>answer “Where is your towel?”
> end if

Custom properties are an excellent option when both of these 
requirements are met:


1. The data is most meaningfully expressed when bound to a specific
   object.

2. The data benefits from persistence.

In the scenario at hand, #1 is well met, but #2 may be problematic.

For example, if you happen to save the stack while working on it (who 
doesn't?) then you'll have property values in place that may not be 
relevant to the next runtime session.


This would require that you add a handler to clear those properties on 
startup, or some other useful entry point for execution, in addition to 
adding the code above.


When you find yourself writing handlers to clean up after other handlers 
you've written, it may be time to reconsider the original premise.



FWIW Jacque's solution seems the most with-the-grain one yet, using the 
function designed for this purpose:


> Look at the recentCards. Line 2 is the card you came from.

--
 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: No subject

2019-06-03 Thread hh via use-livecode
> Tom B. wrote:
> The issue is that some (not all) images used in a LC standalone app
> appear as black boxes.

Did you already try to
   set the paintcompression to PNG
in the standalone?

Or set it to the paintcompression of the imported image?

The black boxes result possibly from alpha data problems
because a standalone's paintcompression is RLE by default ...

___
use-livecode mailing list
use-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:

2019-06-03 Thread Knapp Martin via use-livecode
Are you setting the “ink” to something other than the standard srcCopy? I had 
some image weirdness that happened when I upgraded to Mojave, though I don’t 
remember which ink setting it was that caused it.

---
Marty Knapp


> On Jun 3, 2019, at 8:31 AM, Tom Bodine via use-livecode 
>  wrote:
> 
> Hi all.
> 
> I'm troubleshooting a rare image issue and hope you can help.
> 
> The issue is that some (not all) images used in a LC standalone app appear
> as black boxes.
> 
> Details:
> 
> * Only happens if user is on Mac Mojave.
> 
> * All pictures appeared normally for the users before upgrading to Mojave.
> After upgrading to Mojave, the black boxes appeared for certain pictures.
> (Other pictures in the same game work fine.)
> 
> * For one user, pictures that failed to render were all screenshots done on
> her Mac.
> 
> * For another user, failing pictures were all composite images from
> photographs. (He arranged one or more images on his screen and use Grab or
> Photoshop to capture them as a composite image.)
> 
> * The issue can happen with either jpg or png files.
> 
> * I am certain the picture paths are valid, because LC is finding them and
> sizing the image control's rect to the aspect ratio of the images.
> 
> * The app in use is a LC standalone built on Mac with LC 8.1.10.
> 
> * The app allows users to select images to add to a quiz. Images are stored
> in a media folder and loaded as needed into an image control for display.
> Only one image file is shown at a time. (This has worked reliably for many
> years.) The full path to the image file is provided to the image control.
> 
> Have you seen any similar issue or do you have a theory about what's going
> on?
> 
> Thanks,
> 
> Tom Bodine
> 
> P.S.: Apologies if this post appears more than once. My original listserve
> account wasn't working.
> ___
> use-livecode mailing list
> use-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: A question about openCard

2019-06-03 Thread J. Landman Gay via use-livecode

Look at the recentCards. Line 2 is the card you came from.

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

Is there some simple way that an openCard handler can branch based on
what card it is coming from?





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


[no subject]

2019-06-03 Thread Tom Bodine via use-livecode
Hi all.

I'm troubleshooting a rare image issue and hope you can help.

The issue is that some (not all) images used in a LC standalone app appear
as black boxes.

Details:

* Only happens if user is on Mac Mojave.

* All pictures appeared normally for the users before upgrading to Mojave.
After upgrading to Mojave, the black boxes appeared for certain pictures.
(Other pictures in the same game work fine.)

* For one user, pictures that failed to render were all screenshots done on
her Mac.

* For another user, failing pictures were all composite images from
photographs. (He arranged one or more images on his screen and use Grab or
Photoshop to capture them as a composite image.)

* The issue can happen with either jpg or png files.

* I am certain the picture paths are valid, because LC is finding them and
sizing the image control's rect to the aspect ratio of the images.

* The app in use is a LC standalone built on Mac with LC 8.1.10.

* The app allows users to select images to add to a quiz. Images are stored
in a media folder and loaded as needed into an image control for display.
Only one image file is shown at a time. (This has worked reliably for many
years.) The full path to the image file is provided to the image control.

Have you seen any similar issue or do you have a theory about what's going
on?

Thanks,

Tom Bodine

P.S.: Apologies if this post appears more than once. My original listserve
account wasn't working.
___
use-livecode mailing list
use-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: A question about openCard

2019-06-03 Thread Bob Sneidar via use-livecode
ResumeStack can be tricky. For instance, if you are tracing a resumeStack 
handler to debug it, every time you click back on to the stack in question, it 
will trigger the debugger and suspend the stack again! Rinse and repeat until 
you realize you can't trace a resumeStack handler without some special 
handling. 

Bob S


> On Jun 2, 2019, at 17:22 , Klaus major-k via use-livecode 
>  wrote:
> 
>> I’m not sure I understand the full range of events that “close” a card so 
>> that returning to it triggers “openCard.”  Does this happen if I set an 
>> insertion point or select text in an unlocked field in a palette, or the 
>> user types there?  Does it happen if I open a palette, or move a palette, or 
>> if the user clicks on the palette?
> 
> See above, resumestack/suspendstack are the messages you could check, if 
> neccessary, in that case.
> 
>> Many thanks.
>> 
>> David Epstein
> 
> Best
> 
> Klaus
> 

___
use-livecode mailing list
use-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: SQLite import

2019-06-03 Thread Bob Sneidar via use-livecode
You can execute any single line sql command using revDBExecute() or it's 
command version revExecuteSQL. Also, there may be command line or teminal 
commands to do so. Use these commands when you want to execute an SQL statement 
but do not need to return a cursor. 

Use LOAD DATA INFILE in your sql statement. Google for specifics. 

Bob S


> On May 31, 2019, at 17:37 , Glen Bojsza via use-livecode 
>  wrote:
> 
> Hello,
> 
> I know LC can script SQLite database inserts but can you script an SQLite
> csv  file import?
> 
> thanks,
> 
> Glen


___
use-livecode mailing list
use-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: A question about openCard

2019-06-03 Thread hh via use-livecode
> David E. wrote:
> Is there some simple way that an openCard handler can branch based on
> what card it is coming from?

TMHO, the function that's made for that is

the target

(dictionary) Returns the object which received the message that started 
execution.
Use the target function within a message handler to determine which object
originally received the message.
___
use-livecode mailing list
use-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] This Week in LiveCode 180

2019-06-03 Thread panagiotis merakos via use-livecode
Hi all,

Read about new developments in LiveCode open source and the open source
community in today's edition of the "This Week in LiveCode" newsletter!

Read issue #180 here: http://bit.ly/2KoA6ov

This is a weekly newsletter about LiveCode, focussing on what's been
going on in and around the open source project. New issues will be
released weekly on Mondays. We have a dedicated mailing list that will
deliver each issue directly to you e-mail, so you don't miss any!

If you have anything you'd like mentioned (a project, a discussion
somewhere, an upcoming event) then please get in touch.

-- 
Panagiotis Merakos 
LiveCode Software Developer

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: A question about openCard

2019-06-03 Thread Simon Knight via use-livecode
"Is there some simple way that an openCard handler can branch based on what 
card it is coming from?"

My solution would be to give each card a customprop named say “uCalledBy".  
Then when the app changes cards I set this prop e.g.

Set the uCalledBy of Card 42 to “HitchHikers”
Go to Card 42

Then in Card 42 ’s  opencard or anywhere else 

If the uCalledBy of me is “HitchHikers” then
   answer “Where is your towel?”
end if



Simon

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