Menu bar width
2005/04/27 05:43
Viewed 8909 times
Replies: 1/2

I would like to create a menu where the width of the menubar is only as wide as needed rather than 100% of the available space. Thanks!

Re: Menu bar width
2005/04/27 10:27
Viewed 11315 times
Replies: 1/1

Well, the menu toplevel parent element is a DIV and as such, it occupies 100% of the available horizontal space. However, you have several options:

(1) Add the following in some CSS section:

div.dynarch-horiz-menu {
float: left;
}

This will make the menubar float at the left; you can try “float: right” too.

(2) Embed the menu in some table element and size accordingly the cell that contains the menu.  Normally you should be able to undersize it (say 1em) and it will scale to the minimum size required for the menu to fit.  But beware Internet Explorer (5.x I think) might break spaces in menu labels in this case, use “ ” or add “white-space: nowrap” in that table's style attribute.

Hope this helps.

last
Re[2]: Menu bar width
2005/04/28 23:05
Viewed 13559 times
Replies: 0/0

Great, that worked perfectly!

last
Google