Skip to content

TTMSFNCBloxToolbar

Methods

Method name Description
AddCategoryItem(ABitmap: TTMSFNCBitmap): TTMSFNCCategoryListItem; Adds a new toolbar item with an existing TTMSFNCBitmap instance
AddCategoryItem(ABitmapName: string): TTMSFNCCategoryListItem; Adds a new toolbar item with a bitmap name from the referenced TTMSFNCBitmapContainer
AddCategoryItem: TTMSFNCCategoryListItem; Adds a new toolbar item
BeginUpdate Blocks all visual updates. Needs to be paired with EndUpdate;
ClosePopup Closes an active popup, displayed after clicking the item that has a PopupControl attached
EndUpdate Blocks all visual updates. Needs to be paired with BeginUpdate; When EndUpdate is called, the control is automatically recalculated/repainted
InitializeDefault Initializes the toolbar with a default appearance and a set of items, based on the necessary tools needed to configure and manipulate diagrams displayed in the TTMSFNCBloxControl
InsertCategoryItem(AIndex: Integer): TTMSFNCCategoryListItem; Inserts a new toolbar item at a specific index
InsertCategoryItem(AIndex: Integer; ABitmap: TTMSFNCBitmap): TTMSFNCCategoryListItem; Inserts a new toolbar item at a specific index with an existing TTMSFNCBitmap instance
InsertCategoryItem(AIndex: Integer; ABitmapName: string): TTMSFNCCategoryListItem; Inserts a new toolbar item at a specific index with a bitmap name from the references TTMSFNCBitmapContainer
Rebuild Completely rebuilds the toolbar, re-initializes the registered elements andcalls InitializeDefault
XYToItem(X, Y: Single): Integer; Returns the item index of a specific item under X and Y coordinates

Events

When assigning an event that executes an action on a block, line or blox control, you are responsible for setting the correct properties. The default behavior is not executed as soon as an event is assigned. This has been designed in this way that you are able to provide a different meaning/purpose to the action that has been executed.

Property name Description
OnAfterDraw Event called after all elements of the toolbar has been drawn
OnApplyAlignCenter Event called when the align center button has been clicked
OnApplyAlignLeft Event called when the align left button has been clicked
OnApplyAlignRight Event called when the align right button has been clicked
OnApplyBold Event called when the bold button has been clicked
OnApplyFillColor Event called when a fill color is selected
OnApplyFillColorTo Event called when a fill color to is selected
OnApplyFillOrientation Event called when the fill orientation is selected
OnApplyFillType Event called when the fill type is selected
OnApplyFontName Event called when the font name is selected
OnApplyFontSize Event called when the font size is selected
OnApplyItalic Event called when the italic button has been clicked
OnApplyPictureMode Event called when the picture mode is changed
OnApplySnapToGrid Event called when the snap to grid button is clicked
OnApplyStrikeOut Event called when the strike out button has been clicked
OnApplyStrokeColor Event called when a stroke color is selected
OnApplyStrokeStyle Event called when a stroke style is selected
OnApplyStrokeWidth Event called when a stroke width is selected
OnApplyText Event called when the text changes
OnApplyTextColor Event called when the text color is applied
OnApplyUnderline Event called when the underline button has been clicked
OnBeforeDraw Event called before all elements of the toolbar has been drawn
OnCopy Event called when the copy button has been clicked
OnCut Event called when the cut button has been clicked
OnDeletePicture Event called when the delete picture button has been clicked
OnItemAfterDrawBackground Event called after the toolbar item background has been drawn
OnItemAfterDrawBitmap Event called after the toolbar item bitmap has been drawn
OnItemAfterDrawContent Event called after the toolbar item content has been drawn
OnItemBeforeDrawBackground Event called before the toolbar item background has been drawn
OnItemBeforeDrawBitmap Event called before the toolbar item bitmap has been drawn
OnItemBeforeDrawContent Event called before the toolbar item content has been drawn
OnItemClick Event called when an item is clicked
OnItemSelected Event called when an item is selected
OnOpenFile Event called when the open file button is clicked
OnOpenPicture Event called when the open picture button is clicked
OnPaste Event called when the paste button is clicked
OnRedo Event called when the redo button is clicked
OnRotateLeft Event called when the rotate left button is clicked
OnRotateRight Event called when the rotate right button is clicked
OnSaveFile Event called when the save button is clicked
OnUndo Event called when the undo button is clicked
OnZoomChanged Event called when the zoom factor has changed