Recent

Author Topic: TRadioGroup / TCheckGroup Questions  (Read 3361 times)

bzman24

  • Jr. Member
  • **
  • Posts: 71
TRadioGroup / TCheckGroup Questions
« on: January 29, 2015, 05:00:11 am »
Hello,

Question 1: Is there a way to change the border color of the TRadioGroup / TCheckGroup components?

Question 2: Can I change the border width of the TRadioGroup / TCheckGroup components like I can in TPanel (It's called bevel width there)?

It looks like I can change the border widths in the Border Spacing properties of each one but nothing shows differently when I change any of the numbers there.  Maybe this is not to change the border size.

Any help on this would be appreciated.

Thanks,  BZMan
==============
OS: Win7 - i5 - win64
Linux Mint 17.3
Lazarus: V1.8.2 / FPC - 3.0.4

howardpc

  • Hero Member
  • *****
  • Posts: 4144
Re: TRadioGroup / TCheckGroup Questions
« Reply #1 on: January 29, 2015, 11:53:49 am »
BorderSpacing is not a property that affects how the borders of a control are displayed.
It is a layout property, used to increase or decrease the spacing between borders of adjacent controls (rather like the "leading" between lines of text).
You can set a design-time option that shows the extent of the BorderSpacing of a control (Tools->Options->Environment->Form Editor, in the Grid groupbox check the "Show border spacing" checkbox: this will then display a red outline -- only at design-time -- indicating where the edges of the control are situated).

The LCL controls that are based on TGroupBox all use the underlying OS widget for their drawing, and so you are restricted to what the current OS theme provides. To change e.g. colours or borderwidths your OS might offer a way to tweak the theme you use. However, many OSs set default values which are hard or impossible to change. For example Windows does not permit changes to most widget properties unless you choose the Classic theme. Instead it offers the user choices between various themes. That is why the BorderWidth property has no effect: any value you set is ignored by the underlying OS, which is responsible for the display of the widget.
People who dislike being limited by an OS theme in this way go the custom drawn route (use the LCL CD components or a library such as fpGUI, or some other alternative to the LCL).
« Last Edit: January 29, 2015, 11:55:47 am by howardpc »

bzman24

  • Jr. Member
  • **
  • Posts: 71
Re: TRadioGroup / TCheckGroup Questions
« Reply #2 on: January 30, 2015, 01:51:48 am »
"(use the LCL CD components or a library such as fpGUI, or some other alternative to the LCL)."

Where do I find the LCL CD components?  I see nothing labeled as such and can't find any mention in the Lazarus documents.  I found the fpGUI and will see if it does what I need.

Thanks,  BZman
==============
OS: Win7 - i5 - win64
Linux Mint 17.3
Lazarus: V1.8.2 / FPC - 3.0.4

Fred vS

  • Hero Member
  • *****
  • Posts: 3168
    • StrumPract is the musicians best friend
Re: TRadioGroup / TCheckGroup Questions
« Reply #3 on: January 30, 2015, 02:38:32 am »
Quote
Where do I find the LCL CD components
=> LCL CustomDrawn widget-set. => http://forum.lazarus.freepascal.org/index.php/board,51.0.html

Quote
I found the fpGUI and will see if it does what I need
=> https://github.com/graemeg/fpgui/tree/develop

Fre;D

« Last Edit: January 30, 2015, 02:44:50 am by Fred vS »
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

 

TinyPortal © 2005-2018