1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
19 #ifndef INCLUDED_SW_SOURCE_CORE_INC_PTQUEUE_HXX
20 #define INCLUDED_SW_SOURCE_CORE_INC_PTQUEUE_HXX
23 * Unfortunately we have some problems with processing more than one Paint()
24 * at a time. This happens especially often during printing.
26 * SwRootFrame::PaintSwFrame() determines that it's called a second time and adds the
27 * rectangle and the corresponding Shell to the PaintCollector.
28 * The call sites that are causing the double Paint() only need to process the
29 * collected Paint()s at the right point in time.
30 * Doing this during printing (after having printed one page) is very suitable
33 * Invalidating windows directly from the RootFrame::PaintSwFrame was not a successful
34 * approach, because the Paint()s arrive at a very unfavourable point in time.
35 * Triggering an update for all windows after printing each page does not seem
36 * appropriate either: on the one hand we don't have direct access to the edit
37 * windows and on the other hand the updates can become very costly on some
48 static SwQueuedPaint
* s_pPaintQueue
;
50 static void Add(SwViewShell
* pSh
, const SwRect
& rNew
);
51 static void Remove(SwViewShell
const* pSh
);
52 static void Repaint();
57 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */