qt-interest@trolltech.com
[Top] [All Lists]

[Qt-interest] Work around screen resolution in QWebView and/or JavaScrip

Subject: [Qt-interest] Work around screen resolution in QWebView and/or JavaScript
From: Dirk Stöcker
Date: Wed, 17 Dec 2008 18:07:56 +0100 CET
Hello,

I got no answer the first time, so I try it a second time. I really found no 
solution for that problem, so any help is recommended.

I wrote a little Qt tool using WebKit to download a webpage as image. Now this 
works fine as long as the webpage is smaller than the physical screen or no 
JavaScript is involved.

The source is here:
http://svn.openstreetmap.org/applications/editors/josm/plugins/wmsplugin/webkit-image.cpp

It is pretty easy piece of source :-)

Now when I call this:
./webkit-image http://www.dstoecker.eu/ymap.html >x.jpg

the output file is reduced to my physical screen size of 1200 pixels in height 
due to the JavaScript code involved.

To get it working nevertheless I tried to convince Qt that I have no 1920x1200 
screen, but a much larger one, but till now I failed.

So my questions are:
a) Is there a way to convince the WebKit part of Qt to assume I have a much 
larger screen (maybe a way to convince JavaScript only)?
b) Is there a way to convince the whole Application that I have a larger 
screen?
c) Is there any other way how I can convince the whole software that it should 
use 2000x2000 instead of my physical screen limits?

The software does not show anything, so it really should not care for the 
physical screen dimensions.

Ciao
-- 
http://www.dstoecker.eu/ (PGP key available)
_______________________________________________
Qt-interest mailing list
Qt-interest@xxxxxxxxxxxxx
http://lists.trolltech.com/mailman/listinfo/qt-interest

<Prev in Thread] Current Thread [Next in Thread>