ToolBarButton Label Positioning
-
- Posts: 4
- Joined: June 29th, 2004, 8:22 pm
ToolBarButton Label Positioning
Does anyone know how to get a ToolBarButton's label underneath or to the left of the button instead of to the right of the button?
Brian
-
- Posts: 1974
- Joined: November 5th, 2002, 3:25 am
- Location: Lancaster, UK
- Contact:
To get the label below the icon use either the <code>orient</code> attribute in XUL, or the <code>-moz-box-orient</code> CSS property (set to <code>vertical</code>). CSS can't override the attribute, so if you want themes to be able to change the orientation then use CSS to set it.
To get the text to the left of the icon use <code>-moz-box-direction: reverse</code> in CSS (presumably <code>direction="reverse"</code> in XUL would work too, though I've never tried). Combine with the above to get the text above the icon.
If your toolbar button has <code>type="menu"</code> or <code>type="menubutton"</code> then things get more complicated.
To get the text to the left of the icon use <code>-moz-box-direction: reverse</code> in CSS (presumably <code>direction="reverse"</code> in XUL would work too, though I've never tried). Combine with the above to get the text above the icon.
If your toolbar button has <code>type="menu"</code> or <code>type="menubutton"</code> then things get more complicated.
- mcm_ham
- Posts: 1747
- Joined: June 16th, 2004, 6:09 am
- Location: Christchurch, New Zealand