[Using QtWebkit from Qt4.5.0]
Attached are test cases [source HTML and image] for several issues;
First, the "double" border style causes the next following instance of a dotted or dashed border to render the top with 1px width.
Second, nesting a div with a border inside of a div with a 1px dashed or dotted causes the child div to overlap the left border, as if the whole child div were moved up and to the left by one pixel.
Third, the dotted border actually features short dashes instead of the expected dots, and the left and right borders do not render all the way to the bottom of the div. Bottom border is potentially a pixel too low.
Created attachment 28448 [details]
HTML Testcase Source
Created attachment 28449 [details]
Screenshot of HTML Testcase
For the "Third" problem I have tested and confirmed that this is a problem with QPen. It does not draw dots when the width of the pen != 0 (e.g. it is not cosmetic). Investigating the rest and looking for solutions to the "Third" problem.
Another update about the "Third" problem. When I use -graphicssystem raster then it draws with dots even if not using cosmetic pen. This indicates the dashes with non-cosmetic pens is a problem in Qt with qpaintengine_x11.cpp.
Also, I've found that there is a problem with the bottom border no matter the paint engine. This is most likely an off-by-one error somewhere in the border drawing code in RenderObject or in GraphicsContextQt.cpp. Still trying to nail it down.
Created attachment 28570 [details]
Fix for Qt port
A refactor to share this code between the ports will follow.
Landed with r41659.