diff options
author | Graeme Geldenhuys <graeme@mastermaths.co.za> | 2011-05-06 00:09:49 +0200 |
---|---|---|
committer | Graeme Geldenhuys <graeme@mastermaths.co.za> | 2011-05-06 00:09:49 +0200 |
commit | fc9b564011e699133fe1301b5088cb362e7cb6b0 (patch) | |
tree | 5ff6081a2511bd302f2a60fb789484c25a7a2be9 | |
parent | 7f2a1ba73eea231189cf75b59cd45a5b6edae2e6 (diff) | |
download | fpGUI-fc9b564011e699133fe1301b5088cb362e7cb6b0.tar.xz |
Just grouped the methods of TfpgStyle based on functionality and widgets.
This is basically just some code formatting changes, making it easier for
a developer to see what style methods related to what widgets - that's if
the method names was not obvious enough. ;-)
-rw-r--r-- | src/corelib/fpg_main.pas | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/corelib/fpg_main.pas b/src/corelib/fpg_main.pas index cefe9215..d6dc7410 100644 --- a/src/corelib/fpg_main.pas +++ b/src/corelib/fpg_main.pas @@ -203,22 +203,25 @@ type MenuDisabledFont: TfpgFont; constructor Create; virtual; destructor Destroy; override; - procedure DrawButtonFace(ACanvas: TfpgCanvas; x, y, w, h: TfpgCoord; AFlags: TFButtonFlags); virtual; overload; - procedure DrawButtonFace(ACanvas: TfpgCanvas; r: TfpgRect; AFlags: TFButtonFlags); overload; + { General } procedure DrawControlFrame(ACanvas: TfpgCanvas; x, y, w, h: TfpgCoord); virtual; overload; procedure DrawControlFrame(ACanvas: TfpgCanvas; r: TfpgRect); overload; + function GetControlFrameBorders: TRect; virtual; procedure DrawBevel(ACanvas: TfpgCanvas; x, y, w, h: TfpgCoord; ARaised: Boolean = True); virtual; procedure DrawDirectionArrow(ACanvas: TfpgCanvas; x, y, w, h: TfpgCoord; direction: TArrowDirection); virtual; procedure DrawString(ACanvas: TfpgCanvas; x, y: TfpgCoord; AText: string; AEnabled: boolean = True); virtual; procedure DrawFocusRect(ACanvas: TfpgCanvas; r: TfpgRect); virtual; + { Buttons } + procedure DrawButtonFace(ACanvas: TfpgCanvas; x, y, w, h: TfpgCoord; AFlags: TFButtonFlags); virtual; overload; + procedure DrawButtonFace(ACanvas: TfpgCanvas; r: TfpgRect; AFlags: TFButtonFlags); overload; + function GetButtonBorders: TRect; virtual; + function GetButtonShift: TPoint; virtual; + { Menus } procedure DrawMenuBar(ACanvas: TfpgCanvas; r: TfpgRect; ABackgroundColor: TfpgColor); virtual; procedure DrawMenuRow(ACanvas: TfpgCanvas; r: TfpgRect; AFlags: TfpgMenuItemFlags); virtual; procedure DrawMenuItem(ACanvas: TfpgCanvas; r: TfpgRect; AFlags: TfpgMenuItemFlags; AText: TfpgString); virtual; procedure DrawMenuItemSeparator(ACanvas: TfpgCanvas; r: TfpgRect); virtual; procedure DrawMenuItemImage(ACanvas: TfpgCanvas; x, y: TfpgCoord; r: TfpgRect; AFlags: TfpgMenuItemFlags); virtual; - function GetButtonBorders: TRect; virtual; - function GetButtonShift: TPoint; virtual; - function GetControlFrameBorders: TRect; virtual; function GetSeparatorSize: integer; virtual; { Editbox } procedure DrawEditBox(ACanvas: TfpgCanvas; const r: TfpgRect; const IsEnabled: Boolean; const IsReadOnly: Boolean; const ABackgroundColor: TfpgColor); virtual; @@ -1245,16 +1248,14 @@ begin try inherited Create(AParams); - if IsInitialized then begin FScreenWidth := GetScreenWidth; FScreenHeight := GetScreenHeight; end; - except on E: Exception do - Sysutils.ShowException(ExceptObject, ExceptAddr); + SysUtils.ShowException(ExceptObject, ExceptAddr); end; end; |