Header Bar labels

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
marksmithhfx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 931
Joined: Thu Nov 13, 2008 6:48 am

Header Bar labels

Post by marksmithhfx » Sat Sep 05, 2020 4:52 pm

I am trying to figure out why the label for the Back arrow is appearing, while the one for the Forward arrow is not? Any suggestions. BTW, the options for the "Actions Display" are only icons and text, where "both" would seem to be a legitimate option?

Thanks
Attachments
Screen Shot 2020-09-05 at 4.49.37 PM.png
macOS 12.6.5 (Monterey), Xcode 14.2, LC 10.0.0, iOS 15.6.1
Targets: Mac, iOS

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10099
Joined: Fri Feb 19, 2010 10:17 am

Re: Header Bar labels

Post by richmond62 » Sat Sep 05, 2020 5:37 pm

At the risk of sounding extremely goofy . . .

I wonder if that is because there is not enough space to fit 'FORWARD' between the '>' and the date.

Possibly the way to test this is to make the stack wider and see if 'FORWARD' appears.

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10099
Joined: Fri Feb 19, 2010 10:17 am

Re: Header Bar labels

Post by richmond62 » Sat Sep 05, 2020 5:48 pm

Oh, b*ll*ocks: this is on a Macintosh computer:
-
Screenshot 2020-09-05 at 19.43.24.png
-
Screenshot 2020-09-05 at 19.43.52.png
-
For some queer reason it looks as if you can have THIS or THAT, but not 'and'.

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10319
Joined: Wed May 06, 2009 2:28 pm

Re: Header Bar labels

Post by dunbarx » Sat Sep 05, 2020 6:02 pm

Hi.

Took me a minute to figure out you were working with a widget. This happens often, as with dataGrids, where I am thinking about the foundations of LC instead of the particulars of a special object within LC.

Please tell me right away. 8)

Craig

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10099
Joined: Fri Feb 19, 2010 10:17 am

Re: Header Bar labels

Post by richmond62 » Sun Sep 06, 2020 2:49 pm

I had a poke, but really could not quite understand whether changing this would add a 3rd option

icon & label

-
Screenshot 2020-09-06 at 16.48.03.png

marksmithhfx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 931
Joined: Thu Nov 13, 2008 6:48 am

Re: Header Bar labels

Post by marksmithhfx » Mon Sep 07, 2020 9:52 am

dunbarx wrote:
Sat Sep 05, 2020 6:02 pm
Hi.

Took me a minute to figure out you were working with a widget. This happens often, as with dataGrids, where I am thinking about the foundations of LC instead of the particulars of a special object within LC.
Craig
Thanks Richmond for having a look into this. You are correct Craig, -- it is the header bar widget. I think the issue (not really an issue, but perhaps more the "reason") has to do with Apple interface conventions. Since installing my own header bar I have been paying more attention to how other apps do this, and the convention does seem to be a label on the left and not on the right. For example, Apple Settings, Reminders and Contacts all do this (or an icon on the right) exactly as LC has defined this. But I think there are lots of exceptions out there and people who do their own thing.

I wonder if I might be able to create my own label icon with text (as an image) and insert that? This is LC after all, there should be a solution.

Cheers,
Mark
macOS 12.6.5 (Monterey), Xcode 14.2, LC 10.0.0, iOS 15.6.1
Targets: Mac, iOS

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10319
Joined: Wed May 06, 2009 2:28 pm

Re: Header Bar labels

Post by dunbarx » Mon Sep 07, 2020 3:26 pm

I wonder if I might be able to create my own label icon with text (as an image) and insert that? This is LC after all, there should be a solution.
Of course you can. I do not use LCB, and have never used a widget. I always build my own gadgetry. Just group a bunch of controls and add a handler.

Craig

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10099
Joined: Fri Feb 19, 2010 10:17 am

Re: Header Bar labels

Post by richmond62 » Mon Sep 07, 2020 4:18 pm

Screenshot 2020-09-07 at 18.16.21.png
-
I have used 2 buttons with 2 images (see bottom of each card) as icons.
Attachments
AROUND ABOUT.livecode.zip
Here's the stack
(2.56 KiB) Downloaded 179 times

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7392
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Header Bar labels

Post by jacque » Mon Sep 07, 2020 5:06 pm

I wonder if I might be able to create my own label icon with text (as an image) and insert that?
You can't insert your own controls without rewriting the widget itself in LCB, but as others have shown, it's pretty easy to make your own group and use that.

There are SVG icons in the SVG library that will scale better than images if you plan to account for different screen sizes.

One thing to think about is whether it's a good idea to ignore the conventional iOS guidelines for header bars. Apple prefers consistency in its apps. I don't think this would get you rejected from the App Store but it is a departure from the norm.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

marksmithhfx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 931
Joined: Thu Nov 13, 2008 6:48 am

Re: Header Bar labels

Post by marksmithhfx » Fri Sep 11, 2020 3:20 pm

jacque wrote:
Mon Sep 07, 2020 5:06 pm
I wonder if I might be able to create my own label icon with text (as an image) and insert that?
One thing to think about is whether it's a good idea to ignore the conventional iOS guidelines for header bars. Apple prefers consistency in its apps. I don't think this would get you rejected from the App Store but it is a departure from the norm.
Thanks Jacque, good advice. I'm leaving it "as is" for now, as I think even without the word the intent is pretty clear. No one would be confused about what it is doing there and, like my kids used to do when we first got "new fangled" gadgets, just press the button and see what happens.

Mark
macOS 12.6.5 (Monterey), Xcode 14.2, LC 10.0.0, iOS 15.6.1
Targets: Mac, iOS

Post Reply