kword

KWFrameList.h
1/* This file is part of the KOffice project
2 * Copyright (C) 2005 Thomas Zander <zander@kde.org>
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; version 2.
7
8 * This library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 * Library General Public License for more details.
12 *
13 * You should have received a copy of the GNU Library General Public License
14 * along with this library; see the file COPYING.LIB. If not, write to
15 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
16 * Boston, MA 02110-1301, USA.
17 */
18#ifndef kw_framelist_h
19#define kw_framelist_h
20
21#include "KWFrame.h"
22
23#include <tqptrlist.h>
24#include <tqvaluevector.h>
25
26class KWDocument;
27
33public:
39 KWFrameList(KWDocument *doc, KWFrame *theFrame);
40
44 TQValueList<KWFrame *> framesBelow() const;
45
49 TQValueList<KWFrame *> framesOnTop() const;
50
58 void updateAfterMove(int oldPageNum);
59
64 void update();
65
70 static void recalcAllFrames(KWDocument *doc);
71
78 static void recalcFrames(KWDocument *doc, int pageFrom, int pageTo);
79
86 static void createFrameList(KWFrame *f, KWDocument *doc);
87
99 static void createFrameList(KWFrameSet *fs, KWDocument *doc, bool forceUpdate=true);
100
101private:
102 static KWFrameList *getFirstFrameList(KWDocument *doc);
103 void updateZOrderFor(const TQPtrList<KWFrame> &frames);
104 void setFrames(const TQPtrList<KWFrame> &frames);
105
106 TQValueVector<KWFrame *> m_frames; // sorted by Z Order
107 KWDocument *m_doc;
108 KWFrame *m_frame;
109};
110
111#endif
This class calculates and caches a list of frames that are on top or below the KWFrame instance this ...
Definition KWFrameList.h:32
static void recalcAllFrames(KWDocument *doc)
Update the z-ordering for all frames of the whole document.
void update()
Update the z-ordering around the frame we host the framelist for.
TQValueList< KWFrame * > framesBelow() const
Fetches the frames below the frame this frameList is for.
static void recalcFrames(KWDocument *doc, int pageFrom, int pageTo)
Update the z-ordering for all frames in the page section of the whole document.
void updateAfterMove(int oldPageNum)
Update the z-ordering around the frame we host the framelist for.
static void createFrameList(KWFrame *f, KWDocument *doc)
Factory method to create and attach a new instance of a framelist.
TQValueList< KWFrame * > framesOnTop() const
Fetches the frames on top of the frame this frameList is for.
Class: KWFrameSet Base type, a frameset holds content as well as frames to show that content.
Definition KWFrameSet.h:62
This class represents a single frame.
Definition KWFrame.h:68