Bug 146609 - [testcase] <option> CSS "width" doesn't work
Summary: [testcase] <option> CSS "width" doesn't work
Status: RESOLVED FIXED
Alias: None
Product: konqueror
Classification: Applications
Component: khtml (show other bugs)
Version: 3.5
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Konqueror Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-06-10 02:12 UTC by Iñaki Baz Castillo
Modified: 2011-01-09 23:48 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Web page showing the issue (917 bytes, text/html)
2007-08-12 01:33 UTC, Iñaki Baz Castillo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Iñaki Baz Castillo 2007-06-10 02:12:30 UTC
Version:           3.5.6 (using KDE 3.5.6, Kubuntu (edgy) 4:3.5.6-0ubuntu1~edgy1)
Compiler:          Target: i486-linux-gnu
OS:                Linux (i686) release 2.6.17-10-generic

If <select> has "width:100px" and <option> has "width:100%" then when showing the options they should use all the required width, even if it's bigger then 100px. That's how it works in Firefox.

But in KHTML the CSS "width" does nothing in <option> CSS.

Try this simple code in Firefox and Konqueror to undersantthe bug:

<select style="width: 50px">
  <option style="width: 100%">short</option>
  <option style="width: 100%">very very very very very very very long, more than 100px</option>
</select>

In Konqueror the <option>'s width is always the <select>'s width.
Comment 1 Iñaki Baz Castillo 2007-06-19 21:58:47 UTC
I have created a simple HTML code to show the problem. It's here:

  http://ibc.43i.net/khtml-select-width-issue/index.html
Comment 2 Iñaki Baz Castillo 2007-08-12 01:31:18 UTC
Sorry, the link is wrong. This is the correct one:
  http://ibc.43i.net/khtml-select-width-issue.html
Comment 3 Iñaki Baz Castillo 2007-08-12 01:32:37 UTC
If the above link fails (because the free web hosting that deletes the content) I attach the page that show the problem.
Comment 4 Iñaki Baz Castillo 2007-08-12 01:33:12 UTC
Created attachment 21376 [details]
Web page showing the issue
Comment 5 Iñaki Baz Castillo 2007-11-20 09:58:19 UTC
Please, any comment about this issue? really nobody confirms it at least?
I think it's very obvious that the bug does exist.

Thanks.
Comment 6 Tommi Tervo 2007-11-20 10:30:46 UTC
Confirmed on 3.5.8, but seems to be fixed in 4.0 beta4.
Comment 7 Iñaki Baz Castillo 2007-12-15 14:35:30 UTC
The bug still exists in Suse KDE4 live CD:
  KDE 4.0 RC2 (3.97.0)

I'm not sure if 4.0beta4 is higher than RC2 3.97.0.
Comment 8 Iñaki Baz Castillo 2008-02-09 21:30:25 UTC
This is **not** fixed in KDE 4.0.1 of Kubuntu.
Comment 9 A. Spehr 2008-04-24 09:12:06 UTC
Sadly, this still exists in 4.0 branch r793993.
Comment 10 Iñaki Baz Castillo 2009-04-06 00:16:37 UTC
Still occurs in KDE 4.2.2.
Comment 11 Gérard Talbot (no longer involved) 2010-05-26 07:01:08 UTC
Hello all,

I loaded attachment 21376 [details] in Konqueror 4.4.3 (Linux 2.6.31-19-generic i686 32bits; Kubuntu package; Qt 4.6.2) and when expanded, the list of options was as wide as its widest option (the 2nd option which was obviously wider than 50px). No clipping occured. So, as far as I can see, this bug was FIXED. Otherwise this WORKSFORME.

Note that the testcase has invalid document structure (document root and body node are inferred), no doctype declaration; so it triggers "quirks" backward-compatible rendering mode, not standards compliant rendering mode. Also, the style="width: 100%" for the option is totally, entirely pointless, irrelevant if the webpage uses valid code and declares a doctype triggering standards compliant rendering mode. So, the problem could/would have been fixed just by upgrading the markup code to begin with.

regards, Gérard
Comment 12 Samuel Brack 2011-01-09 23:48:40 UTC
Fixed in 4.5.4, closing this report.