diff options
author | Graeme Geldenhuys <graemeg@users.sourceforge.net> | 2007-05-09 08:44:53 +0000 |
---|---|---|
committer | Graeme Geldenhuys <graemeg@users.sourceforge.net> | 2007-05-09 08:44:53 +0000 |
commit | b7bfa629a9f5e19392cc1e2de9d3bfd54213f1bd (patch) | |
tree | 54e603a6415c1a5f23cc12e2843c10ca48277097 /gui | |
parent | 6921b4509c2a185a4cfda797d92cc293343c3a08 (diff) | |
download | fpGUI-b7bfa629a9f5e19392cc1e2de9d3bfd54213f1bd.tar.xz |
* Radio buttons can now be drawn as disabled under Linux. This is still a work-around imprementation until the palette issue is fixed in GFX/X11
Diffstat (limited to 'gui')
-rw-r--r-- | gui/fpguistyle.inc | 46 |
1 files changed, 34 insertions, 12 deletions
diff --git a/gui/fpguistyle.inc b/gui/fpguistyle.inc index a6bdecd5..af04cfed 100644 --- a/gui/fpguistyle.inc +++ b/gui/fpguistyle.inc @@ -703,22 +703,44 @@ begin InflateRect(r, -2, -2); Canvas.DrawCircle(r); - SetUIColor(Canvas, cl3DDkShadow); + if cbIsEnabled in Flags then + SetUIColor(Canvas, cl3DDkShadow) + else + SetUIColor(Canvas, cl3DShadow); InflateRect(r, 1, 1); Canvas.DrawCircle(r); - if cbIsChecked in Flags then + if cbIsEnabled in Flags then begin - SetUIColor(Canvas, clNavy); - InflateRect(r, -3, -3); - Canvas.DrawCircle(r); - InflateRect(r, -1, -1); - Canvas.FillRect(r); - InflateRect(r, 1, 1); - SetUIColor(Canvas, clSkyBlue); - InflateRect(r, -2, -2); - OffsetRect(r, -1, -1); - Canvas.FillRect(r); + if cbIsChecked in Flags then + begin + SetUIColor(Canvas, clNavy); + InflateRect(r, -3, -3); + Canvas.DrawCircle(r); + InflateRect(r, -1, -1); + Canvas.FillRect(r); + InflateRect(r, 1, 1); + SetUIColor(Canvas, clSkyBlue); + InflateRect(r, -2, -2); + OffsetRect(r, -1, -1); + Canvas.FillRect(r); + end; + end + else + begin + if cbIsChecked in Flags then + begin + SetUIColor(Canvas, cl3DShadow); + InflateRect(r, -3, -3); + Canvas.DrawCircle(r); + InflateRect(r, -1, -1); + Canvas.FillRect(r); + InflateRect(r, 1, 1); + SetUIColor(Canvas, clLtGray); + InflateRect(r, -2, -2); + OffsetRect(r, -1, -1); + Canvas.FillRect(r); + end; end; {$ENDIF} |