Customizable Print Formats GSoC 2015

Gehad Elrobey gehadelrobey at gmail.com
Sat Mar 7 14:23:38 PST 2015


On Sun, Mar 8, 2015 at 12:11 AM, Lubomir I. Ivanov <neolit123 at gmail.com>
wrote:

> On 7 March 2015 at 23:47, Lubomir I. Ivanov <neolit123 at gmail.com> wrote:
> >
> > one thing to figure out is how are we going to embed the profile
> pictures...
> > if we are capturing the output of a QWebPage then we first need to
> > show the profiles in there.
> > for that <img src="data: metatype, base64, theDataGoesHere" /> can be
> used.
>
> now, there is an alternative for all that, but it's tricky...
> since we can use QWebFrame::render() on a QPainter that uses the
> QPrinter as paint device, in theory we can position a QPicture of the
> profile exactly over the already rendered profile HTML frame (e.g. in
> your PDF that would be "dive profile area"), but that's only in
> theory.
>

I was thinking of using Grantlee to generate parts of the HTML code, one
part for each widget that will be placed in the layout dynamically, we can
also insert the profile photos dynamically as the HTML code.

So the Qt class will call Grantlee many times to fill in the <div> s (or
widgets in the main layout) dynamically and generate the full html code
that can be rendered by QWebPage and printed.

-- 
regards,
Gehad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.subsurface-divelog.org/pipermail/subsurface/attachments/20150308/4fbdf783/attachment.html>


More information about the subsurface mailing list