Truncated text in pickwheel

Getting into LiveCode for iOS? Ask your questions here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
SusanB
Posts: 111
Joined: Mon Nov 07, 2011 4:10 am
Location: San Jose area, California, USA
Contact:

Truncated text in pickwheel

Post by SusanB » Wed Jul 26, 2017 5:35 am

I did a search on this issue and only came up with the question I asked awhile back. I got no answers then, but was hoping for better luck this time. I would greatly appreciate!!

Does anybody know how to prevent text from truncating in the pickwheel? As each line comes into focus while scrolling, the text enlarges and "...." replaces some of the last letters. Changing textsize and size of the button doesn't help.

SusanB

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: Truncated text in pickwheel

Post by bogs » Wed Jul 26, 2017 12:49 pm

You'll have to forgive me if this seems a dense or obtuse question, but what is a pickwheel? Can you post a picture of what your trying to accomplish? Even if it is just a sketch or doodle, it may help you get the answers you need.
Image

Klaus
Posts: 13806
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: Truncated text in pickwheel

Post by Klaus » Wed Jul 26, 2017 2:00 pm

If you own any cellphone (unlike me :D ), you surely will have seen and used this.
See attached pic...
Image

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: Truncated text in pickwheel

Post by bogs » Wed Jul 26, 2017 2:44 pm

I actually *did* get a cell phone recently, but it has nothing like that. Of course, I should also point out that it is a phone that is very limited, not powered by one of the big two Os's, etc. Interesting to know what a pickwheel is, though, I had only seen a reference to it in a completely different language.

Looking at it, though, the only way I could see text getting trucated is if the font were too large, or if the margins were some how off? It looks like a regular field to me.
Image

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7215
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: Truncated text in pickwheel

Post by jacque » Wed Jul 26, 2017 3:56 pm

Pickwheels are only on iOS, it's an Apple interface.

The OS controls it, I don't think it's possible to change its behavior or appearance. About all you can do is use shorter strings.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

SusanB
Posts: 111
Joined: Mon Nov 07, 2011 4:10 am
Location: San Jose area, California, USA
Contact:

Re: Truncated text in pickwheel

Post by SusanB » Wed Jul 26, 2017 5:25 pm

That's what I thought, Jacques. The pickwheel on the old iPhones didn't do the truncating and looked more like the posted example. It's not a life or death matter, but would be nice to be able to control the handling of the text there.

[-hh]
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2262
Joined: Thu Feb 28, 2013 11:52 pm
Location: Göttingen, DE

Re: Truncated text in pickwheel

Post by [-hh] » Thu Jul 27, 2017 12:13 pm

See the paragraph "Variable Width Presentation Strings" in
https://developer.apple.com/library/con ... 10_12Notes

So you may have to issue a feature request for LC's iOS part ...
shiftLock happens

jiml
Posts: 336
Joined: Sat Dec 09, 2006 1:27 am
Location: Los Angeles

Re: Truncated text in pickwheel

Post by jiml » Thu Jul 27, 2017 6:38 pm

Truncating, as Jacque suggests, seems the best way to go. However you could break a long line into multiple lines.
For example consider this list of three fruits:
  • Cherry
    Peeled and sliced banana
    Peach
Line 2 may be too long to fit into the picker. So, you might break line 2 into two lines, inserting a couple of spaces into the extra line to give an indented appearance:
  • Cherry
    Peeled and
    — sliced banana
    Peach
You'd then map the value of the selected line to the fruit list:
1 = Cherry
2 or 3 = Banana
4 = Peach

Admittedly this is a very kludgey and non-standard alternative.

Jim Lambert

SusanB
Posts: 111
Joined: Mon Nov 07, 2011 4:10 am
Location: San Jose area, California, USA
Contact:

Re: Truncated text in pickwheel

Post by SusanB » Thu Jul 27, 2017 6:40 pm

I like that :)

quailcreek
Posts: 746
Joined: Sun Feb 04, 2007 11:01 pm
Location: McKenna, WA

Re: Truncated text in pickwheel

Post by quailcreek » Wed Aug 23, 2017 9:14 pm

The only way I've been able to get around this is to set the last choice in the pickWheel list to be a series of "-- ---- ----- --- ---" dashes and spaces. I keep playing with the size until the truncation is eliminated. Of course you have to handle the event when the user selects the last item in the pickWheel.
Tom
MacBook Pro OS Mojave 10.14

SusanB
Posts: 111
Joined: Mon Nov 07, 2011 4:10 am
Location: San Jose area, California, USA
Contact:

Re: Truncated text in pickwheel

Post by SusanB » Wed Aug 23, 2017 9:16 pm

Thank you!! I look forward to trying this out.

Post Reply

Return to “iOS Deployment”