Desktop Tools and Development Environment Previous page   Next Page

Adding Your Own Toolboxes to the Start Button

If you offer a toolbox or a collection of M-files to other users, you can provide access to it from the Start button.

In summary, the Start button determines what information to display using info.xml files that reside on the search path or in the current directory. You create an info.xml file for your toolbox, which contains tags for all of the subentries you want on the Start button. The term toolbox is used here for convenience, but the same concept applies to a blockset or any name you give to your M-file collection.

You can view and modify the file used for this example, which is located in matlab/help/techdoc/matlab_env/examples; it adds the SpecSim (Example) Toolbox to the Start button:

  1. Copy the example file startinfo.xml to a directory for which you have write access. Rename it to info.xml. Add the directory to the search path.
  2. Select Start -> Toolboxes -> SpecSim (Example) to see its entries.

    Image showing Start menu, with Toolboxes - SpecSim selected. There are three entries: SpecSim GUI, Example, and SpecSim Web Site.

  3. Select Start -> Desktop Tools -> View Source Files.
  1. The Start Button Configuration Files dialog box opens.

    Image of Start Button Configuraton Files dialog box, highlighting the SpecSim (Example) item.

  1. Select an info.xml file, which you will use as a basis for your own toolbox--for this example, select the info.xml file for SpecSim (Example).
  2. Click the Open button.
  1. The info.xml file for the selected product opens in the Editor/Debugger.

  1. In the Editor/Debugger, change the entries in the info.xml file so they pertain to your toolbox. For details, see the illustration and table after step 9.
  2. In the Editor/Debugger, select File -> Save to save the changes.
  3. In the Start Button Configuration Files dialog box, click Refresh Start Button and then click Close.
  4. Select Start -> Toolboxes to see your toolbox and all of its subentries on the Start button.

    Image of info.xml file opened in the Editor. The file adds SpecSim to the Start button.

    Line
    XML Tag
    Value for Example
    Notes 
    6
    <matlabrelease>
    14
    MATLAB release.
    7
    <name>
    SpecSim (Example)
    Name of the toolbox.
    8
    <type>
    toolbox
    The product category. Allowable values are matlab, simulink, toolbox, blockset, other. This determines where the entry appears in the Start button. SpecSim (Example) appears under Start -> Toolboxes. Within a category, entries are displayed in alphabetical order.
    9
    <icon>
    specsimicon.gif
    Assumes the toolbox has the icon, specsimicon.gif. You can use icons supplied with MATLAB, which are in matlab/toolbox/matlab
    /icons
    . You can specify a relative path, that is relative to the location of the info.xml file. For the example, specsimicon.gif is included in the matlab/help/techdoc/matlab_env/
    examples
    .
    10
    <help_location>

    Location of HTML help files you provide for the toolbox. This has no corresponding entry on the Start button, but impacts the Help browser. For details, see Adding Your Own Help Files in the Help Browser. You can specify a relative path, that is, relative to the location of the info.xml file. For the example, there is no entry.
    12 to 15
    <label>
    SpecSim GUI
    Name of a tool in the toolbox. You must have at least one list- listitem-label-callback set of tags for the toolbox to appear in the Start button.
    16
    <callback>
    saviewer
    Function in the toolbox that runs the SpecSim GUI. This is the statement that runs when you select Start -> Toolboxes -> SpecSim (Example) -> SpecSim GUI. For example, saviewer starts the SpecSim GUI.
    17
    <icon>
    $toolbox/signal/.../
    fdatoolicon.gif
    Use the FDA tool icon for the toolbox. This value uses a relative pathname: $toolbox is the matlab/toolbox directory.
    21
    <label>
    Examples
    For examples you provide with the toolbox.
    22
    <callback>
    sa_examples
    This is the statement that runs when you select the Start -> Toolboxes -> SpecSim (Examples) -> Examples menu item for the SpecSim (Example) Toolbox. In this example, sa_examples is an M-file that contains example code.
    23
    <icon>
    $toolbox/matlab
    /icons/demoicon.gif

    Use the standard MATLAB demo and example icon. This value uses a relative pathname: $toolbox is the matlab/toolbox directory.
    27
    <label>
    SpecSim Web Site
    Provide a link to the toolbox's Web site.
    28
    <callback>
    web http://www.
    specsim.com -browser

    This is the statement that runs when you select the Start -> Toolboxes -> SpecSim (Example) -> SpecSim Web Site menu item. In this example, it displays the Web site for the SpecSim (Example) Toolbox in the system browser.
    30
    to
    34

    </listitem>
    </list>
    </productinfo>

    none
    Designates end of list and productinfo entries in the Start button for the toolbox.

Editing the info.xml File for Your Own Toolbox

After making changes to the info.xml files for your own toolboxes, you need to perform these steps so that your changes appear in the Start button:

  1. Select Start -> Desktop Tools -> View Source Files.
  2. In the resulting Start Button Configuration Files dialog box, click Refresh Start Button, and then click Close.
  3. Select Start to see the changes.

Previous page  Adding Your Own Toolboxes to the Development Environment Adding Your Own Help Files in the Help Browser Next page

© 1994-2005 The MathWorks, Inc.