Intermittent crash on set textFont

If you find an issue in LiveCode but are having difficulty pinning down a reliable recipe or want to sanity-check your findings with others, this is the place.

Please have one thread per issue, and try to summarize the issue concisely in the thread title so others can find related issues here.

Moderator: Klaus

Post Reply
francis6425
Posts: 15
Joined: Tue Aug 18, 2015 6:48 am

Intermittent crash on set textFont

Post by francis6425 » Mon Sep 21, 2015 4:26 pm

Hi,

I need to set the textFont to a custom font for a number fields according to the user's choice.
There is no problem when running in windows, but when I test it out in android, it crash intermittently.

After numerous days of trying, I still can't figure out where is the problem.
Sometimes after setting the default textSize to certain value, it becomes stable, but when I try the same thing in another stack it still crash.
I also tried to set the textFont and textSize (one after another) and it crash faster.

So I believe its a bug. Please verify.
I have also attached some test code.

Regards,
Francis
Attachments
testFont.zip
Sample showing that it will crash intermittently.
(161.8 KiB) Downloaded 149 times

francis6425
Posts: 15
Joined: Tue Aug 18, 2015 6:48 am

Re: Intermittent crash on set textFont

Post by francis6425 » Thu Sep 24, 2015 5:28 am

I've added a newer sample to show that it will crash in android after changing the textFont and the textSize.
I've also set the text field fixed line height to false to make it slightly more stable but will still crash intermittently.

Anyone tried this, please advise if you encounter it crashing or not.
Attachments
Font.zip
New sample for the bug in android
(166.6 KiB) Downloaded 147 times

SparkOut
Posts: 2943
Joined: Sun Sep 23, 2007 4:58 pm

Re: Intermittent crash on set textFont

Post by SparkOut » Thu Sep 24, 2015 6:08 am

I had an issue recently with "frequent crashes (90% of the time) but not reliably reproducible" on Android when using FontAwesome glyph fonts and setting textSize. Mostly it would crash when the first card opened and the textFont and textSize was being set. Very occasionally it would work and then crash when the orientation changed and the card layout script was resetting the text. I will revisit the issue when I can, but for now I have worked around it by using images instead of glyph fonts.
When I can I will test your stack, but I think we have seen the same bug.

Post Reply