RE: Min-width property for select boxes?

	It doesn't seem to work on select boxes though (IE5.5).  Try the
code below.  It should fill the page and shrink with it until you get below
500 pixels and then stop shrinking.  It doesn't stop shrinking though...

<select style="width:100%; min-width:500px">
	<option>hello world</option>
</select>

-----Original Message-----
From: Ian Hickson [mailto:ian@hixie.ch]
Sent: Tuesday, July 31, 2001 3:47 PM
To: Zongker, Jeremy
Cc: 'www-style@w3.org'
Subject: Re: Min-width property for select boxes?


On Tue, 31 Jul 2001, Zongker, Jeremy wrote:

> I have a select box I would like to stretch to the size of the cell if
it's
> larger, but not shrink below the size of the items in it if the cell is
> smaller.  I can make it stetch using style="width:100%".  Can someone tell
> me if there is some type of min-width property?

Yep, it's called 'min-width' and works exactly like 'width' but for the
minimum width instead of the preferred width.

   http://www.w3.org/TR/REC-CSS2/visudet.html#propdef-min-width

-- 
Ian Hickson                                            )\     _. - ._.)   fL
Invited Expert, CSS Working Group                     /. `- '  (  `--'
The views expressed in this message are strictly      `- , ) -  > ) \
personal and not those of Netscape or Mozilla. ________ (.' \) (.' -' ______

Received on Wednesday, 1 August 2001 08:26:48 UTC