summaryrefslogtreecommitdiff
path: root/uidesigner/vfdwidgets.pas
diff options
context:
space:
mode:
authorGraeme Geldenhuys <graemeg@gmail.com>2014-07-21 22:59:15 +0100
committerGraeme Geldenhuys <graemeg@gmail.com>2014-07-21 22:59:15 +0100
commitbf1aa3d4983f01c0943aa188963a1dc0aa801fbc (patch)
tree65ef656d1b114270a92d9c8735651fb148a0c626 /uidesigner/vfdwidgets.pas
parent84d9c47dee2a6c27e4c8ce467fe618591104977f (diff)
downloadfpGUI-bf1aa3d4983f01c0943aa188963a1dc0aa801fbc.tar.xz
uidesigner: added togglebox widget to the palette bar
Diffstat (limited to 'uidesigner/vfdwidgets.pas')
-rw-r--r--uidesigner/vfdwidgets.pas31
1 files changed, 31 insertions, 0 deletions
diff --git a/uidesigner/vfdwidgets.pas b/uidesigner/vfdwidgets.pas
index 2238e4e5..575ae40a 100644
--- a/uidesigner/vfdwidgets.pas
+++ b/uidesigner/vfdwidgets.pas
@@ -67,6 +67,7 @@ uses
fpg_ColorWheel,
fpg_splitter,
fpg_hyperlink,
+ fpg_toggle,
vfdpropeditgrid,
vfdmain;
@@ -325,6 +326,12 @@ begin
fpgImages.AddBMP(
'vfd.scrollframe', @stdimg_vfd_scrollframe,
sizeof(stdimg_vfd_scrollframe));
+
+ fpgImages.AddMaskedBMP(
+ 'vfd.toggle', @stdimg_vfd_toggle,
+ sizeof(stdimg_vfd_toggle),
+ 0, 0);
+
end;
procedure AddWidgetPosProps(wgc: TVFDWidgetClass);
@@ -985,6 +992,30 @@ begin
wc.WidgetIconName := 'vfd.hyperlink';
RegisterVFDWidget(wc);
+ // ToggleBox
+ wc := TVFDWidgetClass.Create(TfpgToggle);
+ wc.NameBase := 'Toggle';
+ wc.AddProperty('Align', TPropertyEnum, '');
+ wc.AddProperty('Checked', TPropertyBoolean, 'Boolean value');
+ wc.AddProperty('CheckedCaption', TPropertyString, 'Initial text');
+ wc.AddProperty('CheckedColor', TPropertyColor, '');
+ wc.AddProperty('CheckedTextColor', TPropertyColor, '');
+ wc.AddProperty('Enabled', TPropertyBoolean, '');
+ wc.AddProperty('FontDesc', TPropertyFontDesc, 'The font used for displaying the text');
+ wc.AddProperty('Hint', TPropertyString, 'Tooltip hint');
+ wc.AddProperty('ParentShowHint', TPropertyBoolean, '');
+ wc.AddProperty('ShowHint', TPropertyBoolean, '');
+ wc.AddProperty('TabOrder', TPropertyInteger, 'The tab order');
+ wc.AddProperty('Text', TPropertyString, 'Initial text');
+ wc.AddProperty('TextColor', TPropertyColor, '');
+ wc.AddProperty('ToggleWidth', TPropertyInteger, 'Width of toggle button');
+ wc.AddProperty('UnCheckedCaption', TPropertyString, 'Initial text');
+ wc.AddProperty('UnCheckedColor', TPropertyColor, '');
+ wc.AddProperty('UnCheckedTextColor', TPropertyColor, '');
+ wc.AddProperty('UseAnimation', TPropertyBoolean, '');
+ wc.WidgetIconName := 'vfd.toggle';
+ RegisterVFDWidget(wc);
+
// Other - do not delete!!! this should be the last...
wc := TVFDWidgetClass.Create(TOtherWidget);
wc.NameBase := 'Custom';