xref: /trunk/main/sc/source/filter/inc/otlnbuff.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_OTLNBUFF_HXX
25 #define SC_OTLNBUFF_HXX
26 
27 #include <tools/solar.h>
28 
29 class ScOutlineArray;
30 
31 class XclImpOutlineBuffer
32 {
33 	// -> exctools.cxx
34 	private:
35 		sal_uInt8*			pLevel;
36 		sal_Bool*			pOuted;
37 		sal_Bool*			pHidden;
38 		SCSIZE			nSize;
39 		SCSIZE			nLast;
40 		sal_uInt8			nMaxLevel;
41 		ScOutlineArray*	pOutlineArray;
42 		sal_Bool			bButtonNormal;	// sal_True -> right / under
43 	public:
44                         XclImpOutlineBuffer( SCSIZE nNewSize );
45                         ~XclImpOutlineBuffer();
46 		void			SetLevel( SCSIZE nIndex, sal_uInt8 nVal, sal_Bool bOuted, sal_Bool bHidden );
47 		void			SetOutlineArray( ScOutlineArray* pOArray );
48 		void			Reset( void );
49 		void			MakeScOutline( void );
50 		void			SetLevelRange( SCSIZE nF, SCSIZE nL, sal_uInt8 nVal,
51 							sal_Bool bOuted, sal_Bool bHidden );
52 
53 		inline sal_Bool		HasOutline( void ) const;
54 
55 		inline void		SetButtonMode( const sal_Bool bRightOrUnder );
56 };
57 
58 
59 
60 
HasOutline(void) const61 inline sal_Bool XclImpOutlineBuffer::HasOutline( void ) const
62 {
63 	return nMaxLevel > 0;
64 }
65 
66 
SetButtonMode(const sal_Bool b)67 inline void XclImpOutlineBuffer::SetButtonMode( const sal_Bool b )
68 {
69 	bButtonNormal = b;
70 }
71 
72 
73 #endif
74 
75