Stay organized with collections Save and categorize content based on your preferences.

blockly > IToolbox

IToolbox interface

Interface for a toolbox.

Signature:

export interface IToolbox extends IRegistrable 

Extends: IRegistrable

Methods

Method Description
clearSelection() Unhighlights any previously selected item.
dispose() Disposes of this toolbox.
getFlyout() Gets the toolbox flyout.
getHeight() Gets the height of the toolbox.
getSelectedItem() Gets the selected item.
getWidth() Gets the width of the toolbox.
getWorkspace() Gets the workspace for the toolbox.
handleToolboxItemResize() Handles resizing the toolbox when a toolbox item resizes.
init() Initializes the toolbox.
isHorizontal() Gets whether or not the toolbox is horizontal.
position() Positions the toolbox based on whether it is a horizontal toolbox and whether the workspace is in rtl.
refreshSelection() Updates the flyout's content without closing it. Should be used in response to a change in one of the dynamic categories, such as variables or procedures.
refreshTheme() Updates the category colours and background colour of selected categories.
render(toolboxDef) Fills the toolbox with new toolbox items and removes any old contents.
selectItemByPosition(position) Selects the toolbox item by it's position in the list of toolbox items.
setVisible(isVisible) Sets the visibility of the toolbox.