Bug 95613

Summary: [testcase] Little error when rendering input elements within tables
Product: [Applications] konqueror Reporter: Anderson Medeiros Gomes <amg1127>
Component: khtml rendererAssignee: Konqueror Developers <konq-bugs>
Status: RESOLVED LATER    
Severity: normal CC: james
Priority: NOR    
Version: 3.3.2   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: attaching testcase

Description Anderson Medeiros Gomes 2004-12-22 04:06:50 UTC
Version:           3.3.2 (using KDE 3.3.2, compiled sources)
Compiler:          gcc version 3.4.0 (Red Hat Linux 3.4.0-1)
OS:                Linux (i686) release 2.6.7-1.494.2.2

Copy the HTML code below in a text editor (kwrite), save as *.html and open it with konqueror. You will see a 'select' element and some buttons.
Click on 'Empty!' button. You will see the button valued 'Test 1' disappears.
The button appears when you move the mouse over it, or when you click on 'Put a text' button.
This is really a insignificant bug... But it's a bug.

<!-- Begin -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
        "http://www.w3.org/TR/REC-html40/loose.dtd">
<html>
 <head>
  <title>This is a bug</title>
  <script language='JavaScript' type='text/javascript'>
   function add_text(f) {
    var o, l;
    o = new Option("no", "no", false, false);
    l = f.testing.options.length;
    f.testing.options[l] = o;
    f.testing.options[l].text = "Conquer your desktop with KDE.";
   }
   
   function remove_text(f) {
    f.testing.options.length = 0;
   }
   
   function does_nothing() {
   }
  </script>
 </head>
 <body>
 <form action='http://bugs.kde.org'>
  <center>
   <table border='0' cellpadding='0' cellspacing='0'>
    <tr>
     <td align='center' valign='middle' nowrap>
      <table border='0' cellpadding='4' cellspacing='0'>
       <tr>
        <td align='center' valign='middle' rowspan=3 nowrap>
         <select name='testing' size=10>
          <option value='no'>Conquer your desktop with KDE.</option>
         </select>
        </td>
        <td align='center' valign='middle' nowrap>
         <input type='button' name='btn_does_nothing_1' value='Test 1' onclick='does_nothing();'>
        </td>
       </tr>
       <tr>
        <td align='center' valign='middle' nowrap>
         <input type='button' name='btn_empty' value='Empty!' onclick='remove_text(this.form);'>
        </td>
       </tr>
       <tr>
        <td align='center' valign='middle' nowrap>
         <input type='button' name='btn_does_nothing_3' value='Test 3' onclick='does_nothing();'>
        </td>
       </tr>
      </table>
     </td>
    </tr>
    <tr>
     <td align='center' valign='middle' nowrap>
      <input type='button' name='btn_put_text' value='Put a text' onclick='add_text(this.form);'>
      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
      <input type='button' name='btn_does_nothing_2' value='Test 2' onclick='does_nothing();'>
     </td>
    </tr>
   </table>
  </center>
 </form>
 </body>
</html>
<!-- End -->
Comment 1 Germain Garand 2005-02-23 04:13:13 UTC
Created attachment 9785 [details]
attaching testcase
Comment 2 Jure Repinc 2008-04-20 23:37:18 UTC
The bug is still present in Konqueror 3.5.9. The problem appears to be fixed in Konqueror 4 from trunk (kdelibs: 799193, kdebase: 799197).
Comment 3 James Spahlinger 2008-04-21 12:20:22 UTC
I'm also able to reproduce. The bug does not exist in 4.0.3 however.

Thanks for reporting this bug. I'm closing this with a time of LATER as it is fixed in a later version (4.x). What needs to be done is the changes need to be back ported from 4.x to 3.5.9.