Recent

Author Topic: Absolute positioning of components  (Read 546 times)

peterbos

  • Newbie
  • Posts: 3
Absolute positioning of components
« on: November 30, 2023, 12:14:10 am »
Hi,

How do I place LAMW components on absolute positions? I set the Left and Top properties of a TCheckbox:

CheckBox1.Left := 50;
CheckBox1.Top  := 50;


In the Lazarus IDE the CheckBox is on the right spot but on my phone it is in the upperleft corner.  I tried playing with PosRelativeToParent and PosRelativeToAnchor but I can't get it to work. What do I do wrong?

Peter

dseligo

  • Hero Member
  • *****
  • Posts: 1149
Re: Absolute positioning of components
« Reply #1 on: November 30, 2023, 01:06:11 am »
Try setting MarginLeft and MarginTop.

jmpessoa

  • Hero Member
  • *****
  • Posts: 2296
Re: Absolute positioning of components
« Reply #2 on: December 02, 2023, 12:23:03 am »

Quote
How do I place LAMW components on absolute positions....

You can't!

But,  what do you need?
Lamw: Lazarus Android Module Wizard
https://github.com/jmpessoa/lazandroidmodulewizard

 

TinyPortal © 2005-2018