Documentation
Publicon
User Guide
Advanced Features
Creating Document Palettes
Button Functions
Button Functions
Introduction
Each button in the document palette triggers a specific action, such as creating a new cell of a particular style. The cell expression for any button has the following form:
ButtonBox[expr, options]
where expr specifies what is displayed on the button and options controls the button's appearance and the action performed when the button is clicked.
You can view a list of all the button options in the Help Browser. Three of the important button options are ButtonFunction, ButtonEvaluator, and Active.
The ButtonFunction option specifies the function that should be executed when the button is clicked.
The ButtonEvaluator option specifies where the expression constructed from ButtonFunction should be sent for evaluation.
The Active option specifies if an action is performed when a button is clicked. When Active
False you can edit the contents of a button directly. When Active
True, the ButtonBox will perform its action whenever you click on it.