Skinning How To/Edit a menu

From Second Life Wiki
Jump to: navigation, search


  • All viewer menu options are set in menu_viewer.xml except for the Advanced/Admin menus (see VWR-2896).
  • Width/height/bottom/left/top are irrelevant in the menu files. The viewer constructs menus based on the xml file's organization and ignores these parameters.
  • Example menu structure:
          <menu_item_separator />

Menu files

  • Viewer menu: menu_viewer.xml
  • Inventory menu: floater_inventory.xml
  • Inventory item menu when right clicked: menu_inventory.xml
  • SLURL menu when right clicked (not currently enabled): menu_slurl.xml
  • Menu at the login screen: menu_login.xml
  • Pie menu when you right click:
    • An object: menu_pie_object.xml
    • Yourself: menu_pie_self.xml
    • Land: menu_pie_land.xml
    • Someone else: menu_pie_avatar.xml
    • An attachment: menu_pie_attachment.xml



Bar that holds menu entries. Accepts name and opaque.


Top level menu. Flyout menu when nested.


Menu item that tells the viewer to execute a specific function.


Nested in a menu item. Sets the function when clicked.


Nested in a menu item. Sets the function when option is enabled.

<menu_item_separator />

Draws a separator between menu options.


Menu item that toggles whether something is active or inactive (set via an X next to the name).


Nested in a menu item. Sets the function when checked.


Does nothing. Assumed to be a legacy setting.



Sets whether or not a menu is enabled or not. Use in <menu>. Boolean: enabled="true" (Default true)


Sets the name the user sees. Necessary for <menu> and menu items. String: label="Awesome Menu"


Sets the name the viewer sees. Necessary for <menu> and menu items. String: name="MenuAwesome"

  • Changing the name of the Tools menu will make it not auto-hide.


Optional. Sets whether or not the menu can be torn off (the double bars at the top of a menu). Use in <menu>. Boolean: tear_off="true" (Default true)


Optional. Sets whether or not the menu is opaque Setting a top-level menu like World to false turns the menu transparent (unless it's torn off and reattached, then you have to relog). Setting the menu bar to false will turn it transparent per its setting in colors.xml. Use in <menu> and <menu_bar>. Boolean: opaque="true"





Optional. Allows keyboard navigation via jump keys. Menus can be navigated using the keyboard by holding down ALT and pressing up or down. Boolean: create_jump_keys="true"


Optional. Any data sent to the function. Use in <on_click>, etc. String: userdata="800,600"


Associates a function with a menu item and action. Use in <on_click>, etc. String: function="Tools.SelectedScriptAction"


Optional. Sets the keyboard shortcut for a menu item. Each key is separated by pipes. String: shortcut="control|alt|T"

Changing a menu

  • If you're adding a shortcut, make sure it isn't used by another item first.
  • Renaming a menu or menu item is fine as long as it calls a working function.
  • Any number of top level menus, flyout menus, and menu items can be set.
  • Don't worry about width/height/bottom/left/top. As said in the intro, these don't do anything anymore.
  • If you want to create a new menu item that doesn't call an existing function, you need to edit the source as well. See Adding_a_menu_item for a start.