TBitBtn ignores the Margin property on Windows
Original Reporter info from Mantis: wp @wpam
-
Reporter name:
Original Reporter info from Mantis: wp @wpam
- Reporter name:
Description:
Positioning of glyph and caption of a TBitBtn can be constrolled by the properties Margin and Spacing.
In Delphi, Margin is the distance between edge of the TBitBtn and the icon unless Margin is -1 which centers the icon/caption, and Spacing is the distance between the icon and the caption unless Spacing is -1 - then the caption is centered within the space following the icon.
In Lazarus in Windows, however, Margin seems to be ignored: Whatever value is assigned to Margin the layout of glyph and caption does not change. In Linux (gtk2, qt), however, Margin behaves more or less like in Delphi.
Steps to reproduce:
The provided demo shows several instances of TBitBtn with various combinations of Margin and Spacing. This is from which the attached screenshots were generated.
Additional information:
This seems to be a very old issue, it is already seen in Laz 1.0 (or maybe even older).
This report is based on a forum post: https://forum.lazarus.freepascal.org/index.php/topic,42768.msg298755
Mantis conversion info:
- Mantis ID: 34379
- Platform: windows
- Fixed in revision: r59270 (#37f0823e)
- Monitored by: » OLLI_S (Oliver Sahr)
- Target version: 1.10