LibreOffice Module lotuswordpro (master) 1
lwppagelayout.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*************************************************************************
3 *
4 * The Contents of this file are made available subject to the terms of
5 * either of the following licenses
6 *
7 * - GNU Lesser General Public License Version 2.1
8 * - Sun Industry Standards Source License Version 1.1
9 *
10 * Sun Microsystems Inc., October, 2000
11 *
12 * GNU Lesser General Public License Version 2.1
13 * =============================================
14 * Copyright 2000 by Sun Microsystems, Inc.
15 * 901 San Antonio Road, Palo Alto, CA 94303, USA
16 *
17 * This library is free software; you can redistribute it and/or
18 * modify it under the terms of the GNU Lesser General Public
19 * License version 2.1, as published by the Free Software Foundation.
20 *
21 * This library is distributed in the hope that it will be useful,
22 * but WITHOUT ANY WARRANTY; without even the implied warranty of
23 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
24 * Lesser General Public License for more details.
25 *
26 * You should have received a copy of the GNU Lesser General Public
27 * License along with this library; if not, write to the Free Software
28 * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
29 * MA 02111-1307 USA
30 *
31 *
32 * Sun Industry Standards Source License Version 1.1
33 * =================================================
34 * The contents of this file are subject to the Sun Industry Standards
35 * Source License Version 1.1 (the "License"); You may not use this file
36 * except in compliance with the License. You may obtain a copy of the
37 * License at http://www.openoffice.org/license.html.
38 *
39 * Software provided under this License is provided on an "AS IS" basis,
40 * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
41 * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
42 * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
43 * See the License for the specific provisions governing your rights and
44 * obligations concerning the Software.
45 *
46 * The Initial Developer of the Original Code is: IBM Corporation
47 *
48 * Copyright: 2008 by IBM Corporation
49 *
50 * All Rights Reserved.
51 *
52 * Contributor(s): _______________________________________
53 *
54 *
55 ************************************************************************/
56
57#ifndef INCLUDED_LOTUSWORDPRO_SOURCE_FILTER_LWPPAGELAYOUT_HXX
58#define INCLUDED_LOTUSWORDPRO_SOURCE_FILTER_LWPPAGELAYOUT_HXX
59
60#include "lwplayout.hxx"
62
63class LwpHeaderLayout;
64class LwpFooterLayout;
65
66class LwpPageLayout final : public LwpLayout
67{
68public:
69 LwpPageLayout(LwpObjectHeader const& objHdr, LwpSvStream* pStrm);
70 virtual ~LwpPageLayout() override;
71 virtual void RegisterStyle() override;
72 OUString RegisterEndnoteStyle();
73 virtual void Parse(IXFStream* pOutputStream) override;
74 virtual LWP_LAYOUT_TYPE GetLayoutType() override { return LWP_PAGE_LAYOUT; }
75
76private:
77 void Read() override;
80 void ParseGeometry(XFPageMaster* pm1);
81 void ParseMargins(XFPageMaster* pm1);
82 void ParseBorders(XFPageMaster* pm1);
87 void ParseColumns(XFPageMaster* pm1);
88 void ParseShadow(XFPageMaster* pm1);
90 double GetMarginWidth();
91 void GetWidthAndHeight(double& fWidth, double& fHeight);
92 double GetWidth() override;
93 double GetHeight() override;
95 sal_uInt16 m_nPrinterBin;
96 sal_Int32 m_nBdroffset;
99
100public:
101 bool HasColumns();
102 bool HasFillerPageText(LwpFoundry const* pFoundry);
104 void ResetXFColumns();
106 virtual sal_Int32 GetPageNumber(sal_uInt16 nLayoutNumber) override;
107 bool operator<(LwpPageLayout& Other);
109};
110
112{
113public:
114 LwpHeaderLayout(LwpObjectHeader const& objHdr, LwpSvStream* pStrm);
115 virtual ~LwpHeaderLayout() override;
116 virtual LWP_LAYOUT_TYPE GetLayoutType() override { return LWP_HEADER_LAYOUT; }
118 void RegisterStyle(XFPageMaster* pm1);
119 void RegisterStyle(XFMasterPage* mp1);
120
121protected:
122 void Read() override;
123 void ParseMargins(XFHeaderStyle* ph1);
124 void ParseBorder(XFHeaderStyle* ph1);
125 void ParseShadow(XFHeaderStyle* ph1);
128 void ParseBackColor(XFHeaderStyle* ph1);
129
130 void ParseWaterMark(XFHeaderStyle* ph1);
131
132private:
134};
135
137{
138public:
139 LwpFooterLayout(LwpObjectHeader const& objHdr, LwpSvStream* pStrm);
140 virtual ~LwpFooterLayout() override;
141 virtual LWP_LAYOUT_TYPE GetLayoutType() override { return LWP_FOOTER_LAYOUT; }
143 void RegisterStyle(XFPageMaster* pm1);
144 void RegisterStyle(XFMasterPage* mp1);
145
146protected:
147 void Read() override;
148 void ParseMargins(XFFooterStyle* pFooterStyle);
149 void ParseBorder(XFFooterStyle* pFooterStyle);
150 void ParseShadow(XFFooterStyle* pFooterStyle);
151 void ParsePatternFill(XFFooterStyle* pFooterStyle);
152 void ParseBackGround(XFFooterStyle* pFooterStyle);
153
154 void ParseBackColor(XFFooterStyle* pFooterStyle);
155
156 void ParseWaterMark(XFFooterStyle* pFooterStyle);
157
158private:
160};
161
162#endif
163
164/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Stream wrapper for sax writer.
Definition: ixfstream.hxx:72
AtomHolder class of Word Pro to hold a string.
void ParseMargins(XFFooterStyle *pFooterStyle)
void ParseWaterMark(XFFooterStyle *pFooterStyle)
virtual ~LwpFooterLayout() override
void ParseBackColor(XFFooterStyle *pFooterStyle)
void ParsePatternFill(XFFooterStyle *pFooterStyle)
@descr: set footer back pattern
void ParseBackGround(XFFooterStyle *pFooterStyle)
@descr: set footer background
void ParseBorder(XFFooterStyle *pFooterStyle)
sal_Int32 m_nBorderOffset
virtual LWP_LAYOUT_TYPE GetLayoutType() override
void Read() override
@descr Read name of LwpDLNFVList from object stream
void ParseShadow(XFFooterStyle *pFooterStyle)
LwpFooterLayout(LwpObjectHeader const &objHdr, LwpSvStream *pStrm)
virtual ~LwpHeaderLayout() override
void ParseMargins(XFHeaderStyle *ph1)
sal_Int32 m_nBorderOffset
void ParseShadow(XFHeaderStyle *ph1)
void ParseBackColor(XFHeaderStyle *ph1)
LwpHeaderLayout(LwpObjectHeader const &objHdr, LwpSvStream *pStrm)
void ParsePatternFill(XFHeaderStyle *ph1)
@descr: set header back pattern
void ParseWaterMark(XFHeaderStyle *ph1)
virtual LWP_LAYOUT_TYPE GetLayoutType() override
void ParseBorder(XFHeaderStyle *ph1)
void Read() override
@descr Read name of LwpDLNFVList from object stream
void ParseBackGround(XFHeaderStyle *ph1)
@descr: set header background
Base class of all Lwp VO objects.
Definition: lwpobjhdr.hxx:71
virtual void RegisterStyle()
@descr default register style function
Definition: lwpobj.cxx:100
virtual void RegisterStyle() override
@descr: Register master page and page master style
void ParseBorders(XFPageMaster *pm1)
@descr: set page borders
bool HasFillerPageText(LwpFoundry const *pFoundry)
@descr: Whether has filler page text in current page layout
void ParseBackColor(XFPageMaster *pm1)
@descr: set page back color
LwpHeaderLayout * GetHeaderLayout()
bool HasColumns()
@descr: Whether current page layout has columns
virtual ~LwpPageLayout() override
LwpPageLayout * GetOddChildLayout()
@descr: Get the odd layout if current page layout is mirror page
LwpAtomHolder m_PaperName
sal_Int32 m_nBdroffset
virtual sal_Int32 GetPageNumber(sal_uInt16 nLayoutNumber) override
@descr: Get the pagenumber
void GetWidthAndHeight(double &fWidth, double &fHeight)
@descr: Get page width and height
void ParseColumns(XFPageMaster *pm1)
@descr: set page columns
OUString RegisterEndnoteStyle()
@descr: Register master page for endnote which name is "endnote"
void ParseBackGround(XFPageMaster *pm1)
@descr: set page background
void ParseFootNoteSeparator(XFPageMaster *pm1)
@descr: set page footnote separator information
void ConvertFillerPageText(XFContentContainer *pCont)
@descr: Parse filler page text
void ParsePatternFill(XFPageMaster *pm1)
@descr: set page back pattern
bool operator<(LwpPageLayout &Other)
@descr: Compare the position of layout.
void ParseGeometry(XFPageMaster *pm1)
@descr: set page height and width
sal_uInt16 m_nPrinterBin
void ResetXFColumns()
@descr: Clear columns style in page layout
double GetMarginWidth()
@descr: Get margin width of page
virtual LWP_LAYOUT_TYPE GetLayoutType() override
double GetHeight() override
@descr: Get page height
void ParseMargins(XFPageMaster *pm1)
@descr: set page margins
void ParseShadow(XFPageMaster *pm1)
@descr: set page shadow
void Read() override
@descr Read name of LwpDLNFVList from object stream
LwpPara * GetPagePosition()
@descr: Get the position of pagelayout
void ParseWaterMark(XFPageMaster *pm1)
@descr: set page watermark
LwpFooterLayout * GetFooterLayout()
virtual void Parse(IXFStream *pOutputStream) override
@descr default parse function
double GetWidth() override
@descr: Get page width
XFPageMaster * m_pXFPageMaster
LwpPageLayout(LwpObjectHeader const &objHdr, LwpSvStream *pStrm)
LwpAtomHolder m_PrinterBinName
encapsulate XInputStream to provide SvStream like interfaces
Definition: lwpsvstream.hxx:69
A container for content.