You can use layer.getContentHeight() and layer.getContentWidth() to get
the width and height of the contents.
--
// Robert Rainwater
On 2/21/2001, 11:57:18 PM EST, Ken wrote about "[Dynapi-Help] Sizing based on content
& CSS":
> Hi List,
> I'm working on a pulldown menu widget and have a couple of questions.
> Any body know how to automatically size based on content? For example, if I
> have a button with the letter 'X' in it, I would like to make it very small.
> (top menu) For large text, I will want to make the button grow in vertical
> size. (for drop down items) I've tried using getContentHeight() and
> getContentWidth() but they don't seem to be cooperating.
> Also, control the appearence of the selected and unselected items, etc, how
> effective is using style sheet classes like:
> o.setHTML('<span class="PullDownMenu">'+o.caption+'</span>')
> Does this create any cross browser issues? In IE i note that I can do a lot
> of stuff with borders and the like. How well does this translate into NS
> 4/6?
> Ken
> _______________________________________________
> Dynapi-Help mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/lists/listinfo/dynapi-help
----------------------
DynAPI Snapshots: http://dynapi.sourceforge.net/snapshot/
DynAPI Homepage: http://dynapi.sourceforge.net/
_______________________________________________
Dynapi-Help mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dynapi-help