W3C home > Mailing lists > Public > public-html-bugzilla@w3.org > May 2011

[Bug 12245] @size on <select> drop-downs is not enough to specify the drop-down maxlength on long options lists with scrollbars

From: <bugzilla@jessica.w3.org>
Date: Fri, 13 May 2011 06:12:56 +0000
To: public-html-bugzilla@w3.org
Message-Id: <E1QKlcO-0008Ah-32@jessica.w3.org>
http://www.w3.org/Bugs/Public/show_bug.cgi?id=12245

--- Comment #24 from Silvia Pfeiffer <silviapfeiffer1@gmail.com> 2011-05-13 06:12:55 UTC ---
(In reply to comment #23)
> > I can already calculate how much space I have available
> > through other means and if I want to stay within the height of a video element
> > or an iframe or whatever, I have that height. I also have the height of each
> > entry in the drop-down. So, if I can tell the browser how many items I want to
> > display maximum, then I can limit the size to whatever I need.
> 
> How are you getting the height of a entry in the drop-down? I guess
> getComputedStyle on a individual <option> could work, though I'm not sure that
> that gives the right value in implementations that doesn't use CSS to display
> the dropdown, such as the one in Safari. I'm also not sure that it'll work
> while the items aren't displayed, such as when the dropdown is not expanded,
> since there won't be any frames for it. We could require that to work of
> course...
> 
> If the use-case is to ensure that the dropdown is a given size in pixels (or
> mm), such that it can "stay within the height of a video element or an iframe
> or whatever", it seems weird to me though require the page to first calculate
> the size of each individual item, then divide the desired height by the item
> height, and finally to set the size expressed in items. Not to mention the pain
> if <option>s can be differently sized...
> 
> Seems much simpler to be able to set the size in pixels (or mm) in the first
> place.

OK, fine by me. That does solve the problem.

-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
Received on Friday, 13 May 2011 06:12:57 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 16:31:10 UTC