Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to stop control resizing when removing anchoring?

When removing an anchoring, a control can automatically resize itself to some other size.

Steps to reproduce

  1. Drop a control on a form

    enter image description here

  2. Set an anchor

    enter image description here

  3. Resize the form; watch the control resize with it:

    enter image description here

  4. Remove the anchor:

    enter image description here

  5. Watch the control resize itself without permission:

    enter image description here

like image 927
Ian Boyd Avatar asked Nov 10 '22 20:11

Ian Boyd


1 Answers

When you create control, It gets initial parameters. Among them there are height and width. When you enable anchoring and resize form, the control also resizes, but initial parameters don't change. Thats why, when you remove anchoring, it gets its initial size.

like image 131
Ulphat Avatar answered Nov 15 '22 06:11

Ulphat