diff options
author | Graeme Geldenhuys <graeme@mastermaths.co.za> | 2009-06-09 10:20:45 +0200 |
---|---|---|
committer | Graeme Geldenhuys <graeme@mastermaths.co.za> | 2009-06-09 10:20:45 +0200 |
commit | 675b6a722af721784838358e3f375b8dd8745969 (patch) | |
tree | 89313043cc748df73b3234274b8efaba9f37d5b2 /uidesigner/vfdfile.pas | |
parent | 435bac31bc0bea6c05fc16883c7937c724d8eec2 (diff) | |
download | fpGUI-675b6a722af721784838358e3f375b8dd8745969.tar.xz |
UIDesigner copyright and code folding
* updated all copyright notices in UI Designer code.
* New Forms now only have the fpg_forms unit in uses clause. This
help with smartlinking and reduces executable size.
* New Forms now include the code folding region around auto-generated
GUI code from UI Designer. This feature works in newer Lazarus
revisions, but will not affect older versions.
Diffstat (limited to 'uidesigner/vfdfile.pas')
-rw-r--r-- | uidesigner/vfdfile.pas | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/uidesigner/vfdfile.pas b/uidesigner/vfdfile.pas index 2c63890a..9928d28a 100644 --- a/uidesigner/vfdfile.pas +++ b/uidesigner/vfdfile.pas @@ -1,7 +1,7 @@ { fpGUI - Free Pascal GUI Toolkit - Copyright (C) 2006 - 2008 See the file AUTHORS.txt, included in this + Copyright (C) 2006 - 2009 See the file AUTHORS.txt, included in this distribution, for details of the copyright. See the file COPYING.modifiedLGPL, included in this distribution, @@ -83,12 +83,13 @@ var s: string; begin s := - ' T' + formname + ' = class(TfpgForm)' + LineEnding + - ' public' + LineEnding + - ' {@VFD_HEAD_BEGIN: ' + formname + '}' + LineEnding + - formheadblock + - ' {@VFD_HEAD_END: ' + formname + '}' + LineEnding + - ' procedure AfterCreate; override;' + LineEnding + ' T' + formname + ' = class(TfpgForm)' + LineEnding + + ' private' + LineEnding + + ' {@VFD_HEAD_BEGIN: ' + formname + '}' + LineEnding + + formheadblock + + ' {@VFD_HEAD_END: ' + formname + '}' + LineEnding + + ' public' + LineEnding + + ' procedure AfterCreate; override;' + LineEnding + ' end;' + LineEnding + LineEnding; NewFormsDecl := NewFormsDecl + s; end; @@ -100,9 +101,11 @@ begin s := LineEnding + LineEnding + 'procedure T' + formname + '.AfterCreate;' + LineEnding + 'begin' + LineEnding + + ' {%region ''Auto-generated GUI code'' -fold}' + LineEnding + ' {@VFD_BODY_BEGIN: ' + formname + '}' + LineEnding + formbody + ' {@VFD_BODY_END: ' + formname + '}' + LineEnding + + ' {%endregion}' + LineEnding + 'end;' + LineEnding; NewFormsImpl := NewFormsImpl + s; end; @@ -351,12 +354,7 @@ begin '{$mode objfpc}{$H+}' + LineEnding + LineEnding + 'interface' + LineEnding + LineEnding + 'uses' + LineEnding + - ' SysUtils, Classes, fpg_base, fpg_main, fpg_widget,' + LineEnding + - ' fpg_edit, fpg_form, fpg_label, fpg_button,' + LineEnding + - ' fpg_listbox, fpg_memo, fpg_combobox, fpg_basegrid, fpg_grid, ' + LineEnding + - ' fpg_dialogs, fpg_checkbox, fpg_tree, fpg_trackbar, ' + LineEnding + - ' fpg_progressbar, fpg_radiobutton, fpg_tab, fpg_menu,' + LineEnding + - ' fpg_panel, fpg_popupcalendar, fpg_gauge;' + LineEnding + LineEnding + + ' SysUtils, Classes, fpg_base, fpg_main, fpg_form;' + LineEnding + LineEnding + 'type' + LineEnding + LineEnding + '{@VFD_NEWFORM_DECL}' + LineEnding + LineEnding + 'implementation' + LineEnding + LineEnding + |