2014-01-21

The Debugger:

← Older revision

Revision as of 02:58, 21 January 2014

(One intermediate revision by one user not shown)

Line 453:

Line 453:

 

“查看单元”、“查看窗体”、“运行”、“暂停”、“步进”、“下一步”、“运行,直到函数返回”。

 

“查看单元”、“查看窗体”、“运行”、“暂停”、“步进”、“下一步”、“运行,直到函数返回”。

 

 



==
The Component Palette
==

+

==
组件面板
==



A Tabbed toolbar which displays a large number of icons representing commonly used components for building Forms.

+

 

 



Each tab causes the display of a different set of icons, representing a functional group of components.  The left-most icon in each tabbed group is an obliquely leftward-facing arrow, called the Selection Tool.

+

标签式工具栏里显示常用组件图标。

 

 



If you allow the mouse cursor to hover over any of the icons on the Component Palette, without clicking on the icon, the title of that component will pop-up.  Note that each title begins with a 'T' - this signifies 'Type' or more accurately 'Class' of the component.  When you select a component for inclusion in a form, the Class is added to the '''type''' section of the '''interface''' part of the Unit (usually as part of the overall TForm1), and an '''instance''' of that class is added to the '''var''' section (usually as the variable Form1).  Any '''Methods''' that you design to be used by the Form or its Components (ie Procedures or Functions) will be placed in the '''implementation''' part of the Unit

+

每个选项卡使用一组不同的图标显示,选项卡组最左边的第一个图片(指向箭头),称为选择工具。

 

 



In the following list of the Components, you will find links to files that contain descriptions of the Units in which they are found.  If you want to find out about the properties of a particular component, it is often worth looking at the Inheritance of that component and then inspecting the properties of the base type from which it is derived.  For example, to understand TMaskEdit it is also useful to examine TCustomMaskEdit.

+

如果你将鼠标悬停在组件面板中的图标上,将会显示该组件的提示信息。T意味着,Type类型,或者是Class组件。在窗体中,使用组件时,类将会添加到类型和接口处(通常作为TForm1一部分)。实例化处,添加到VAR部分(通常作为Form1变量)。任何方法,设计时要使用窗体或组件(程序或函数),将被放置在implementation部分。如果你要找出某一特定组件的属性,可以看组件的继承,之后检查其派生的基类型的属性。例如,你要了解TMaskEdit,可以查看TcustomMaskEdit。

 

   

 

   



'''
TABS
'''
(the names are largely self-explanatory):

+

'''
选项卡
'''
(通过名称可以了解的其包含了哪些组件):



* '''[http://lazarus-ccr.sourceforge.net/index.php?wiki=StdCtrls
Standard
]'''

+

* '''[http://lazarus-ccr.sourceforge.net/index.php?wiki=StdCtrls
标准组件
]'''

 

<center>[[Image:Component_Palette_Standart.png]]</center>

 

<center>[[Image:Component_Palette_Standart.png]]</center>



:''
Frequently used components:
'' [http://lazarus-ccr.sourceforge.net/docs/lcl/menus/tmainmenu.html TMainMenu], [http://lazarus-ccr.sourceforge.net/docs/lcl/menus/tpopupmenu.html TPopupMenu], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tbutton.html TButton], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tlabel.html TLabel], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tedit.html TEdit], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tmemo.html TMemo], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/ttogglebox.html TToggleBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tcheckbox.html TCheckBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tradiobutton.html TRadioButton], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tlistbox.html TListBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tcombobox.html TComboBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tscrollbar.html TScrollBar], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tgroupbox.html TGroupBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tstatictext.html TStaticText], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tradiogroup.html TRadioGroup], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tcheckgroup.html TCheckGroup], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tpanel.html TPanel], [http://lazarus-ccr.sourceforge.net/docs/lcl/actnlist/tactionlist.html TActionList]

+

:''
通常使用的组件:
'' [http://lazarus-ccr.sourceforge.net/docs/lcl/menus/tmainmenu.html TMainMenu], [http://lazarus-ccr.sourceforge.net/docs/lcl/menus/tpopupmenu.html TPopupMenu], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tbutton.html TButton], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tlabel.html TLabel], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tedit.html TEdit], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tmemo.html TMemo], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/ttogglebox.html TToggleBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tcheckbox.html TCheckBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tradiobutton.html TRadioButton], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tlistbox.html TListBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tcombobox.html TComboBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tscrollbar.html TScrollBar], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tgroupbox.html TGroupBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/stdctrls/tstatictext.html TStaticText], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tradiogroup.html TRadioGroup], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tcheckgroup.html TCheckGroup], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tpanel.html TPanel], [http://lazarus-ccr.sourceforge.net/docs/lcl/actnlist/tactionlist.html TActionList]



* '''[http://lazarus-ccr.sourceforge.net/index.php?wiki=ExtCtrls
Additional
]'''

+

* '''[http://lazarus-ccr.sourceforge.net/index.php?wiki=ExtCtrls
更多组件
]'''

 

<center>[[Image:Component_Palette_Additional.png]]</center>

 

<center>[[Image:Component_Palette_Additional.png]]</center>



:''
More, often-used components:
'' [http://lazarus-ccr.sourceforge.net/docs/lcl/buttons/tbitbtn.html TBitBtn], [http://lazarus-ccr.sourceforge.net/docs/lcl/buttons/tspeedbutton.html TSpeedButton], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/timage.html TImage], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tshape.html TShape], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tbevel.html TBevel], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tpaintbox.html TPaintBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tnotebook.html TNotebook], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tlabelededit.html TLabeledEdit], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tsplitter.html TSplitter], [http://lazarus-ccr.sourceforge.net/docs/lcl/maskedit/tmaskedit.html TMaskEdit], [http://lazarus-ccr.sourceforge.net/docs/lcl/checklst/tchecklistbox.html TCheckListBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/forms/tscrollbox.html TScrollBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/forms/tapplicationproperties.html TApplicationProperties], [http://lazarus-ccr.sourceforge.net/docs/lcl/grids/tstringgrid.html TStringGrid], [http://lazarus-ccr.sourceforge.net/docs/lcl/grids/tdrawgrid.html TDrawGrid], [http://lazarus-ccr.sourceforge.net/docs/lcl/pairsplitter/tpairsplitter.html TPairSplitter]

+

:''
更多经常使用的组件:
'' [http://lazarus-ccr.sourceforge.net/docs/lcl/buttons/tbitbtn.html TBitBtn], [http://lazarus-ccr.sourceforge.net/docs/lcl/buttons/tspeedbutton.html TSpeedButton], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/timage.html TImage], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tshape.html TShape], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tbevel.html TBevel], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tpaintbox.html TPaintBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tnotebook.html TNotebook], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tlabelededit.html TLabeledEdit], [http://lazarus-ccr.sourceforge.net/docs/lcl/extctrls/tsplitter.html TSplitter], [http://lazarus-ccr.sourceforge.net/docs/lcl/maskedit/tmaskedit.html TMaskEdit], [http://lazarus-ccr.sourceforge.net/docs/lcl/checklst/tchecklistbox.html TCheckListBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/forms/tscrollbox.html TScrollBox], [http://lazarus-ccr.sourceforge.net/docs/lcl/forms/tapplicationproperties.html TApplicationProperties], [http://lazarus-ccr.sourceforge.net/docs/lcl/grids/tstringgrid.html TStringGrid], [http://lazarus-ccr.sourceforge.net/docs/lcl/grids/tdrawgrid.html TDrawGrid], [http://lazarus-ccr.sourceforge.net/docs/lcl/pairsplitter/tpairsplitter.html TPairSplitter]



* '''[http://lazarus-ccr.sourceforge.net/index.php?wiki=ComCtrls
Common Controls
]'''

+

* '''[http://lazarus-ccr.sourceforge.net/index.php?wiki=ComCtrls
公共组件
]'''

 

<center>[[Image:Component_Palette_Common_Controls.png]]</center>

 

<center>[[Image:Component_Palette_Common_Controls.png]]</center>

 

: TTrackBar, TProgressBar, TTreeView, TListView, TStatusBar, TToolBar, TUpDown, TPageControl, TImageList

 

: TTrackBar, TProgressBar, TTreeView, TListView, TStatusBar, TToolBar, TUpDown, TPageControl, TImageList



* '''[http://lazarus-ccr.sourceforge.net/index.php?wiki=DialogsTxt
Dialogs
]'''

+

* '''[http://lazarus-ccr.sourceforge.net/index.php?wiki=DialogsTxt
对话框组件
]'''

 

<center>[[Image:Component_Palette_Dialogs.png]]</center>

 

<center>[[Image:Component_Palette_Dialogs.png]]</center>

 

: TOpenDialog, TSaveDialog, TSelectDirectoryDialog, TColorDialog, TFontDialog, TOpenPictureDialog, TSavePictureDialog, TCalendarDialog, TCalculatorDialog

 

: TOpenDialog, TSaveDialog, TSelectDirectoryDialog, TColorDialog, TFontDialog, TOpenPictureDialog, TSavePictureDialog, TCalendarDialog, TCalculatorDialog

 

 



Several useful
'''[http://lazarus-ccr.sourceforge.net/index.php?wiki=DialogExamples
Dialog
]'''
procedures or functions don't appear on the Palette, but are easily used as direct calls from your source program.

+

有几个有用的
'''[http://lazarus-ccr.sourceforge.net/index.php?wiki=DialogExamples
对话框
]'''
,它不在组件面板中显示,但在你可在过程函数中直接调用。

 

 



For several good examples of the use of Components see the
$LazarusPath/lazarus/
examples subdirectory of your source installation.  Many of the programs show how to use dialogs and other components directly without using the IDE and component palette or having a separate form definition file:  all the components are fully and explicitly defined in the main Pascal program.  Other example programs make full use of the IDE.

+

有关组件使用的例子,请参看
$LazarusPath/lazarus/
examples目录。许多程序不使用IDE组件而直接使用对话框或其他组件的调色板,或者有一个单独的窗体定义文件:所有组件中,在Pascal主程序部分定义使用。

 

 



Some examples don't work straight away: you may need to play about with paths and permissions of files or directories.  If you want to compile any of the examples, make sure that you have read/write/execute permissions for the files and directories, or copy the files to a directory where you do have the appropriate permissions.

 

 

 



Try running the
'
testall
'
program to see a menu of the available components together with small example test forms for most of them;  then inspect the code to find out how they work!

+

一些示例,不马上使用的:你可能需要调整路径和文件(目录)的执行权限。如果你想直接编译示例,请确保对文件(目录)具有读取/写入/执行权限。



* '''
Misc
'''

+

 

 

+

请尝试运行
''
'testall程序''',以查看可用组件和示例菜单,大多数的测试,可以确定你的环境是否能够正常使用这些组件!

 

+

 

 

+

* '''
杂项组件
'''

 

<center>[[Image:Component_Palette_Misc.png]]</center>

 

<center>[[Image:Component_Palette_Misc.png]]</center>

 

: [http://lazarus-ccr.sourceforge.net/index.php?wiki=DialogsTxt TColorButton], TSpinEdit, TArrow, TCalendar, TEditButton, TFileNameEdit, TDirectoryEdit, TDateEdit, TCalcEdit, TFileListBox  

 

: [http://lazarus-ccr.sourceforge.net/index.php?wiki=DialogsTxt TColorButton], TSpinEdit, TArrow, TCalendar, TEditButton, TFileNameEdit, TDirectoryEdit, TDateEdit, TCalcEdit, TFileListBox  



* '''
Data Controls
'''

+

* '''
数据组件
'''

 

<center>[[Image:Component_Palette_DataControls.png]]</center>

 

<center>[[Image:Component_Palette_DataControls.png]]</center>



: ''
Data-aware components, which largely replicate the Standard and Additional groups but are applicable to Databases:
'' TDBNavigation, TDBText, TDBEdit, TDBMemo, TDBImage, TDBListBox,TDBComboBox, TDBCheckBox, TDBRadioGroup, TDBCalendar, TDBGroupBox, TdbGrid

+

: ''
数据组件,通常用于数据库:
'' TDBNavigation, TDBText, TDBEdit, TDBMemo, TDBImage, TDBListBox,TDBComboBox, TDBCheckBox, TDBRadioGroup, TDBCalendar, TDBGroupBox, TdbGrid



* '''
Data Access
'''

+

* '''
数据访问组件
'''

 

<center>[[Image:Component_Palette_DataAccess.png]]</center>

 

<center>[[Image:Component_Palette_DataAccess.png]]</center>

 

: TDatasource

 

: TDatasource



* '''
[[System]]
'''

+

* '''
系统组件
'''

 

<center>[[Image:Component_Palette_System.png]]</center>

 

<center>[[Image:Component_Palette_System.png]]</center>

 

: [http://lazarus-ccr.sourceforge.net/index.php?wiki=ExtCtrls#TTimer TTimer], TIdleTimer, [[doc:fcl/process/tprocess.html|TProcess]]

 

: [http://lazarus-ccr.sourceforge.net/index.php?wiki=ExtCtrls#TTimer TTimer], TIdleTimer, [[doc:fcl/process/tprocess.html|TProcess]]



* '''
SynEdit
'''

+

* '''
SynEdit(<strike>编辑器组件</strike>)
'''

 

<center>[[Image:Component_Palette_SynEdit.png]]</center>

 

<center>[[Image:Component_Palette_SynEdit.png]]</center>



: ''A group of components to help interfacing with other languages and software tools. SynEdit is an advanced multi-line edit control, for Borland Delphi, Kylix  and C++Builder. It supports Syntax Highlighting and code completion, and includes exporters for html, tex and rtf. It is a full-VCL/CLX control, meaning it is not a wrapper for Microsoft Windows controls, and no run-time library is required; this make SynEdit a crossplatform component. Compatibility with FreePascal is also planned, and SynEdit is the edit component in Lazarus IDE.'' see [http://synedit.sourceforge.net synedit at sourceforge]. TSynEdit, TSynAutoComplete, TSynExporterHTML, TSynMacroRecorder, TSynMemo, TSynPasSyn, TSynCppSyn, TSynJavaSyn, TSynPerlSyn, TSynHTMLSyn, TSynXMLSyn, TSynLFMSyn, TSynUNIXShellScriptSyn, TSynCssSyn, TSynPHPSyn, TSynTeXSyn, TSynSQLSyn, TSynMultiSyn

 

 

 



To use the Palette, there must be an open form on view in the editor (if there isn
'
t one, select File -> New Form)
.
Click on the icon in the appropriate tab of the Palette for the component you want to use
,
then click on the Form
,
near where you want the component to appear.  When the desired component appears
,
you can select it by clicking with the mouse
,
then move it to the exact place on the Form where you want it and adjust its size.  Adjustments can be made to the appearance either by altering the picture itself on the Form using the mouse
,
or by changing the relevant Property in the Object Editor for that component.

+

:
'
'SynEdit是一个高级的文本编辑器控制,对Borland的Delphi,Kylix、C++Builder等支持语法高亮和代码自动完成,并支持输出为HTML、Tex和RTF。这是一个VCL/CLX控件,意味着,适用于Microsoft的Windows,没有信赖的运行库,SynEdit作为跨平台组件,也是Lazarus IDE中的编辑器组件。'' 查看 [http://synedit
.
sourceforge.net sourceforge上的synedit]. TSynEdit
,
TSynAutoComplete
,
TSynExporterHTML
,
TSynMacroRecorder
,
TSynMemo
,
TSynPasSyn, TSynCppSyn, TSynJavaSyn, TSynPerlSyn, TSynHTMLSyn, TSynXMLSyn, TSynLFMSyn, TSynUNIXShellScriptSyn, TSynCssSyn, TSynPHPSyn, TSynTeXSyn, TSynSQLSyn, TSynMultiSyn

 

+

 

 

+

要使用调色板,必须存在窗体(如果没有,选择文件->新建窗体)。单击调色板中需要使用的控件,在窗体上单击,这时候,窗体上,将显示出来调色板组件;你可以调整它到合适的位置,通过属性可以显示外观。

 

 



If you install additional components, either those you have written yourself, or some coming as a package from some other source, then extra tabs with the relevant icons will appear in your Component Palette. These new components can be selected and used on your forms in the same way as those supplied by default.

+

如果你想安装额外的组件,无论是你自己编写的,还是第三方的;完成后,将在组件面板中显示出来。

 

 



==
The Debugger
==

+

==
调试器
==



:
''
Still to be written
''
.

+


''
待写
''


 

 



see also
[[:category: IDE Window - Debug]]

+

更多
[[:category: IDE Window - Debug]]

 

 

 

== The Lazarus files ==

 

== The Lazarus files ==

Show more