Recent

Author Topic: Resize the components along with resizing of the form  (Read 5441 times)

Kushal

  • New Member
  • *
  • Posts: 33
Resize the components along with resizing of the form
« on: January 29, 2013, 01:18:07 pm »
May i know how to resize the components on the form along with resizing the form [normal to maximizing, vice-versa and other sizes]

for example if im developing an application for linux and align all components  as required on the form it works well on my laptop (14") and if i run the same app on a PC with screen of 52" i need all the components to be resized as per the resolution.

if there is a way to achieve this please let me know.

Thanks in advance.

Blaazen

  • Hero Member
  • *****
  • Posts: 3241
  • POKE 54296,15
    • Eye-Candy Controls
Re: Resize the components along with resizing of the form
« Reply #1 on: January 29, 2013, 01:28:57 pm »
I believe you can do it using:
1) Proper aligning and anchoring (each component has property Anchors). Also Childsizing and Borderspacing properties may be useful.
2) If it depends on your screen resolution, you can get the info: x:=Screen.Width; and y:=Screen.Height;

http://wiki.lazarus.freepascal.org/Autosize_/_Layout

EDIT: Forms have also property PixelsPerInch.
« Last Edit: January 29, 2013, 02:00:33 pm by Blaazen »
Lazarus 2.3.0 (rev main-2_3-2863...) FPC 3.3.1 x86_64-linux-qt Chakra, Qt 4.8.7/5.13.2, Plasma 5.17.3
Lazarus 1.8.2 r57369 FPC 3.0.4 i386-win32-win32/win64 Wine 3.21

Try Eye-Candy Controls: https://sourceforge.net/projects/eccontrols/files/

 

TinyPortal © 2005-2018