xref: /aoo42x/main/sc/inc/fillinfo.hxx (revision 38d50f7b)
1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 
24 #ifndef SC_FILLINFO_HXX
25 #define SC_FILLINFO_HXX
26 
27 #include <svx/framelinkarray.hxx>
28 #include "global.hxx"
29 
30 class SfxItemSet;
31 class SvxBrushItem;
32 class SvxBoxItem;
33 class SvxLineItem;
34 class SvxShadowItem;
35 
36 class ScBaseCell;
37 class ScPatternAttr;
38 
39 // ============================================================================
40 
41 const sal_uInt8 SC_ROTDIR_NONE       = 0;
42 const sal_uInt8 SC_ROTDIR_STANDARD   = 1;
43 const sal_uInt8 SC_ROTDIR_LEFT       = 2;
44 const sal_uInt8 SC_ROTDIR_RIGHT      = 3;
45 const sal_uInt8 SC_ROTDIR_CENTER     = 4;
46 
47 const sal_uInt8 SC_CLIPMARK_NONE     = 0;
48 const sal_uInt8 SC_CLIPMARK_LEFT     = 1;
49 const sal_uInt8 SC_CLIPMARK_RIGHT    = 2;
50 const sal_uInt8 SC_CLIPMARK_SIZE     = 64;
51 
52 enum ScShadowPart
53 {
54 	SC_SHADOW_HSTART,
55 	SC_SHADOW_VSTART,
56 	SC_SHADOW_HORIZ,
57 	SC_SHADOW_VERT,
58 	SC_SHADOW_CORNER
59 };
60 
61 // ============================================================================
62 
63 struct CellInfo
64 {
65     ScBaseCell*                 pCell;
66 
67     const ScPatternAttr*        pPatternAttr;
68     const SfxItemSet*           pConditionSet;
69 
70     const SvxBrushItem*         pBackground;
71 
72     const SvxBoxItem*           pLinesAttr;         /// Original item from document.
73     const SvxLineItem*          mpTLBRLine;         /// Original item from document.
74     const SvxLineItem*          mpBLTRLine;         /// Original item from document.
75 
76     const SvxShadowItem*        pShadowAttr;            // Original-Item (intern)
77 
78     const SvxShadowItem*        pHShadowOrigin;
79     const SvxShadowItem*        pVShadowOrigin;
80 
81     ScShadowPart                eHShadowPart : 4;           // Schatten effektiv zum Zeichnen
82     ScShadowPart                eVShadowPart : 4;
83     sal_uInt8                        nClipMark;
84     sal_uInt16                      nWidth;
85     sal_uInt8                        nRotateDir;
86 
87     sal_Bool                        bMarked : 1;
88     sal_Bool                        bEmptyCellText : 1;
89 
90     sal_Bool                        bMerged : 1;
91     sal_Bool                        bHOverlapped : 1;
92     sal_Bool                        bVOverlapped : 1;
93     sal_Bool                        bAutoFilter : 1;
94     sal_Bool                        bPushButton : 1;
95     bool                        bPopupButton: 1;
96     bool                        bFilterActive:1;
97 
98     sal_Bool                        bPrinted : 1;               // bei Bedarf (Pagebreak-Modus)
99 
100     sal_Bool                        bHideGrid : 1;              // output-intern
101     sal_Bool                        bEditEngine : 1;            // output-intern
102 };
103 
104 const SCCOL SC_ROTMAX_NONE = SCCOL_MAX;
105 
106 // ============================================================================
107 
108 struct RowInfo
109 {
110     CellInfo*           pCellInfo;
111 
112     sal_uInt16              nHeight;
113     SCROW               nRowNo;
114     SCCOL               nRotMaxCol;         // SC_ROTMAX_NONE, wenn nichts
115 
116     sal_Bool                bEmptyBack;
117     sal_Bool                bEmptyText;
118     sal_Bool                bAutoFilter;
119     sal_Bool                bPushButton;
120     sal_Bool                bChanged;           // sal_True, wenn nicht getestet
121 
RowInfoRowInfo122     inline explicit     RowInfo() : pCellInfo( 0 ) {}
123 
124 private:
125                     RowInfo( const RowInfo& );
126     RowInfo&        operator=( const RowInfo& );
127 };
128 
129 // ============================================================================
130 
131 struct ScTableInfo
132 {
133     svx::frame::Array   maArray;
134     RowInfo*            mpRowInfo;
135     sal_uInt16              mnArrCount;
136     bool                mbPageMode;
137 
138     explicit            ScTableInfo();
139                         ~ScTableInfo();
140 
141 private:
142                         ScTableInfo( const ScTableInfo& );
143     ScTableInfo&        operator=( const ScTableInfo& );
144 };
145 
146 // ============================================================================
147 
148 #endif
149 
150