Several controls commonly used in Lazarus forms TStatusBar - a strip along the bottom of a form for displaying information on current status

TStatusBar - a strip along the bottom of a form for displaying information on current status

The bar may consist of a single SimplePanel, in which case the displayed text is contained in SimpleText.

However if SimplePanel is false, then there can be multiple panels or sub-sections of the status bar, whose properties are described in Panels.

The property SimpleText can be assigned programatically to display the value of some variable, such as the position of the Splitter in the example

Panels - the list of strings to be placed in the sub-panels of TStatusBar

If SimplePanel is false, the contents of Panels is displayed.

Contents can be adjusted with a stringlist editor that pops up when the ellipsis (...) next to Panels in the Object Inspector is selected and allows insertion of an arbitrary number of sub-panels with their own strings

SimpleText - a character string containing the information to be displayed in the Status Bar

SimpleText - a character string containing the information to be displayed in the Status Bar

This is displayed if SimplePanel is true; otherwise the information in Panels is displayed.

SimplePanel - boolean. Is there just one continuous panel, or several sub-panels?

SimplePanel - boolean. Is there just one continuous panel, or several sub-panels?

If true, the value of SimpleText is displayed; if false, the contents of Panels is displayed.

Contents can be adjusted with a stringlist editor that pops up when the ellipsis (...) next to Panels is selected and allows insertion of an arbitrary number of sub-panels with their own strings

Set Set of constants to define the drawing stages. So far I've only seen cdPrePaint used in this unit. Set to define the DrawState TCustomDrawStateFlag consists of the following constants:
cdsSelected,
cdsGrayed,
cdsDisabled,
cdsChecked,
cdsFocused,
cdsDefault,
cdsHot,
cdsMarked,
cdsIndeterminate
A subset of TCustomDrawStateFlag TCustomDrawState determines how a item will be drawn. TListItem - the ancestor class for TCustomListView and TListView Most properties are inherited from ancestors, TPersistent and TObject Caption - the name given to this item on the list Cut this item from the list (but it can be placed on the clipboard) Pointer to the Data asociated with this item Property is true if this item has Focus The index of this item in the list (integer) The index of the image associated with this Item in the list A list of items with a cache of the last accessed item TListitems has a built-in cache of the last accessed item. This will speed up interface updates since Item.Index is often used for the same item updating more properties. If FCacheIndex = -1 then the cache is not valid. TCustomListView - the base class for TListView

TCustomListView is the base class for TListView. If you want to define your own ListView class, you should derive it from this class.

Change - Internal procedure to simulate the OnChange event

This is an internal procedure which is called after an item has been changed. It is a programmatic method for simulating the OnChange event if the programmer has assigned a method to this event.

ColClick - procedure to simulate the OnColumnClick event.

ColClick - procedure to simulate the OnColumnClick event.

Can be used programmatically to execute the same code as is used to respond to the OnColumnClick event

Columns - define and change the columns of a ListView

Columns is a TCollectionItem and contains all information on the columns of a listview.

ColumnClick - determines if the OnColumnClick event will be executed.

The ColumnClick property of the ListView enables or disables the OnColumnClick Event. A call to OnColumnClick will only be done when a method has been assigned to the OnColumnClick event and ColumnClick is set to true (default).

Items - the list of entries in the list. Held as a linked list with a cached index of the last accessed item

Items - the list of entries in the list. Held as a linked list with a cached index of the last accessed item

Items is of type TListitems which has a built-in cache of the last accessed item. This speeds up interface updates since Item.Index is often used for the same item updating more properties. If FCacheIndex = -1 then the cache is not valid.

LargeImages - an ImageList to be used in association with the list of Items

LargeImages - an ImageList to be used in association with the list of Items

A typical application might have two ImageLists: one ofLargeImages and one of SmallImages, containing two versions of the same collection of images, in large and small format; the index numbers of the first list would correspond with those in the second list.

SmallImages could be displayed beside the text strings in the list view, and the programmer would supply code to ensure that when an item with its associated SmallImage was selected, the corresponding LargeImage would be displayed in another window.

A TImageList control needs to be selected and pasted on to the Form Designer, and the ImageList Editor can be opened from the pop-up menu obtained by right-clicking on TImageList icon in the Form Designer. Then in the StringList editor for Items the correct ImageIndex must be allocated to each entry in the list.

MultiSelect - enables the selection of more than one entry from Items - by pressing SHIFT or CTRL keys while selecting ReadOnly - determines if the list can only be read, and not written or deleted. ScrollBars - the kind of scrollbars to be used: none, auto, horizontal or vertical ShowColumnHeaders - whether headers for columns are to be displayed SmallImages - an ImageList of small images (icons) to be used in association with the list of Items

SmallImages - an ImageList of small images (icons) to be used in association with the list of Items

A typical application might have two ImageLists: one ofLargeImages and one of SmallImages, containing two versions of the same collection of images, in large and small format; the index numbers of the first list would correspond with those in the second list.

SmallImages could be displayed beside the text strings in the list view, and the programmer would supply code to ensure that when an item with its associated SmallImage was selected, the corresponding LargeImage would be displayed in another window.

A TImageList control needs to be selected and pasted on to the Form Designer, and the ImageList Editor can be opened from the pop-up menu obtained by right-clicking on TImageList icon in the Form Designer. Then in the StringList editor for Items the correct ImageIndex must be allocated to each entry in the list.

SortType - whether to sort by text, by data, both or not at all SortColumn - the column that is being sorted StateImages - an imagelist of icons to demonstrate the state of a process or event ViewStyle - whether to view as a simple list, a list with large or small icons, or as a report BoundingRect - the coordinates of the rectangle containing the ListView Canvas - defines the area on which all graphic material is drawn (Read-only) CheckBoxes - determines if the ListView shows checkboxes beside the items on the list Column - reads the column information of the listview.

This property can be used to read the information of a column.

The column whose information is to be retrieved is determined by an index (AIndex). As with nearly all indexes, this index is 0 based. In column[0] the caption of the listitem is show, in subsequent column the subitems of the listitem are shown.

To add, change or delete a column use the Columns property

Integer to determine the column of the ListView to retreive information on. DropTarget - location where an item from the list is to be dropped FlatScrollBars - whether the scroll bars are to be displayed flat ItemFocused - the item currently receiving focus RowSelect - whether the user can select rows of items (across columns). Default false SelCount - the number of items selected Selected - the current list item that has been selected TopItem - the first item on the list ViewOrigin - the top left coordinate for the current view VisibleRowCount - the number of rows visible in the current view (some items might have scrolled outside the window) TListView - a window showing a list of Items, which may or may not have associated icons

TListView - a window showing a list of items, which may or may not have associated icons

At first, this control looks very like TListBox, but it has a much higher degree of complexity. It is capable of displaying Items in Columns of Rows, and it can have images associated with the list Items.

The important information is held in Items, a string-list that can be created using the string-list editor obtained by right-clicking on the ListView in the Form Editor or by clicking on the ellipsis (...) next to the Items entry in the Object Inspector.

A typical application might have two ImageLists: one ofLargeImages and one of SmallImages, containing two versions of the same collection of images, in large and small format; the index numbers of the first list would correspond with those in the second list.

SmallImages (if assigned to a string-list) can be displayed beside the text strings in the list view, and the programmer would supply code to ensure that when an item with its associated Small Image was selected, the corresponding Large Image would be displayed in another window.

One or more TImageList controls need to be selected and pasted on to the Form Designer, and the ImageList Editor can be opened from the pop-up menu obtained by right-clicking on TImageList icon in the Form Designer. The image list can be populated by reading from files. Then in the StringList editor for Items the correct ImageIndex must be allocated to each entry in the list.

The ancestor class for TProgressBar TCustomProgressBar is the ancestor for TProgressBar. If you want to define your own ProgressBar class, you should derive it from this class. TProgress Bar - a bar that depicts what proportion of a process has been completed TProgress Bar: a control that appears at or near the bottom of form or window. It depicts the progress of a process, or what proportion of the process is complete. A series of coloured rectangles appears in the control, filling it from left to right or from top to bottom as the process progresses HowToUseStdCtrls Message constant. Determines the style of the tool buttons.

These are the possible values of Style:

  • tbsButton - The button appears and functions like a normal button.
  • tbsCheck - Clicking the button toggles the Down property. Once selected, the button remains selected until clicked again.
  • tbsDivider - The button appears as a vertical line on the toolbar (used to separate other controls).
  • tbsDropDown - The button displays a downwards-pointing arrow (suitable for accessing a drop-down menu).
  • tbsSeparator - The button appears as an empty space on the toolbar (used to separate other controls).
The button appears and functions like a normal button. Clicking the button toggles the Down property. Once selected, the button remains selected until clicked again. The button displays a downwards-pointing arrow (suitable for accessing a drop-down menu). The button appears as an empty space on the toolbar (used to separate other controls). The button appears as a vertical line on the toolbar (used to separate other controls). TToolButton is a button control in a TToolBar object.

Use TToolButton to implement buttons on a toolbar. While other controls (including TButton and TSpeedButton) can be placed on toolbars, TToolButton utilizes special toolbar features to simplify the configuration of buttons and offers added display options such as pop-up borders and transparency.

To place tool buttons on a toolbar at design time, select the toolbar, right-click, and choose New Button.

TButton TSpeedButton HowToUseStdCtrls
Index - the sequence number of the current button in the list of buttons Is this button Down (ie has it been selected)? Default false A DropDownMenu that appears when this button is selected

A DropDownMenu that appears when this button is selected

It uses the same code as a TPopupMenu, and offers a series of additional menu choices.

Is this button a member of a group? Default false

Is this button a member of a group?

This would mean behaviour similar to the radio buttons in a TRadioGroup, where only one button in the group can be selected, or the check boxes in a TCheckGroup where more than one item can be selected but the members of the group interact in some way.

ImageIndex - the index value of the image from the imagelist to be used with this button Is this button Marked (ie has it been selected)? Default false The item on the Main Menu with which this tool button is associated

The item on the Main Menu with which this tool button is associated

Typically, the buttons on the toolbar would each point to an entry on the menu action list, which could also be accessed by using the Main Menu

Has this button been wrapped to the next row? Determines the style of the tool button. See TToolButtonStyle for the possible Style values. TToolbar manages tool buttons and other controls, arranging them in rows and automatically adjusting their sizes and positions.

TToolbar is a container for tool buttons (TToolButton). it provides an easy way to arrange and manage visual controls.

  • All tool buttons on a toolbar maintain a uniform width and height.
  • Other controls can sit on a toolbar. These controls (which are held in place by invisible tool buttons) maintain a uniform height.
  • Controls can automatically wrap around and start a new row when they do not fit horizontally on the toolbar.
  • The Flat property allows the background to show through the toolbar and gives pop-up borders to the tool buttons.
  • Spaces and dividers (which are in fact specially configured tool buttons) can group controls on the toolbar both visually and functionally.

Typically, the tool buttons correspond to items in an application's menu and gives the user more direct access to the application's commands.

HowToUseStdCtrls
Lists the tool buttons (TToolButton) in the toolbar.

Buttons maintains a list of TToolButton instances. All tool buttons that share a TToolBar parent have the same height and (except for separators and dividers) the same width. Other controls on a toolbar are held in place by invisible separators, which are automatically created and destroyed.

To add tool buttons to the toolbar at design time, select the toolbar, right-click, and choose New Button. To create a space (separator) between one button and the next, select New Separator. To create a divider between buttons, add a button and set its Style propery to tbsDivider. Other controls may be added to the toolbar directly from the Component palette.

The Images on the Image List that are NOT selected for display Should the toolbuttons be displayed Flat (rather than in relief)? Default false The Images on the Image list that are selected for display The Images to be displayed on the buttons Indent - the amount by which the buttons should be indented Default is 1 Should the contents of the toolbar be displayed as a List? Default false Wrapable - enables wrapping buttons to the next row if there are too many for the current row TCustomTrackBar - the base class for TTrackBar

TCustomTrackBar defines many of the properties inherited by TTrackBar, a device that allows the user to determine the value of a variable using a quasi-analog slider

SetTick - set the interval for ticks on the taskbar (integer) Frequency - how frequently the position of the slider is to be read and updated (currently unsupported) Line-Size - increment for slider position when an arrow key is pressed Max - the value corresponding to full movement of the slider. Default = 10 Min - the value associated with the minimum slider position. Default = 0 OnChange - action to be taken on change in the slider position Orientation - horizontal or vertical PageSize - increment for slider position when PageUp or PageDown key is pressed Position - the location of the slider along the track bar. Represents the Return value from the control ScalePos - whether scaling label appears at top, bottom, left or right Tickmarks - whether the ticks are above/left, below/right, or both Tickmarks - where the ticks appear relative to the bar: above/left, below/right, or both TickStyle - none, produced automatically, or calculated manually TTrackBar: a device which allows the user to determine the value of a variable using a quasi-analog slider

TTrackBar: a device which allows the user to determine the value of a variable using a quasi-analog slider

The device looks like a slider-potentiometer control on a hi-fi amplifier, and consists of a slider which can be moved along a bar using the mouse. Tick marks can be displayed along one or both edges, giving an indication of the proportion of the maximum value of the controlled variable that is being selected.

The Position property indicates the distance along the bar that the slider has been placed, either by the program or by mouse capture and movement

In the example, movement of the slider is detected and shown in the associated TProgressBar.

HowToUseStdCtrls
A set to determine the place where a node should be placed in a tree.

This sets consist of three values:

taAdd: Adds the node as the last child.

taAddFirst: Adds the node as the first child.

taInsert: Adds the node in front another node.


This set is used in TTreeNode.InternalMove and TTreeNodes.InternalAddObject

Definition of a error type for errors araising from the code of TTreeView Definition of a error type for errors araising from the code of TTreeView A array of strings containings names for NodeAttachModes This is a constant array of string containing names for the modes to attach a node. An array of strings to store the names for the different TAddModes. Type TAddMode = (taAddFirst, taAdd, taInsert); Const AddModeNames: array[TAddMode] of string = ('taAddFirst', 'taAdd', 'taInsert'); A constant A pointer to TTreeNodeInfo A pointer to TDelphiNodeInfo TTreeNode is a single item that holds data in TTreeView A TTreeNode is part of a TTreeView and is used for storing data. This can be done by using the Caption property or for more complex data the Data property can be used. Each node can have sibling or child items associated with it. Property of type pointer used to store custom data in a node. Unit used by ComCtrls. A collection or list of TTreeNode A set of TreeViewOptions which are set be default. These set of options is used to set the options of a TreeView object when first placed on a form. This set consists of the follwoing items:
tvoShowRoot,
tvoShowLines,
tvoShowButtons,
tvoHideSelection,
tvoToolTips,
tvoKeepCollapsedNodes,
tvoAutoItemHeight
For the meaning of this options, see the documentation of TTreeView.
TCustomTreeView - ancestor class for TTreeView TCustomTreeView - ancestor class for TTreeView, which displays a collection of items in a hierarchical tree form. This class defines many properties which are inherited by children classes, including loading the data from files or streams, saving to files or streams, updating, sorting alphabetically, editing, making visible or invisible, expanding or collapsing the tree display, and many more. TTreeView is a control that displays a hierarchical list of items Use a TTreeView to display a hierarchical list of items. Items are shown by their caption and an optional bitmap. The Bitmap image associated with each item in the display The Items to be displayed in the tree view - ie the actual data Function to compare the nodetext two nodes. This function does an ANSICompare on the NodeText of two nodes. The parameters Data1 and Data2 are pointers to the nodes to be compared. The result is the same is the result from ANSICompareText.
-1: The nodetext from the first node is lower then the nodetext from the second.
0: The nodetext-s from both nodes are equal.
1: The nodetext from the first node is higher then the nodetext from the second.
Function to compare the give text with the nodetextof the given node. This function does an ANSICompare on the NodeText of two nodes. The parameters Data1 and Data2 are pointers to the nodes to be compared. The result is the same is the result from ANSICompareText.
-1: The given text is lower then the nodetext from the given node.
0: The given text is equal to the nodetext from the given node.
1: The given text is higher then the nodetext from the given node.
Function InitCommonControl Implemented for Delphi compatibility, always returns true; Procedure CheckCommonControl. Implemented for Delphi compatibility. Procedure does not execute any code. Procedure used to register the components.