Update ooo320-m1
[ooovba.git] / sw / inc / printdata.hxx
blob7ecfe08ec5c43904c0bbe389f19b6b379889a150
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: printdata.hxx,v $
10 * $Revision: 1.11 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef _SW_PRINTDATA_HXX
31 #define _SW_PRINTDATA_HXX
34 #include <sal/types.h>
35 #include <rtl/ustring.hxx>
37 struct SwPrintData
39 sal_Bool bPrintGraphic, bPrintTable, bPrintDraw, bPrintControl, bPrintPageBackground,
40 bPrintBlackFont,
41 //#i81434# - printing of hidden text
42 bPrintHiddenText, bPrintTextPlaceholder,
43 bPrintLeftPage, bPrintRightPage, bPrintReverse, bPrintProspect,
44 bPrintProspect_RTL,
45 bPrintSingleJobs, bPaperFromSetup,
46 // --> FME 2005-12-13 #b6354161# Print empty pages
47 bPrintEmptyPages,
48 // <--
49 // #i56195# no field update while printing mail merge documents
50 bUpdateFieldsInPrinting,
51 bModified;
53 sal_Int16 nPrintPostIts;
54 rtl::OUString sFaxName;
56 SwPrintData()
58 bPrintGraphic =
59 bPrintTable =
60 bPrintDraw =
61 bPrintControl =
62 bPrintLeftPage =
63 bPrintRightPage =
64 bPrintPageBackground =
65 bPrintEmptyPages =
66 bUpdateFieldsInPrinting = sal_True;
68 bPaperFromSetup =
69 bPrintReverse =
70 bPrintProspect =
71 bPrintProspect_RTL =
72 bPrintSingleJobs =
73 bModified =
74 bPrintBlackFont =
75 bPrintHiddenText =
76 bPrintTextPlaceholder = sal_False;
78 nPrintPostIts = 0;
81 virtual ~SwPrintData() {}
83 sal_Bool operator==(const SwPrintData& rData)const
85 return
86 bPrintGraphic == rData.bPrintGraphic &&
87 bPrintTable == rData.bPrintTable &&
88 bPrintDraw == rData.bPrintDraw &&
89 bPrintControl == rData.bPrintControl &&
90 bPrintPageBackground== rData.bPrintPageBackground&&
91 bPrintBlackFont == rData.bPrintBlackFont &&
92 bPrintLeftPage == rData.bPrintLeftPage &&
93 bPrintRightPage == rData.bPrintRightPage &&
94 bPrintReverse == rData.bPrintReverse &&
95 bPrintProspect == rData.bPrintProspect &&
96 bPrintProspect_RTL == rData.bPrintProspect_RTL &&
97 bPrintSingleJobs == rData.bPrintSingleJobs &&
98 bPaperFromSetup == rData.bPaperFromSetup &&
99 bPrintEmptyPages == rData.bPrintEmptyPages &&
100 bUpdateFieldsInPrinting == rData.bUpdateFieldsInPrinting &&
101 nPrintPostIts == rData.nPrintPostIts &&
102 sFaxName == rData.sFaxName &&
103 bPrintHiddenText == rData.bPrintHiddenText &&
104 bPrintTextPlaceholder == rData.bPrintTextPlaceholder;
106 sal_Bool IsPrintGraphic() const { return bPrintGraphic; }
107 sal_Bool IsPrintTable() const { return bPrintTable; }
108 sal_Bool IsPrintDraw() const { return bPrintDraw; }
109 sal_Bool IsPrintControl() const { return bPrintControl; }
110 sal_Bool IsPrintLeftPage() const { return bPrintLeftPage; }
111 sal_Bool IsPrintRightPage() const { return bPrintRightPage; }
112 sal_Bool IsPrintReverse() const { return bPrintReverse; }
113 sal_Bool IsPaperFromSetup() const { return bPaperFromSetup; }
114 sal_Bool IsPrintEmptyPages() const{ return bPrintEmptyPages; }
115 sal_Bool IsPrintProspect() const { return bPrintProspect; }
116 sal_Bool IsPrintProspect_RTL() const { return bPrintProspect_RTL; }
117 sal_Bool IsPrintPageBackground() const { return bPrintPageBackground; }
118 sal_Bool IsPrintBlackFont() const { return bPrintBlackFont;}
119 sal_Bool IsPrintSingleJobs() const { return bPrintSingleJobs;}
120 sal_Int16 GetPrintPostIts() const { return nPrintPostIts; }
121 const rtl::OUString GetFaxName() const{return sFaxName;}
122 sal_Bool IsPrintHiddenText() const {return bPrintHiddenText;}
123 sal_Bool IsPrintTextPlaceholder() const {return bPrintTextPlaceholder;}
125 void SetPrintGraphic ( sal_Bool b ) { doSetModified(); bPrintGraphic = b;}
126 void SetPrintTable ( sal_Bool b ) { doSetModified(); bPrintTable = b;}
127 void SetPrintDraw ( sal_Bool b ) { doSetModified(); bPrintDraw = b;}
128 void SetPrintControl ( sal_Bool b ) { doSetModified(); bPrintControl = b; }
129 void SetPrintLeftPage ( sal_Bool b ) { doSetModified(); bPrintLeftPage = b;}
130 void SetPrintRightPage( sal_Bool b ) { doSetModified(); bPrintRightPage = b;}
131 void SetPrintReverse ( sal_Bool b ) { doSetModified(); bPrintReverse = b;}
132 void SetPaperFromSetup( sal_Bool b ) { doSetModified(); bPaperFromSetup = b;}
133 void SetPrintEmptyPages(sal_Bool b ) { doSetModified(); bPrintEmptyPages = b;}
134 void SetPrintPostIts ( sal_Int16 n){ doSetModified(); nPrintPostIts = n; }
135 void SetPrintProspect ( sal_Bool b ) { doSetModified(); bPrintProspect = b; }
136 void SetPrintProspect_RTL ( sal_Bool b ) { doSetModified(); bPrintProspect_RTL = b; }
137 void SetPrintPageBackground(sal_Bool b){ doSetModified(); bPrintPageBackground = b;}
138 void SetPrintBlackFont(sal_Bool b){ doSetModified(); bPrintBlackFont = b;}
139 void SetPrintSingleJobs(sal_Bool b){ doSetModified(); bPrintSingleJobs = b;}
140 void SetFaxName(const rtl::OUString& rSet){sFaxName = rSet;}
141 void SetPrintHiddenText(sal_Bool b){ doSetModified(); bPrintHiddenText = b;}
142 void SetPrintTextPlaceholder(sal_Bool b){ doSetModified(); bPrintTextPlaceholder = b;}
143 virtual void doSetModified () { bModified = sal_True;}
146 #endif //_SW_PRINTDATA_HXX