The rectangle of a group

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
Mag
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 802
Joined: Fri Nov 16, 2012 10:51 pm

The rectangle of a group

Post by Mag » Wed Nov 20, 2013 4:47 pm

Hi all,

I'm dealing with positioning of a group with a toolbar which contains buttons and a graphic. It seems to me that the rectangle of the gourp has some pixels more that the ofe of the included object, for exaple to align the bar to the bottom of the card, I have to add 4 pixels:

Code: Select all

set the bottom of group "Toolbar" to the bottom of this card+4
Is there something that I don't know or make wrong?

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10052
Joined: Sat Apr 08, 2006 7:05 am
Contact:

Re: The rectangle of a group

Post by FourthWorld » Wed Nov 20, 2013 5:10 pm

Groups have a margin property, which is set to 4 by default. This margin is useful to maintain consistency with the HIGs when providing a frame around grouped controls, but when using groups for any other purpose you can safely set the margin to 0.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

Mag
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 802
Joined: Fri Nov 16, 2012 10:51 pm

Re: The rectangle of a group

Post by Mag » Wed Nov 20, 2013 5:58 pm

FourthWorld wrote:Groups have a margin property, which is set to 4 by default. This margin is useful to maintain consistency with the HIGs when providing a frame around grouped controls, but when using groups for any other purpose you can safely set the margin to 0.
Thank you so much Richard. Is the margin property a value I have to set via cose or there is a value in the Inspector (that I didn't find).

Klaus
Posts: 14199
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: The rectangle of a group

Post by Klaus » Wed Nov 20, 2013 6:09 pm

Hi Mag,

check the "Text Formatting" options of the group in the inspector!
There you will find at the bottom :D


Best

Klaus

Mag
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 802
Joined: Fri Nov 16, 2012 10:51 pm

Re: The rectangle of a group

Post by Mag » Wed Nov 20, 2013 6:21 pm

Thanks a lot guys!

Post Reply