anchors

Questions and answers for designing and implementing forms in Servoy

anchors

Postby Hans Nieuwenhuis » Sat Feb 02, 2013 12:06 am

Hi,

I am testing with labels and anchors.
Set the anchors of the three labels below to l,t,r,b
normal window size is oke, resized window does not show the lables as I would like to :

nonscaled.png
nonscaled.png (34.86 KiB) Viewed 2226 times


resized.png
resized.png (47.15 KiB) Viewed 2226 times


What am I doing wrong, or is this not possible ???

Regards,
Hans Nieuwenhuis
Betagraphics
http://www.deltics.nl
http://www.betagraphics.nl

Servoy Version 7.3.1
Java version 1.7.0.x
Database Oracle 11g
User avatar
Hans Nieuwenhuis
 
Posts: 1026
Joined: Thu Apr 12, 2007 12:36 pm
Location: Hengelo, The Netherlands

Re: anchors

Postby mboegem » Sat Feb 02, 2013 2:49 am

Hi Hans,

The way you set it now is as it behaves.
So that's expected.
Normally you would have 1 label anchor left, 1 label anchor right, 1 label anchor left/right.
Top/bottom anchoring can be set as you please.

In case you want the labels to be distributed evenly, you will have to write a method which will be triggered on show/on resize of windows.
Within the method:
1- determine the width of the window
2- set the label x-position/width at runtime
Marc Boegem
Solutiative / JBS Group, Partner
Servoy Specialist
• Servoy Certified Developer
• Servoy Valued Professional
• Freelance Developer

Image
User avatar
mboegem
 
Posts: 1750
Joined: Sun Oct 14, 2007 1:34 pm
Location: Amsterdam


Return to Forms

Who is online

Users browsing this forum: No registered users and 9 guests

cron