Hi Andrew,
Sorry for the delay... I had a pretty long week-end here ;)
On Fri, 2012-04-27 at 18:08 +0100, Andrew Higginson wrote:
On 27 April 2012 18:01, Cedric Bosdonnat <cbosdonnat@suse.com> wrote:
You will need to create your own control for that with your
own Paint()
implementation. You should get some inspiration from the
SwHeaderFooterWin class:
http://cgit.freedesktop.org/libreoffice/core/tree/sw/source/ui/docvw/HeaderFooterWin.cxx
Do you think that it is necessary to do that? Would adding some
drawing code in the correct Paint() method not suffice?
I'm sure it won't suffice. The reason is pretty simple: when scrolling
the document horizontally or vertically, the visible region of the
document is simply moved and only the missing part is computed and added
to the display. This will necessarily lead into some drawing artifacts
with something painted over the document.
What you need to understand is that the whole document is rendered as a
single window control. If you create a new kind of Control as I
mentioned, it will be completely separated from the document and thus
there will be no problem with the refresh / scrolling.
--
Cedric
Context
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.