diff --git a/.gitattributes b/.gitattributes index 6c4481da60..a33e5555bc 100644 --- a/.gitattributes +++ b/.gitattributes @@ -642,7 +642,9 @@ examples/barchart/frmmain.lfm svneol=native#text/plain examples/barchart/frmmain.lrs svneol=native#text/pascal examples/barchart/frmmain.pas svneol=native#text/pascal examples/bitbtnform.pp svneol=native#text/pascal +examples/bitbutton.lpi svneol=native#text/plain examples/bitbutton.pp svneol=native#text/pascal +examples/checkbox.lpi svneol=native#text/plain examples/checkbox.pp svneol=native#text/pascal examples/codepageconverter/codepages.ini svneol=native#text/plain examples/codepageconverter/filefind/filefind.lrs svneol=native#text/pascal @@ -660,7 +662,9 @@ examples/codepageconverter/mainunit.lrt svneol=native#text/plain examples/codepageconverter/mainunit.pas svneol=native#text/pascal examples/codepageconverter/mainunit.po svneol=native#text/plain examples/codepageconverter/mainunit.ru_RU.UTF-8.po svneol=native#text/plain +examples/combobox.lpi svneol=native#text/plain examples/combobox.pp svneol=native#text/pascal +examples/comdialogs.lpi svneol=native#text/plain examples/comdialogs.pp svneol=native#text/pascal examples/dlgform.pp svneol=native#text/pascal examples/easter/about.lfm svneol=native#text/plain @@ -671,6 +675,7 @@ examples/easter/holyday.lpr svneol=native#text/pascal examples/easter/main.lfm svneol=native#text/plain examples/easter/main.lrs svneol=native#text/pascal examples/easter/main.pas svneol=native#text/pascal +examples/edittest.lpi svneol=native#text/plain examples/edittest.pp svneol=native#text/pascal examples/grid_semaphor/TSemaphorDBGrid.xpm -text svneol=native#image/x-xpixmap examples/grid_semaphor/example/project1.lpi svneol=native#text/plain @@ -690,7 +695,9 @@ examples/grid_semaphor/semaphorgridlpk.pas svneol=native#text/pascal examples/grid_semaphor/semaphorgrids.pas svneol=native#text/pascal examples/grid_semaphor/semaphorgridsicon.lrs svneol=native#text/pascal examples/grid_semaphor/tsemaphorgrid.xpm -text svneol=native#image/x-xpixmap +examples/groupbox.lpi svneol=native#text/plain examples/groupbox.pp svneol=native#text/pascal +examples/groupboxnested.lpi svneol=native#text/plain examples/groupboxnested.pas svneol=native#text/pascal examples/gtkglarea/data/particle.bmp -text svneol=unset#image/bmp examples/gtkglarea/data/texture1.bmp -text svneol=unset#image/bmp @@ -699,6 +706,7 @@ examples/gtkglarea/data/texture3.bmp -text svneol=unset#image/bmp examples/gtkglarea/exampleform.pp svneol=native#text/pascal examples/gtkglarea/gtkglarea_demo.lpi svneol=native#text/plain examples/gtkglarea/gtkglarea_demo.pp svneol=native#text/pascal +examples/hello.lpi svneol=native#text/plain examples/hello.pp svneol=native#text/pascal examples/helloform.pp svneol=native#text/pascal examples/imgviewer/file.bmp -text svneol=native#image/bmp @@ -716,17 +724,24 @@ examples/lazintfimage/fadein1.lpr svneol=native#text/pascal examples/lazintfimage/mainunit1.lfm svneol=native#text/plain examples/lazintfimage/mainunit1.lrs svneol=native#text/pascal examples/lazintfimage/mainunit1.pas svneol=native#text/pascal +examples/listboxtest.lpi svneol=native#text/plain examples/listboxtest.pp svneol=native#text/pascal examples/listview/listview.lpr svneol=native#text/pascal examples/listview/testform.lfm svneol=native#text/plain examples/listview/testform.lrs svneol=native#text/pascal examples/listview/testform.pp svneol=native#text/pascal +examples/listviewtest.lpi svneol=native#text/plain examples/listviewtest.pp svneol=native#text/pascal +examples/loadpicture.lpi svneol=native#text/plain examples/loadpicture.pas svneol=native#text/pascal +examples/memotest.lpi svneol=native#text/plain examples/memotest.pp svneol=native#text/pascal +examples/messagedialogs.lpi svneol=native#text/plain examples/messagedialogs.pp svneol=native#text/pascal +examples/notebk.lpi svneol=native#text/plain examples/notebk.pp svneol=native#text/pascal examples/notebku.pp svneol=native#text/pascal +examples/notebooktest.lpi svneol=native#text/plain examples/notebooktest.pp svneol=native#text/pascal examples/objectinspector/mainunit.lfm svneol=native#text/plain examples/objectinspector/mainunit.lrs svneol=native#text/pascal @@ -738,10 +753,13 @@ examples/postscript/samplepostscriptcanvas.lpr svneol=native#text/pascal examples/postscript/usamplepostscriptcanvas.lfm svneol=native#text/plain examples/postscript/usamplepostscriptcanvas.lrs svneol=native#text/pascal examples/postscript/usamplepostscriptcanvas.pas svneol=native#text/pascal +examples/progressbar.lpi svneol=native#text/plain examples/progressbar.pp svneol=native#text/pascal +examples/scrollbar.lpi svneol=native#text/plain examples/scrollbar.pp svneol=native#text/pascal examples/selection.pp svneol=native#text/pascal examples/selectionform.pp svneol=native#text/pascal +examples/speedtest.lpi svneol=native#text/plain examples/speedtest.pp svneol=native#text/pascal examples/sprites/playground.lfm svneol=native#text/plain examples/sprites/playground.lrs svneol=native#text/pascal @@ -749,12 +767,17 @@ examples/sprites/playground.pas svneol=native#text/pascal examples/sprites/spriteexample.lpi svneol=native#text/plain examples/sprites/spriteexample.lpr svneol=native#text/pascal examples/synchronize.pp svneol=native#text/pascal +examples/synedit1.lpi svneol=native#text/plain examples/synedit1.pas svneol=native#text/pascal +examples/taborder.lpi svneol=native#text/plain examples/taborder.pas svneol=native#text/pascal +examples/testall.lpi svneol=native#text/plain examples/testall.pp svneol=native#text/pascal examples/testallform.pp svneol=native#text/pascal examples/testtools.inc svneol=native#text/pascal +examples/toolbar.lpi svneol=native#text/plain examples/toolbar.pp svneol=native#text/pascal +examples/trackbar.lpi svneol=native#text/plain examples/trackbar.pp svneol=native#text/pascal examples/treeview/TV_Add_Remove.dpr svneol=native#text/pascal examples/treeview/TV_Add_Remove.res svneol=native#unset diff --git a/examples/bitbutton.lpi b/examples/bitbutton.lpi new file mode 100644 index 0000000000..54295788f9 --- /dev/null +++ b/examples/bitbutton.lpi @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/checkbox.lpi b/examples/checkbox.lpi new file mode 100644 index 0000000000..55f6862280 --- /dev/null +++ b/examples/checkbox.lpi @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/combobox.lpi b/examples/combobox.lpi new file mode 100644 index 0000000000..e1ca0e24dd --- /dev/null +++ b/examples/combobox.lpi @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/combobox.pp b/examples/combobox.pp index 5df4e703b2..a3be02eb0f 100644 --- a/examples/combobox.pp +++ b/examples/combobox.pp @@ -35,43 +35,43 @@ uses SysUtils, Extctrls, Controls; type - TForm1 = class(TFORM) - public - Label1 : TLabel; - Label2 : TLabel; - Label3 : TLabel; - Button1: TButton; - Button2: TButton; - Button3: TButton; - Button4: TButton; - Button5: TButton; - Button6: TButton; - Button7: TButton; - Edit1 : TEdit; - mnuMain: TMainMenu; - itmFileQuit: TMenuItem; - itmFile: TMenuItem; - ComboBox1 : TComboBox; - ComboBox2 : TComboBox; - Memo1 : TMemo; - constructor Create(AOwner: TComponent); override; - procedure LoadMainMenu; - Procedure FormKill(Sender : TObject); - procedure mnuQuitClicked(Sender : TObject); - protected - procedure Button1CLick(Sender : TObject); - procedure Button2CLick(Sender : TObject); - procedure Button3CLick(Sender : TObject); - procedure Button4CLick(Sender : TObject); - procedure Button5CLick(Sender : TObject); - procedure Button6CLick(Sender : TObject); - procedure Button7CLick(Sender : TObject); - procedure ComboOnChange (Sender:TObject); - procedure ComboOnClick (Sender:TObject); - end; + TForm1 = class(TFORM) + public + Label1: TLabel; + Label2: TLabel; + Label3: TLabel; + Button1: TButton; + Button2: TButton; + Button3: TButton; + Button4: TButton; + Button5: TButton; + Button6: TButton; + Button7: TButton; + Edit1: TEdit; + mnuMain: TMainMenu; + itmFileQuit: TMenuItem; + itmFile: TMenuItem; + ComboBox1: TComboBox; + ComboBox2: TComboBox; + Memo1: TMemo; + constructor Create(AOwner: TComponent); override; + procedure LoadMainMenu; + procedure FormKill(Sender: TObject); + procedure mnuQuitClicked(Sender: TObject); + protected + procedure Button1CLick(Sender: TObject); + procedure Button2CLick(Sender: TObject); + procedure Button3CLick(Sender: TObject); + procedure Button4CLick(Sender: TObject); + procedure Button5CLick(Sender: TObject); + procedure Button6CLick(Sender: TObject); + procedure Button7CLick(Sender: TObject); + procedure ComboOnChange(Sender: TObject); + procedure ComboOnClick(Sender: TObject); + end; var -Form1 : TForm1; + Form1 : TForm1; constructor TForm1.Create(AOwner: TComponent); begin diff --git a/examples/comdialogs.lpi b/examples/comdialogs.lpi new file mode 100644 index 0000000000..bfe6d754c2 --- /dev/null +++ b/examples/comdialogs.lpi @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/edittest.lpi b/examples/edittest.lpi new file mode 100644 index 0000000000..45945a6160 --- /dev/null +++ b/examples/edittest.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/groupbox.lpi b/examples/groupbox.lpi new file mode 100644 index 0000000000..bf91362b83 --- /dev/null +++ b/examples/groupbox.lpi @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/groupboxnested.lpi b/examples/groupboxnested.lpi new file mode 100644 index 0000000000..c9dcb4a240 --- /dev/null +++ b/examples/groupboxnested.lpi @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/hello.lpi b/examples/hello.lpi new file mode 100644 index 0000000000..76d8d14ac9 --- /dev/null +++ b/examples/hello.lpi @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/listboxtest.lpi b/examples/listboxtest.lpi new file mode 100644 index 0000000000..d5d3ec1bac --- /dev/null +++ b/examples/listboxtest.lpi @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/listboxtest.pp b/examples/listboxtest.pp index eb18ec55dc..71931d6eb1 100644 --- a/examples/listboxtest.pp +++ b/examples/listboxtest.pp @@ -23,15 +23,13 @@ program ListBoxTest; {$mode objfpc}{$H+} uses - Interfaces, Buttons, Classes, Forms, StdCtrls, SysUtils, Controls{, - CListBox}; + Interfaces, Buttons, Classes, Forms, StdCtrls, SysUtils, Controls; type TListBoxTestForm = class(TForm) public Button1, Button2, Button3, Button4: TButton; ListBox: TListBox; -// ListBox: TCListBox; constructor Create(AOwner: TComponent); override; procedure Button1Click(Sender: TObject); procedure Button2Click(Sender: TObject); diff --git a/examples/listviewtest.lpi b/examples/listviewtest.lpi new file mode 100644 index 0000000000..106a9fea26 --- /dev/null +++ b/examples/listviewtest.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/loadpicture.lpi b/examples/loadpicture.lpi new file mode 100644 index 0000000000..837260b07b --- /dev/null +++ b/examples/loadpicture.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/memotest.lpi b/examples/memotest.lpi new file mode 100644 index 0000000000..dd9a1f9bb7 --- /dev/null +++ b/examples/memotest.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/messagedialogs.lpi b/examples/messagedialogs.lpi new file mode 100644 index 0000000000..472bda69bb --- /dev/null +++ b/examples/messagedialogs.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/notebk.lpi b/examples/notebk.lpi new file mode 100644 index 0000000000..160f87c8de --- /dev/null +++ b/examples/notebk.lpi @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/notebooktest.lpi b/examples/notebooktest.lpi new file mode 100644 index 0000000000..de7ae2f3e8 --- /dev/null +++ b/examples/notebooktest.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/notebooktest.pp b/examples/notebooktest.pp index f455d4b9f9..b9bd94210b 100644 --- a/examples/notebooktest.pp +++ b/examples/notebooktest.pp @@ -41,7 +41,7 @@ uses Graphics, ExtCtrls, LclProc; type - + TForm1 = class(TFORM) notebook1 : TNotebook; Button1: TButton; diff --git a/examples/progressbar.lpi b/examples/progressbar.lpi new file mode 100644 index 0000000000..e3cdf0d680 --- /dev/null +++ b/examples/progressbar.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/progressbar.pp b/examples/progressbar.pp index c70d8f7b56..7a14d7b425 100644 --- a/examples/progressbar.pp +++ b/examples/progressbar.pp @@ -3,8 +3,8 @@ progressbar - example --------------------- - Just a simple example to show & verify functionality - of the lazarus TTimer / TProgressBar classes. + Just a simple example to show & verify functionality + of the lazarus TTimer / TProgressBar classes. Initial Revision : Sun Aug 15 1999 @@ -41,36 +41,35 @@ uses type - TForm1 = class(TFORM) - public - Progre1: TProgressBar; - Timer0 : TTimer; - Button1: TButton; - Button2: TButton; - Button3: TButton; - Button4: TButton; - Button5: TButton; - Button6: TButton; - Button7: TButton; - mnuFile: TMainMenu; - itmFileQuit: TMenuItem; - constructor Create(AOwner: TComponent); override; - procedure LoadMainMenu; - procedure mnuQuitClicked(Sender : TObject); - protected - procedure Button1CLick(Sender : TObject); - procedure Button2CLick(Sender : TObject); - procedure Button3CLick(Sender : TObject); - procedure Button4CLick(Sender : TObject); - procedure Button5CLick(Sender : TObject); - procedure Button6CLick(Sender : TObject); - procedure Button7CLick(Sender : TObject); - procedure TimedOut(Sender : TObject); - end; + TForm1 = class(TFORM) + public + Progre1: TProgressBar; + Timer0 : TTimer; + Button1: TButton; + Button2: TButton; + Button3: TButton; + Button4: TButton; + Button5: TButton; + Button6: TButton; + Button7: TButton; + mnuFile: TMainMenu; + itmFileQuit: TMenuItem; + constructor Create(AOwner: TComponent); override; + procedure LoadMainMenu; + procedure mnuQuitClicked(Sender : TObject); + protected + procedure Button1CLick(Sender : TObject); + procedure Button2CLick(Sender : TObject); + procedure Button3CLick(Sender : TObject); + procedure Button4CLick(Sender : TObject); + procedure Button5CLick(Sender : TObject); + procedure Button6CLick(Sender : TObject); + procedure Button7CLick(Sender : TObject); + procedure TimedOut(Sender : TObject); + end; var -Form1 : TForm1; - + Form1 : TForm1; constructor TForm1.Create(AOwner: TComponent); diff --git a/examples/scrollbar.lpi b/examples/scrollbar.lpi new file mode 100644 index 0000000000..94d74102d1 --- /dev/null +++ b/examples/scrollbar.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/scrollbar.pp b/examples/scrollbar.pp index dea6403c8d..1b22f8bee3 100644 --- a/examples/scrollbar.pp +++ b/examples/scrollbar.pp @@ -37,26 +37,26 @@ uses SysUtils, ExtCtrls, Controls; type - TForm1 = class(TFORM) - Scrollbar1 : TScrollbar; - Button1 : TButton; - Button2 : TButton; - Button3 : TButton; - Button4 : TButton; - Procedure Button1Clicked(sender : tobject); - Procedure Button2Clicked(sender : tobject); - Procedure Button3Clicked(sender : tobject); - Procedure Button4Clicked(sender : tobject); - Procedure scrollbar1Changed(sender : tobject); - procedure Scrollbar1OnScroll(Sender: TObject; ScrollCode: TScrollCode; var ScrollPos: Integer); - public - constructor Create(AOwner: TComponent); override; - Procedure FormKill(Sender : TObject); - protected - end; + TForm1 = class(TFORM) + Scrollbar1 : TScrollbar; + Button1 : TButton; + Button2 : TButton; + Button3 : TButton; + Button4 : TButton; + Procedure Button1Clicked(sender : tobject); + Procedure Button2Clicked(sender : tobject); + Procedure Button3Clicked(sender : tobject); + Procedure Button4Clicked(sender : tobject); + Procedure scrollbar1Changed(sender : tobject); + procedure Scrollbar1OnScroll(Sender: TObject; ScrollCode: TScrollCode; var ScrollPos: Integer); + public + constructor Create(AOwner: TComponent); override; + Procedure FormKill(Sender : TObject); + protected + end; var -Form1 : TForm1; + Form1 : TForm1; constructor TForm1.Create(AOwner: TComponent); begin diff --git a/examples/speedtest.lpi b/examples/speedtest.lpi new file mode 100644 index 0000000000..ae2a961fdb --- /dev/null +++ b/examples/speedtest.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/synedit1.lpi b/examples/synedit1.lpi new file mode 100644 index 0000000000..d8d34512a4 --- /dev/null +++ b/examples/synedit1.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/taborder.lpi b/examples/taborder.lpi new file mode 100644 index 0000000000..55ebb6d7e5 --- /dev/null +++ b/examples/taborder.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/testall.lpi b/examples/testall.lpi new file mode 100644 index 0000000000..ae41172a50 --- /dev/null +++ b/examples/testall.lpi @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/toolbar.lpi b/examples/toolbar.lpi new file mode 100644 index 0000000000..db9ba46a40 --- /dev/null +++ b/examples/toolbar.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/trackbar.lpi b/examples/trackbar.lpi new file mode 100644 index 0000000000..ab67957555 --- /dev/null +++ b/examples/trackbar.lpi @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/trackbar.pp b/examples/trackbar.pp index 5c394f72bf..f333084904 100644 --- a/examples/trackbar.pp +++ b/examples/trackbar.pp @@ -3,8 +3,8 @@ trackbar - example ------------------ - Just a simple example to show & verify functionality - of the lazarus TTrackbar class. + Just a simple example to show & verify functionality + of the lazarus TTrackbar class. Initial Revision : Sun Aug 05 1999 @@ -12,7 +12,7 @@ TODO: - button "orientation" will crash the program if pressed - add a label which displays current trackbar value and is updated - by a procedure connected to "OnChange" + by a procedure connected to "OnChange" ***************************************************************************/ *************************************************************************** @@ -43,40 +43,40 @@ uses SysUtils, Controls; type - TForm1 = class(TFORM) - public - Button1: TButton; - Button2: TButton; - Button3: TButton; - Button4: TButton; - Button5: TButton; - Button6: TButton; - Button7: TButton; - Button8: TButton; - Track1 : TTRackBar; - Track2 : TTRackBar; + TForm1 = class(TFORM) + public + Button1: TButton; + Button2: TButton; + Button3: TButton; + Button4: TButton; + Button5: TButton; + Button6: TButton; + Button7: TButton; + Button8: TButton; + Track1 : TTRackBar; + Track2 : TTRackBar; mnuMain: TMainMenu; itmFile: TMenuItem; itmFileQuit: TMenuItem; - constructor Create(AOwner: TComponent); override; + constructor Create(AOwner: TComponent); override; procedure LoadMainMenu; - procedure mnuQuitClicked(Sender : TObject); - protected - procedure Button1CLick(Sender : TObject); - procedure Button2CLick(Sender : TObject); - procedure Button3CLick(Sender : TObject); - procedure Button4CLick(Sender : TObject); - procedure Button5CLick(Sender : TObject); - procedure Button6CLick(Sender : TObject); - procedure Button7CLick(Sender : TObject); - procedure Button8CLick(Sender : TObject); - procedure Track1Change(Sender : TObject); - end; + procedure mnuQuitClicked(Sender : TObject); + protected + procedure Button1CLick(Sender : TObject); + procedure Button2CLick(Sender : TObject); + procedure Button3CLick(Sender : TObject); + procedure Button4CLick(Sender : TObject); + procedure Button5CLick(Sender : TObject); + procedure Button6CLick(Sender : TObject); + procedure Button7CLick(Sender : TObject); + procedure Button8CLick(Sender : TObject); + procedure Track1Change(Sender : TObject); + end; var Form1 : TForm1; -constructor TForm1.Create(AOwner: TComponent); +constructor TForm1.Create(AOwner: TComponent); begin inherited Create(AOwner); Caption := 'TrackBar Demo v0.1'; @@ -93,9 +93,9 @@ End; procedure TForm1.Button2Click(Sender : TObject); Begin if assigned (track1) then begin - if Track1.orientation = trHorizontal - then Track1.orientation := trVertical - else Track1.orientation := trHorizontal; + if Track1.orientation = trHorizontal + then Track1.orientation := trVertical + else Track1.orientation := trHorizontal; end; End; @@ -103,7 +103,7 @@ procedure TForm1.Button3Click(Sender : TObject); Begin if assigned (Track1) then begin writeln ('Setting new position'); - Track1.Position := Track1.Position + 1; + Track1.Position := Track1.Position + 1; end; End; @@ -114,8 +114,8 @@ Begin case Track1.ScalePos of trLeft : Track1.ScalePos := trRight; trRight : Track1.ScalePos := trTop; - trTop : Track1.ScalePos := trBottom; - trBottom: Track1.ScalePos := trLeft; + trTop : Track1.ScalePos := trBottom; + trBottom: Track1.ScalePos := trLeft; end; end; End; @@ -124,7 +124,7 @@ procedure TForm1.Button5Click(Sender : TObject); Begin if assigned (Track1) then begin writeln ('Toggling ShowScalePos'); - Track1.ShowScale := not Track1.ShowScale; + Track1.ShowScale := not Track1.ShowScale; end; End; @@ -138,7 +138,7 @@ procedure TForm1.Button7Click(Sender : TObject); Begin if assigned (Track1) then begin writeln ('Incrementing LineSize'); - Track1.LineSize := Track1.LineSize + 1; + Track1.LineSize := Track1.LineSize + 1; end; End; @@ -146,7 +146,7 @@ procedure TForm1.Button8Click(Sender : TObject); Begin if assigned (Track1) then begin writeln ('Incrementing PageSize'); - Track1.PageSize := Track1.PageSize + 1; + Track1.PageSize := Track1.PageSize + 1; end; End; @@ -154,7 +154,7 @@ procedure TForm1.Track1Change(Sender : TObject); begin if assigned (Track1) then begin writeln ('*** CALLBACK ONCHANGE!!!!! ***'); - Track1.PageSize := Track1.PageSize + 1; + Track1.PageSize := Track1.PageSize + 1; end; end; @@ -162,117 +162,117 @@ end; procedure TForm1.LoadMainMenu; begin - { set the height and width } - Height := 350; - Width := 700; + { set the height and width } + Height := 350; + Width := 700; - { Setting up horizontal trackbar } - Track1 := TTrackBar.Create (Self); - Track1.Parent := Self; - Track1.Left := 50; - Track1.Top := 150; - Track1.Width := 140; - Track1.Height := 140; - Track1.Min := 0; - Track1.Max := 100; - Track1.OnChange := @Track1Change; - Track1.Show; + { Setting up horizontal trackbar } + Track1 := TTrackBar.Create (Self); + Track1.Parent := Self; + Track1.Left := 50; + Track1.Top := 150; + Track1.Width := 140; + Track1.Height := 140; + Track1.Min := 0; + Track1.Max := 100; + Track1.OnChange := @Track1Change; + Track1.Show; - { Setting up vertical trackbar } - Track2 := TTrackBar.Create (Self); - Track2.Parent := Self; - Track2.Orientation := trVertical; - Track2.Left := 500; - Track2.Top := 150; - Track2.Width := 20; - Track2.Height := 100; - Track2.Min := 0; - Track2.Max := 100; - Track2.Show; + { Setting up vertical trackbar } + Track2 := TTrackBar.Create (Self); + Track2.Parent := Self; + Track2.Orientation := trVertical; + Track2.Left := 500; + Track2.Top := 150; + Track2.Width := 20; + Track2.Height := 100; + Track2.Min := 0; + Track2.Max := 100; + Track2.Show; - { create some buttons to change trackbar properties } - Button2 := TButton.Create(Self); - button2.Parent := Self; - Button2.Left := 200; - Button2.Top := 30; - Button2.Width := 100; - Button2.Height := 30; - Button2.Caption := 'Orientation'; - Button2.OnClick := @Button2Click; - Button2.Show; + { create some buttons to change trackbar properties } + Button2 := TButton.Create(Self); + button2.Parent := Self; + Button2.Left := 200; + Button2.Top := 30; + Button2.Width := 100; + Button2.Height := 30; + Button2.Caption := 'Orientation'; + Button2.OnClick := @Button2Click; + Button2.Show; - Button1 := TButton.Create(Self); - button1.Parent := Self; - Button1.Left := 200; - Button1.Top := 70; - Button1.Width := 100; - Button1.Height := 30; - Button1.Caption := 'Max++'; - Button1.OnClick := @Button1Click; - Button1.Show; + Button1 := TButton.Create(Self); + button1.Parent := Self; + Button1.Left := 200; + Button1.Top := 70; + Button1.Width := 100; + Button1.Height := 30; + Button1.Caption := 'Max++'; + Button1.OnClick := @Button1Click; + Button1.Show; - Button3 := TButton.Create(Self); - button3.Parent := Self; - Button3.Left := 200; - Button3.Top := 110; - Button3.Width := 100; - Button3.Height := 30; - Button3.Show; - Button3.Caption := 'Position++'; - Button3.OnClick := @Button3Click; + Button3 := TButton.Create(Self); + button3.Parent := Self; + Button3.Left := 200; + Button3.Top := 110; + Button3.Width := 100; + Button3.Height := 30; + Button3.Show; + Button3.Caption := 'Position++'; + Button3.OnClick := @Button3Click; - Button4 := TButton.Create(Self); - button4.Parent := Self; - Button4.Left := 350; - Button4.Top := 30; - Button4.Width := 130; - Button4.Height := 30; - Button4.Show; - Button4.Caption := 'GTK: TextPos'; - Button4.OnClick := @Button4Click; + Button4 := TButton.Create(Self); + button4.Parent := Self; + Button4.Left := 350; + Button4.Top := 30; + Button4.Width := 130; + Button4.Height := 30; + Button4.Show; + Button4.Caption := 'GTK: TextPos'; + Button4.OnClick := @Button4Click; - Button5 := TButton.Create(Self); - button5.Parent := Self; - Button5.Left := 350; - Button5.Top := 70; - Button5.Width := 130; - Button5.Height := 30; - Button5.Show; - Button5.Caption := 'GTK: Show Text'; - Button5.OnClick := @Button5Click; + Button5 := TButton.Create(Self); + button5.Parent := Self; + Button5.Left := 350; + Button5.Top := 70; + Button5.Width := 130; + Button5.Height := 30; + Button5.Show; + Button5.Caption := 'GTK: Show Text'; + Button5.OnClick := @Button5Click; - Button6 := TButton.Create(Self); - button6.Parent := Self; - Button6.Left := 350; - Button6.Top := 110; - Button6.Width := 130; - Button6.Height := 30; - Button6.Show; - Button6.Caption := '---'; - Button6.Visible := false; - Button6.OnClick := @Button6Click; + Button6 := TButton.Create(Self); + button6.Parent := Self; + Button6.Left := 350; + Button6.Top := 110; + Button6.Width := 130; + Button6.Height := 30; + Button6.Show; + Button6.Caption := '---'; + Button6.Visible := false; + Button6.OnClick := @Button6Click; - Button7 := TButton.Create(Self); - button7.Parent := Self; - Button7.Left := 200; - Button7.Top := 150; - Button7.Width := 100; - Button7.Height := 30; - Button7.Show; - Button7.Caption := 'LineSize++'; - Button7.OnClick := @Button7Click; + Button7 := TButton.Create(Self); + button7.Parent := Self; + Button7.Left := 200; + Button7.Top := 150; + Button7.Width := 100; + Button7.Height := 30; + Button7.Show; + Button7.Caption := 'LineSize++'; + Button7.OnClick := @Button7Click; - Button8 := TButton.Create(Self); - button8.Parent := Self; - Button8.Left := 350; - Button8.Top := 150; - Button8.Width := 130; - Button8.Height := 30; - Button8.Caption := 'PageSize++'; - Button8.OnClick := @Button8Click; - Button8.Show; + Button8 := TButton.Create(Self); + button8.Parent := Self; + Button8.Left := 350; + Button8.Top := 150; + Button8.Width := 130; + Button8.Height := 30; + Button8.Caption := 'PageSize++'; + Button8.OnClick := @Button8Click; + Button8.Show; - { create a menubar } + { create a menubar } mnuMain := TMainMenu.Create(Self); Menu := mnuMain;