Details
Description
The attachment demonstrates a rendering problem where a Qt application is offset in the canvas based on other HTML elements in the DOM.
It is based on the Qt analog clock example.
– The HTML output file has been modified such that some lines of text are added above the qtcanvas.
– The text causes the canvas to be rendered with a vertical offset (shown as a black bar) equal to the height of the text.
– While this example doesn't show it, the problem also exists on the left side of the canvas as well, for instance, if there are HTML elements positioned on the left of the canvas element.
To run this example:
1) Open a cmd prompt in the extracted directory
2) Python -m SimpleHTTPServer 8080
3) Open Chrome and direct it to localhost:/8080/analogclock.html