This is documentation for Mathematica 4, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)
Wolfram Research, Inc.

Creating a Button BoxCombinatorica

An Example

Suppose you want to construct a hyperlink that points to information about the menu command Format RightTriangle Option Inspector. The cells with this information are located in the a notebook called "FormatMenu.nb" and have the cell tag "OptionsDialog". This notebook is in the OtherInformation directory of the Documentation/English directory. The item in the BrowserCategories.m file that refers to this topic is:

Item["Option Inspector","FormatMenu.nb",

CopyTag -> "OptionsDialog",

IndexTag -> "Option Inspector"]

Hence the expression for the ButtonBox command will be:

ButtonBox["Option Inspector",

ButtonData:> "Option Inspector",

ButtonStyle -> "OtherInformationLink"]


1. The first argument of the ButtonBox command contains the text that will represent the hyperlink.

2. The setting for the ButtonData option matches the IndexTag for this item.

3. The setting for the ButtonStyle option is OtherInformationLink because the target material is located in the OtherInformation subdirectory.

Here are the steps involved in creating such a hyperlink:

1. Select the cell in which you want to place the hyperlink, e.g. a blank text cell.

2. Unformat the expression for the cell by typing ControlKeyKeyBarShiftKeyLeftModifiedERightModified.

(For Macintosh type CloverLeafKeyBarShiftKeyKeyBarLeftModifiedERightModified.)

3. Insert the ButtonBox expression written above into the cell.

4. Wrap the command TextData[ ] around the ButtonBox expression inside the cell.

5. The cell expression now looks like this.

Cell[TextData[ButtonBox["Option Inspector",

ButtonData :> "Option Inspector",

ButtonStyle -> "Hyperlink"]], "Text"]

6. Format the cell expression by typing ControlKeyKeyBarShiftKeyLeftModifiedERightModified again.

This completes the construction of the hyperlink. The text "Option Inspector" now appears underlined and colored. Clicking on the link will cause the Help Browser to open and display information about this menu command. A similar procedure can be followed for constructing a hyperlink to any other item in the Help Browser.

Creating a Button BoxCombinatorica