LibreOffice Module sc (master) 1
xlstyle.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#pragma once
21
22#include <map>
23#include <com/sun/star/awt/FontSlant.hpp>
24#include <tools/color.hxx>
25#include <tools/fontenum.hxx>
26#include <editeng/svxenum.hxx>
27#include <editeng/frmdir.hxx>
28#include <svl/zforlist.hxx>
29#include "fapihelper.hxx"
30
31class XclRoot;
32
33// Constants and Enumerations =================================================
34
35// Line styles ----------------------------------------------------------------
36
51
52// Background patterns --------------------------------------------------------
53
61
62// (0x001E, 0x041E) FORMAT ----------------------------------------------------
63
64const sal_uInt16 EXC_ID2_FORMAT = 0x001E;
65const sal_uInt16 EXC_ID4_FORMAT = 0x041E;
66
67const sal_uInt16 EXC_FORMAT_OFFSET5 = 164;
68const sal_uInt16 EXC_FORMAT_OFFSET8 = 164;
69const sal_uInt16 EXC_FORMAT_NOTFOUND = 0xFFFF;
70
71// (0x0031) FONT --------------------------------------------------------------
72
73const sal_uInt16 EXC_ID2_FONT = 0x0031;
74const sal_uInt16 EXC_ID3_FONT = 0x0231;
75
76const sal_uInt16 EXC_FONT_APP = 0;
77const sal_uInt16 EXC_FONT_NOTFOUND = 0xFFFF;
78
79const size_t EXC_FONT_MAXCOUNT4 = 0x00FF;
80const size_t EXC_FONT_MAXCOUNT5 = 0x00FF;
81const size_t EXC_FONT_MAXCOUNT8 = 0xFFFF;
82
83// families
91
92// charsets
94
95// attributes
96const sal_uInt16 EXC_FONTATTR_NONE = 0x0000;
97const sal_uInt16 EXC_FONTATTR_BOLD = 0x0001;
98const sal_uInt16 EXC_FONTATTR_ITALIC = 0x0002;
99const sal_uInt16 EXC_FONTATTR_UNDERLINE = 0x0004;
100const sal_uInt16 EXC_FONTATTR_STRIKEOUT = 0x0008;
101const sal_uInt16 EXC_FONTATTR_OUTLINE = 0x0010;
102const sal_uInt16 EXC_FONTATTR_SHADOW = 0x0020;
103
104// weight
105const sal_uInt16 EXC_FONTWGHT_DONTKNOW = 0;
106const sal_uInt16 EXC_FONTWGHT_THIN = 100;
107const sal_uInt16 EXC_FONTWGHT_ULTRALIGHT = 200;
108const sal_uInt16 EXC_FONTWGHT_LIGHT = 300;
109const sal_uInt16 EXC_FONTWGHT_SEMILIGHT = 350;
110const sal_uInt16 EXC_FONTWGHT_NORMAL = 400;
111const sal_uInt16 EXC_FONTWGHT_MEDIUM = 500;
112const sal_uInt16 EXC_FONTWGHT_SEMIBOLD = 600;
113const sal_uInt16 EXC_FONTWGHT_BOLD = 700;
114const sal_uInt16 EXC_FONTWGHT_ULTRABOLD = 800;
115const sal_uInt16 EXC_FONTWGHT_BLACK = 900;
116
117// underline
123
124// escapement
125const sal_uInt16 EXC_FONTESC_NONE = 0x00;
126const sal_uInt16 EXC_FONTESC_SUPER = 0x01;
127const sal_uInt16 EXC_FONTESC_SUB = 0x02;
128
129// (0x0043, 0x0243, 0x0443, 0x00E0) XF ----------------------------------------
130
131const sal_uInt16 EXC_ID2_XF = 0x0043;
132const sal_uInt16 EXC_ID3_XF = 0x0243;
133const sal_uInt16 EXC_ID4_XF = 0x0443;
134const sal_uInt16 EXC_ID5_XF = 0x00E0;
135
136const sal_uInt32 EXC_XF_MAXCOUNT = 4050;
137const sal_uInt32 EXC_XF_MAXSTYLECOUNT = 1536;
138const sal_uInt16 EXC_XF_DEFAULTSTYLE = 0;
139const sal_uInt16 EXC_XF_DEFAULTCELL = 15;
140const sal_uInt16 EXC_XF_NOTFOUND = 0xFFFF;
141
142const sal_uInt32 EXC_XFID_NOTFOUND = 0xFFFFFFFF;
143
144const sal_uInt16 EXC_XF_LOCKED = 0x0001;
145const sal_uInt16 EXC_XF_HIDDEN = 0x0002;
146const sal_uInt16 EXC_XF_STYLE = 0x0004;
147const sal_uInt16 EXC_XF_STYLEPARENT = 0x0FFF;
148const sal_uInt16 EXC_XF_LINEBREAK = 0x0008;
149const sal_uInt16 EXC_XF_SHRINK = 0x0010;
150
157
166
172
176
185
186const sal_uInt16 EXC_XF8_SHRINK = 0x0010;
187const sal_uInt16 EXC_XF8_MERGE = 0x0020;
188
189const sal_uInt32 EXC_XF_DIAGONAL_TL_TO_BR = 0x40000000;
190const sal_uInt32 EXC_XF_DIAGONAL_BL_TO_TR = 0x80000000;
191const sal_uInt32 EXC_XF_DIAGONAL_BOTH = 0xC0000000;
192
193// (0x0045) EFONT -------------------------------------------------------------
194
195const sal_uInt16 EXC_ID_EFONT = 0x0045;
196
197// (0x0092) PALETTE -----------------------------------------------------------
198
199const sal_uInt16 EXC_ID_PALETTE = 0x0092;
200
201const sal_uInt16 EXC_COLOR_BIFF2_BLACK = 0;
202const sal_uInt16 EXC_COLOR_BIFF2_WHITE = 1;
203
204const sal_uInt16 EXC_COLOR_USEROFFSET = 8;
205const sal_uInt16 EXC_COLOR_WINDOWTEXT3 = 24;
206const sal_uInt16 EXC_COLOR_WINDOWBACK3 = 25;
207const sal_uInt16 EXC_COLOR_WINDOWTEXT = 64;
208const sal_uInt16 EXC_COLOR_WINDOWBACK = 65;
209const sal_uInt16 EXC_COLOR_BUTTONBACK = 67;
210const sal_uInt16 EXC_COLOR_CHWINDOWTEXT = 77;
211const sal_uInt16 EXC_COLOR_CHWINDOWBACK = 78;
212const sal_uInt16 EXC_COLOR_CHBORDERAUTO = 79;
213const sal_uInt16 EXC_COLOR_NOTEBACK = 80;
214const sal_uInt16 EXC_COLOR_NOTETEXT = 81;
215const sal_uInt16 EXC_COLOR_FONTAUTO = 0x7FFF;
216
217// (0x0293) STYLE -------------------------------------------------------------
218
219const sal_uInt16 EXC_ID_STYLE = 0x0293;
220
221const sal_uInt16 EXC_STYLE_BUILTIN = 0x8000;
222const sal_uInt16 EXC_STYLE_XFMASK = 0x0FFF;
223
235
238
239// (0x0892) STYLEEXT ----------------------------------------------------------
240
241const sal_uInt16 EXC_ID_STYLEEXT = 0x0892;
242
246
247// Color data =================================================================
248
251{
252public:
253 explicit XclDefaultPalette( const XclRoot& rRoot );
254
256 sal_uInt32 GetColorCount() const { return mnTableSize - EXC_COLOR_USEROFFSET; }
257
259 Color GetDefColor( sal_uInt16 nXclIndex ) const;
260
262 bool IsSystemColor( sal_uInt16 nXclIndex ) const { return nXclIndex >= mnTableSize; }
263
264private:
269 sal_uInt32 mnTableSize;
270};
271
272// Font data ==================================================================
273
274namespace vcl { class Font; }
275class SvxFont;
276
284{
285 OUString maName;
286 OUString maStyle;
288 sal_uInt16 mnHeight;
289 sal_uInt16 mnWeight;
290 sal_uInt16 mnEscapem;
294 bool mbItalic;
297 bool mbShadow;
298
300 explicit XclFontData();
302 explicit XclFontData( const vcl::Font& rFont );
304 explicit XclFontData( const SvxFont& rFont );
305
307 void Clear();
309 void FillFromVclFont( const vcl::Font& rFont );
311 void FillFromSvxFont( const SvxFont& rFont );
312
313// *** conversion of VCL/SVX constants *** ------------------------------------
314
316 FontFamily GetScFamily( rtl_TextEncoding eDefTextEnc ) const;
318 rtl_TextEncoding GetFontEncoding() const;
320 FontItalic GetScPosture() const;
322 FontWeight GetScWeight() const;
329
331 void SetScHeight( sal_Int32 nTwips );
333 void SetScFamily( FontFamily eScFamily );
335 void SetFontEncoding( rtl_TextEncoding eFontEnc );
337 void SetScPosture( FontItalic eScPosture );
339 void SetScWeight( FontWeight eScWeight );
341 void SetScUnderline( FontLineStyle eScUnderl );
343 void SetScEscapement( short nScEscapem );
345 void SetScStrikeout( FontStrikeout eScStrikeout );
346
347// *** conversion of API constants *** ----------------------------------------
348
350 float GetApiHeight() const;
352 sal_Int16 GetApiFamily() const;
354 sal_Int16 GetApiFontEncoding() const;
356 css::awt::FontSlant GetApiPosture() const;
358 float GetApiWeight() const;
360 sal_Int16 GetApiUnderline() const;
362 sal_Int16 GetApiEscapement() const;
364 sal_Int16 GetApiStrikeout() const;
365
367 void SetApiHeight( float fPoint );
369 void SetApiFamily( sal_Int16 nApiFamily );
371 void SetApiPosture( css::awt::FontSlant eApiPosture );
373 void SetApiWeight( float fApiWeight );
375 void SetApiUnderline( sal_Int16 nApiUnderl );
377 void SetApiEscapement( sal_Int16 nApiEscapem );
379 void SetApiStrikeout( sal_Int16 nApiStrikeout );
380};
381
382bool operator==( const XclFontData& rLeft, const XclFontData& rRight );
383
386{
387 Cell,
388 Editeng,
390};
391
394{
398
401{
402public:
403 explicit XclFontPropSetHelper();
404
406 void ReadFontProperties( XclFontData& rFontData,
407 const ScfPropertySet& rPropSet, XclFontPropSetType eType,
408 sal_Int16 nScript = -1 );
409
413 const XclFontData& rFontData,
414 bool bHasWstrn, bool bHasAsian, bool bHasCmplx,
415 const Color* pFontColor );
416
417private:
419 ScfPropSetHelper& GetChartHelper( sal_Int16 nScript );
420
421private:
431};
432
433// Number formats =============================================================
434
436{
437 OUString maFormat;
440};
441
443{
444public:
445 explicit XclNumFmtBuffer( const XclRoot& rRoot );
446
448 sal_uInt32 GetStdScNumFmt() const { return mnStdScNumFmt; }
449
450protected:
451 typedef ::std::map< sal_uInt16, XclNumFmt > XclNumFmtMap;
452
454 void InitializeImport();
455
457 const XclNumFmtMap& GetFormatMap() const { return maFmtMap; }
458
460 void InsertFormat( sal_uInt16 nXclNumFmt, const OUString& rFormat );
461
462private:
465
468 const sal_uInt32 mnStdScNumFmt;
469};
470
471// Cell formatting data (XF) ==================================================
472
475{
476 bool mbLocked;
477 bool mbHidden;
478
479 explicit XclCellProt();
480};
481
482bool operator==( const XclCellProt& rLeft, const XclCellProt& rRight );
483
486{
494 bool mbShrink;
495
496 explicit XclCellAlign();
497
508
510 void SetScHorAlign( SvxCellHorJustify eHorJust );
512 void SetScVerAlign( SvxCellVerJustify eVerJust );
514 void SetScFrameDir( SvxFrameDirection eFrameDir );
515};
516
517bool operator==( const XclCellAlign& rLeft, const XclCellAlign& rRight );
518
521{
522 sal_uInt16 mnLeftColor;
523 sal_uInt16 mnRightColor;
524 sal_uInt16 mnTopColor;
525 sal_uInt16 mnBottomColor;
526 sal_uInt16 mnDiagColor;
534
535 explicit XclCellBorder();
536};
537
538bool operator==( const XclCellBorder& rLeft, const XclCellBorder& rRight );
539
542{
543 sal_uInt16 mnForeColor;
544 sal_uInt16 mnBackColor;
546
547 explicit XclCellArea();
548 explicit XclCellArea(sal_uInt8 nPattern);
549
551 bool IsTransparent() const;
552};
553
554bool operator==( const XclCellArea& rLeft, const XclCellArea& rRight );
555
561{
562public:
563 explicit XclXFBase( bool bCellXF );
564 virtual ~XclXFBase();
565
566 XclXFBase(XclXFBase const &) = default;
567 XclXFBase(XclXFBase &&) = default;
568 XclXFBase & operator =(XclXFBase const &) = default;
570
572 void SetAllUsedFlags( bool bUsed );
574 bool HasUsedFlags() const;
575
577 bool IsCellXF() const { return mbCellXF; }
579 bool IsStyleXF() const { return !IsCellXF(); }
580
581protected:
583 bool Equals( const XclXFBase& rCmp ) const;
584
585protected:
586 sal_uInt16 mnParent;
587 bool mbCellXF;
594};
595
596/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Generic helper class for reading from and writing to property sets.
Definition: fapihelper.hxx:214
A wrapper for a UNO property set.
Definition: fapihelper.hxx:104
Stores all default colors for a specific BIFF version.
Definition: xlstyle.hxx:251
sal_uInt32 GetColorCount() const
Returns the color count in the current palette.
Definition: xlstyle.hxx:256
XclDefaultPalette(const XclRoot &rRoot)
Definition: xlstyle.cxx:92
Color mnNoteText
System button background color.
Definition: xlstyle.hxx:267
Color GetDefColor(sal_uInt16 nXclIndex) const
Returns the default color for a (non-zero-based) Excel color or COL_AUTO on error.
Definition: xlstyle.cxx:140
const Color * mpnColorTable
Definition: xlstyle.hxx:265
bool IsSystemColor(sal_uInt16 nXclIndex) const
Returns true, if the passed Excel color index is a system color.
Definition: xlstyle.hxx:262
Color mnNoteBack
Note text color.
Definition: xlstyle.hxx:268
sal_uInt32 mnTableSize
Note background color.
Definition: xlstyle.hxx:269
Color mnFaceColor
The table with RGB values.
Definition: xlstyle.hxx:266
Helper class for usage of property sets.
Definition: xlstyle.hxx:401
ScfPropSetHelper maHlpChAsian
Chart properties for Western script.
Definition: xlstyle.hxx:424
ScfPropSetHelper maHlpChWstrnNoName
Chart properties for Complex script.
Definition: xlstyle.hxx:426
ScfPropSetHelper maHlpChAsianNoName
Chart properties for Western script, no font name.
Definition: xlstyle.hxx:427
void ReadFontProperties(XclFontData &rFontData, const ScfPropertySet &rPropSet, XclFontPropSetType eType, sal_Int16 nScript=-1)
Reads all font properties from the passed property set.
Definition: xlstyle.cxx:623
ScfPropSetHelper maHlpControl
Chart properties for font escapement.
Definition: xlstyle.hxx:430
ScfPropSetHelper maHlpChCommon
Definition: xlstyle.hxx:422
void WriteFontProperties(ScfPropertySet &rPropSet, XclFontPropSetType eType, const XclFontData &rFontData, bool bHasWstrn, bool bHasAsian, bool bHasCmplx, const Color *pFontColor)
Writes all font properties to the passed property set, uses passed color as font color.
Definition: xlstyle.cxx:691
ScfPropSetHelper maHlpChEscapement
Chart properties for Complex script, no font name.
Definition: xlstyle.hxx:429
ScfPropSetHelper maHlpChCmplx
Chart properties for Asian script.
Definition: xlstyle.hxx:425
ScfPropSetHelper maHlpChCmplxNoName
Chart properties for Asian script, no font name.
Definition: xlstyle.hxx:428
ScfPropSetHelper & GetChartHelper(sal_Int16 nScript)
Returns a chart property set helper according to the passed script type.
Definition: xlstyle.cxx:743
ScfPropSetHelper maHlpChWstrn
Chart properties for all scripts.
Definition: xlstyle.hxx:423
void InsertFormat(sal_uInt16 nXclNumFmt, const OUString &rFormat)
Inserts a new number format for the specified Excel format index.
Definition: xlstyle.cxx:1468
void InsertBuiltinFormats()
Inserts built-in number formats for the current system language.
Definition: xlstyle.cxx:1477
void InitializeImport()
Clears all buffered data, used to set up for a new sheet.
Definition: xlstyle.cxx:1463
::std::map< sal_uInt16, XclNumFmt > XclNumFmtMap
Definition: xlstyle.hxx:451
XclNumFmtBuffer(const XclRoot &rRoot)
Definition: xlstyle.cxx:1453
XclNumFmtMap maFmtMap
Definition: xlstyle.hxx:466
sal_uInt32 GetStdScNumFmt() const
Returns the core index of the current standard number format.
Definition: xlstyle.hxx:448
const sal_uInt32 mnStdScNumFmt
Current system language.
Definition: xlstyle.hxx:468
const LanguageType meSysLang
Map containing all default and user-defined formats.
Definition: xlstyle.hxx:467
const XclNumFmtMap & GetFormatMap() const
Returns the current number format map.
Definition: xlstyle.hxx:457
Access to global data for a filter object (imported or exported document) from other classes.
Definition: xlroot.hxx:128
Contains base members for XF record import/export.
Definition: xlstyle.hxx:561
bool mbBorderUsed
true = alignment used.
Definition: xlstyle.hxx:592
bool IsCellXF() const
Returns true, if this is a hard cell format.
Definition: xlstyle.hxx:577
bool mbAreaUsed
true = border data used.
Definition: xlstyle.hxx:593
bool IsStyleXF() const
Returns true, if this is a cell style.
Definition: xlstyle.hxx:579
XclXFBase(XclXFBase &&)=default
bool mbProtUsed
true = cell XF, false = style XF.
Definition: xlstyle.hxx:588
bool HasUsedFlags() const
Returns true, if any "attribute used" flags are ste in this XF.
Definition: xlstyle.cxx:1730
XclXFBase(XclXFBase const &)=default
bool mbFmtUsed
true = font index used.
Definition: xlstyle.hxx:590
sal_uInt16 mnParent
Definition: xlstyle.hxx:586
bool mbAlignUsed
true = number format used.
Definition: xlstyle.hxx:591
bool mbCellXF
Index to parent style XF.
Definition: xlstyle.hxx:587
XclXFBase & operator=(XclXFBase const &)=default
bool Equals(const XclXFBase &rCmp) const
Returns true, if this object is equal to the passed.
Definition: xlstyle.cxx:1735
void SetAllUsedFlags(bool bUsed)
Sets all "attribute used" flags to the passed state.
Definition: xlstyle.cxx:1725
virtual ~XclXFBase()
Definition: xlstyle.cxx:1721
XclXFBase(bool bCellXF)
Definition: xlstyle.cxx:1714
bool mbFontUsed
true = cell protection used.
Definition: xlstyle.hxx:589
DocumentType eType
FontLineStyle
FontStrikeout
FontItalic
FontFamily
SvxFrameDirection
FontWeight
Contains all cell alignment attributes.
Definition: xlstyle.hxx:486
sal_uInt8 mnTextDir
Text orientation.
Definition: xlstyle.hxx:490
SvxCellHorJustify GetScHorAlign() const
Returns the Calc horizontal alignment.
Definition: xlstyle.cxx:1556
void SetScFrameDir(SvxFrameDirection eFrameDir)
Sets the Calc frame direction.
Definition: xlstyle.cxx:1640
sal_uInt8 mnOrient
Vertical alignment.
Definition: xlstyle.hxx:489
SvxCellJustifyMethod GetScHorJustifyMethod() const
Returns horizontal justification method as Calc's attribute.
Definition: xlstyle.cxx:1574
sal_uInt8 mnVerAlign
Horizontal alignment.
Definition: xlstyle.hxx:488
XclCellAlign()
true = Shrink to fit cell size.
Definition: xlstyle.cxx:1544
sal_uInt8 mnIndent
Text rotation angle.
Definition: xlstyle.hxx:492
SvxCellVerJustify GetScVerAlign() const
Returns the Calc vertical alignment.
Definition: xlstyle.cxx:1579
SvxCellJustifyMethod GetScVerJustifyMethod() const
Returns vertical justification method as Calc's attribute.
Definition: xlstyle.cxx:1594
void SetScHorAlign(SvxCellHorJustify eHorJust)
Sets the Calc horizontal alignment.
Definition: xlstyle.cxx:1612
void SetScVerAlign(SvxCellVerJustify eVerJust)
Sets the Calc vertical alignment.
Definition: xlstyle.cxx:1627
sal_uInt8 mnRotation
CTL text direction.
Definition: xlstyle.hxx:491
SvxFrameDirection GetScFrameDir() const
Returns the Calc frame direction.
Definition: xlstyle.cxx:1599
sal_uInt8 mnHorAlign
Definition: xlstyle.hxx:487
bool mbLineBreak
Indentation.
Definition: xlstyle.hxx:493
bool mbShrink
true = Multi-line text.
Definition: xlstyle.hxx:494
Contains background colors and pattern for a cell.
Definition: xlstyle.hxx:542
XclCellArea()
Fill pattern.
Definition: xlstyle.cxx:1688
sal_uInt16 mnBackColor
Palette index to foreground color.
Definition: xlstyle.hxx:544
bool IsTransparent() const
Returns true, if the area represents transparent state.
Definition: xlstyle.cxx:1702
sal_uInt8 mnPattern
Palette index to background color.
Definition: xlstyle.hxx:545
sal_uInt16 mnForeColor
Definition: xlstyle.hxx:543
Contains color and line style for each cell border line.
Definition: xlstyle.hxx:521
XclCellBorder()
true = Bottom-left to top-right on.
Definition: xlstyle.cxx:1661
sal_uInt8 mnRightLine
Style of left line.
Definition: xlstyle.hxx:528
sal_uInt8 mnDiagLine
Style of bottom line.
Definition: xlstyle.hxx:531
sal_uInt16 mnDiagColor
Palette index for bottom line.
Definition: xlstyle.hxx:526
bool mbDiagTLtoBR
Style of diagonal line(s).
Definition: xlstyle.hxx:532
sal_uInt8 mnTopLine
Style of right line.
Definition: xlstyle.hxx:529
sal_uInt16 mnLeftColor
Definition: xlstyle.hxx:522
sal_uInt8 mnLeftLine
Palette index for diagonal line(s).
Definition: xlstyle.hxx:527
sal_uInt16 mnTopColor
Palette index for right line.
Definition: xlstyle.hxx:524
sal_uInt16 mnRightColor
Palette index for left line.
Definition: xlstyle.hxx:523
sal_uInt16 mnBottomColor
Palette index for top line.
Definition: xlstyle.hxx:525
bool mbDiagBLtoTR
true = Top-left to bottom-right on.
Definition: xlstyle.hxx:533
sal_uInt8 mnBottomLine
Style of top line.
Definition: xlstyle.hxx:530
Contains all cell protection attributes.
Definition: xlstyle.hxx:475
XclCellProt()
true = Formula is hidden.
Definition: xlstyle.cxx:1533
bool mbLocked
Definition: xlstyle.hxx:476
bool mbHidden
true = Locked against editing.
Definition: xlstyle.hxx:477
This struct helps reading and writing Excel fonts.
Definition: xlstyle.hxx:284
void SetApiEscapement(sal_Int16 nApiEscapem)
Sets the API escapement style.
Definition: xlstyle.cxx:500
void FillFromVclFont(const vcl::Font &rFont)
Fills all members (except color and escapement) from the passed font.
Definition: xlstyle.cxx:202
OUString maStyle
Font name.
Definition: xlstyle.hxx:286
sal_Int16 GetApiFontEncoding() const
Returns the API font text encoding.
Definition: xlstyle.cxx:410
Color maColor
String with styles (bold, italic).
Definition: xlstyle.hxx:287
css::awt::FontSlant GetApiPosture() const
Returns the API font posture.
Definition: xlstyle.cxx:416
sal_uInt8 mnCharSet
Windows font family.
Definition: xlstyle.hxx:292
sal_Int16 GetApiStrikeout() const
Returns the API font strike-out style.
Definition: xlstyle.cxx:450
sal_Int16 GetApiFamily() const
Returns the API font family.
Definition: xlstyle.cxx:395
void SetScHeight(sal_Int32 nTwips)
Sets the Calc font height (in twips).
Definition: xlstyle.cxx:306
sal_uInt16 mnHeight
Font color.
Definition: xlstyle.hxx:288
void SetFontEncoding(rtl_TextEncoding eFontEnc)
Sets the font text encoding.
Definition: xlstyle.cxx:328
float GetApiWeight() const
Returns the API font weight.
Definition: xlstyle.cxx:421
bool mbOutline
true = Struck out.
Definition: xlstyle.hxx:296
void SetScFamily(FontFamily eScFamily)
Sets the Calc font family.
Definition: xlstyle.cxx:311
void SetApiStrikeout(sal_Int16 nApiStrikeout)
Sets the API font strike-out style.
Definition: xlstyle.cxx:510
sal_uInt16 mnWeight
Font height in twips (1/20 of a point).
Definition: xlstyle.hxx:289
FontWeight GetScWeight() const
Returns the Calc font weight.
Definition: xlstyle.cxx:258
void SetScStrikeout(FontStrikeout eScStrikeout)
Sets the Calc strike-out style.
Definition: xlstyle.cxx:380
void SetApiWeight(float fApiWeight)
Sets the API font weight.
Definition: xlstyle.cxx:483
XclFontData()
true = Shadowed.
Definition: xlstyle.cxx:172
void SetApiPosture(css::awt::FontSlant eApiPosture)
Sets the API font posture.
Definition: xlstyle.cxx:474
float GetApiHeight() const
Returns the API font height.
Definition: xlstyle.cxx:390
void SetScPosture(FontItalic eScPosture)
Sets the Calc font posture.
Definition: xlstyle.cxx:334
FontFamily GetScFamily(rtl_TextEncoding eDefTextEnc) const
Returns the Calc font family.
Definition: xlstyle.cxx:227
sal_Int16 GetApiEscapement() const
Returns the API escapement style.
Definition: xlstyle.cxx:439
FontStrikeout GetScStrikeout() const
Returns the Calc strike-out style.
Definition: xlstyle.cxx:301
void SetApiFamily(sal_Int16 nApiFamily)
Sets the API font family.
Definition: xlstyle.cxx:460
bool mbItalic
Underline style.
Definition: xlstyle.hxx:294
void SetApiUnderline(sal_Int16 nApiUnderl)
Sets the API font underline style.
Definition: xlstyle.cxx:488
sal_uInt8 mnUnderline
Windows character set.
Definition: xlstyle.hxx:293
FontLineStyle GetScUnderline() const
Returns the Calc font underline style.
Definition: xlstyle.cxx:277
void SetScEscapement(short nScEscapem)
Sets the Calc escapement style.
Definition: xlstyle.cxx:370
bool mbStrikeout
true = Italic.
Definition: xlstyle.hxx:295
FontItalic GetScPosture() const
Returns the Calc font posture.
Definition: xlstyle.cxx:253
void SetApiHeight(float fPoint)
Sets the API font height.
Definition: xlstyle.cxx:455
void SetScWeight(FontWeight eScWeight)
Sets the Calc font weight.
Definition: xlstyle.cxx:339
void SetScUnderline(FontLineStyle eScUnderl)
Sets the Calc underline style.
Definition: xlstyle.cxx:358
sal_uInt8 mnFamily
Escapement type.
Definition: xlstyle.hxx:291
void Clear()
Resets all members to default (empty) values.
Definition: xlstyle.cxx:188
sal_uInt16 mnEscapem
Boldness: 400=normal, 700=bold.
Definition: xlstyle.hxx:290
bool mbShadow
true = Outlined.
Definition: xlstyle.hxx:297
sal_Int16 GetApiUnderline() const
Returns the API font underline style.
Definition: xlstyle.cxx:426
rtl_TextEncoding GetFontEncoding() const
Returns the font text encoding.
Definition: xlstyle.cxx:247
SvxEscapement GetScEscapement() const
Returns the Calc escapement style.
Definition: xlstyle.cxx:290
OUString maName
Definition: xlstyle.hxx:285
void FillFromSvxFont(const SvxFont &rFont)
Fills all members (except color) from the passed SVX font.
Definition: xlstyle.cxx:219
OUString maFormat
Definition: xlstyle.hxx:437
NfIndexTableOffset meOffset
Format string, may be empty (meOffset used then).
Definition: xlstyle.hxx:438
LanguageType meLanguage
SvNumberFormatter format index, if maFormat is empty.
Definition: xlstyle.hxx:439
SvxEscapement
SvxCellJustifyMethod
SvxCellHorJustify
SvxCellVerJustify
unsigned char sal_uInt8
const sal_uInt8 EXC_FONTFAM_MODERN
Definition: xlstyle.hxx:88
const sal_uInt16 EXC_COLOR_NOTEBACK
Automatic frame border for series (BIFF8 charts).
Definition: xlstyle.hxx:213
const sal_uInt8 EXC_STYLE_CURRENCY_0
"Comma [0]" style.
Definition: xlstyle.hxx:231
const sal_uInt16 EXC_XF_SHRINK
Automatic line break.
Definition: xlstyle.hxx:149
const sal_uInt16 EXC_FONTWGHT_MEDIUM
Definition: xlstyle.hxx:111
const sal_uInt16 EXC_FONTWGHT_NORMAL
Definition: xlstyle.hxx:110
const sal_uInt16 EXC_XF_DEFAULTSTYLE
Arbitrary maximum number of style XFs.
Definition: xlstyle.hxx:138
const size_t EXC_FONT_MAXCOUNT5
Definition: xlstyle.hxx:80
const sal_uInt16 EXC_COLOR_WINDOWBACK
System window text color (>=BIFF5).
Definition: xlstyle.hxx:208
const sal_uInt8 EXC_FONTFAM_SCRIPT
Definition: xlstyle.hxx:89
const sal_uInt8 EXC_FONTFAM_SWISS
Definition: xlstyle.hxx:86
const sal_uInt16 EXC_FONT_NOTFOUND
Application font index.
Definition: xlstyle.hxx:77
const sal_uInt16 EXC_FONTWGHT_SEMIBOLD
Definition: xlstyle.hxx:112
const sal_uInt8 EXC_XF_HOR_GENERAL
Definition: xlstyle.hxx:158
const sal_uInt8 EXC_XF_HOR_DISTRIB
Definition: xlstyle.hxx:165
const sal_uInt8 EXC_STYLE_CURRENCY
"Comma" style.
Definition: xlstyle.hxx:228
const sal_uInt8 EXC_XF_TEXTDIR_LTR
Definition: xlstyle.hxx:174
const sal_uInt8 EXC_XF2_HIDDEN
Definition: xlstyle.hxx:179
const sal_uInt8 EXC_LINE_HAIR
Definition: xlstyle.hxx:44
const sal_uInt32 EXC_XF_DIAGONAL_BOTH
Bottom-left to top-right.
Definition: xlstyle.hxx:191
const sal_uInt16 EXC_XF8_MERGE
Shrink to fit into cell.
Definition: xlstyle.hxx:187
const sal_uInt16 EXC_FONTATTR_SHADOW
Definition: xlstyle.hxx:102
const sal_uInt8 EXC_LINE_DOTTED
Definition: xlstyle.hxx:41
const sal_uInt16 EXC_COLOR_BUTTONBACK
System window background color (>=BIFF5).
Definition: xlstyle.hxx:209
const sal_uInt16 EXC_FONTWGHT_SEMILIGHT
Definition: xlstyle.hxx:109
const sal_uInt16 EXC_FONTWGHT_ULTRABOLD
Definition: xlstyle.hxx:114
const sal_uInt16 EXC_FORMAT_OFFSET8
Definition: xlstyle.hxx:68
const sal_uInt8 EXC_PATT_50_PERC
Definition: xlstyle.hxx:56
const sal_uInt8 EXC_STYLE_COLLEVEL
"RowLevel_*" styles.
Definition: xlstyle.hxx:226
const sal_uInt8 EXC_XF2_TOPLINE
Definition: xlstyle.hxx:182
const sal_uInt8 EXC_LINE_MEDIUM_DASHDOTDOT
Definition: xlstyle.hxx:49
const sal_uInt16 EXC_FONT_APP
Definition: xlstyle.hxx:76
const sal_uInt16 EXC_COLOR_NOTETEXT
Note background color.
Definition: xlstyle.hxx:214
const sal_uInt8 EXC_FONTFAM_SYSTEM
Definition: xlstyle.hxx:87
const sal_uInt8 EXC_XF_DIFF_BORDER
Definition: xlstyle.hxx:154
const sal_uInt32 EXC_XF_MAXSTYLECOUNT
Maximum number of all XF records.
Definition: xlstyle.hxx:137
XclFontItemType
Enumerates different types of Which-IDs for font items.
Definition: xlstyle.hxx:386
@ Editeng
Use Calc Which-IDs (ATTR_*).
const sal_uInt8 EXC_PATT_6_25_PERC
Definition: xlstyle.hxx:60
const sal_uInt16 EXC_FONTESC_SUPER
Definition: xlstyle.hxx:126
const sal_uInt16 EXC_COLOR_FONTAUTO
Note text color.
Definition: xlstyle.hxx:215
const sal_uInt16 EXC_STYLE_XFMASK
Definition: xlstyle.hxx:222
const sal_uInt16 EXC_ID2_XF
Definition: xlstyle.hxx:131
const sal_uInt16 EXC_FONTATTR_UNDERLINE
Definition: xlstyle.hxx:99
const sal_uInt16 EXC_COLOR_USEROFFSET
Definition: xlstyle.hxx:204
const sal_uInt16 EXC_FONTWGHT_BLACK
Definition: xlstyle.hxx:115
const sal_uInt8 EXC_XF_HOR_CENTER_AS
Definition: xlstyle.hxx:164
const sal_uInt8 EXC_STYLE_PERCENT
"Currency" style.
Definition: xlstyle.hxx:229
const sal_uInt8 EXC_XF2_RIGHTLINE
Definition: xlstyle.hxx:181
XclFontPropSetType
Enumerates different types for objects with font settings (using different property names).
Definition: xlstyle.hxx:394
@ EXC_FONTPROPSET_CONTROL
All text objects in charts.
Definition: xlstyle.hxx:396
@ EXC_FONTPROPSET_CHART
Definition: xlstyle.hxx:395
const sal_uInt8 EXC_XF_HOR_CENTER
Definition: xlstyle.hxx:160
const sal_uInt8 EXC_FONTFAM_DONTKNOW
Definition: xlstyle.hxx:84
const size_t EXC_FONT_MAXCOUNT8
Definition: xlstyle.hxx:81
const sal_uInt8 EXC_STYLEEXT_CUSTOM
Definition: xlstyle.hxx:245
const sal_uInt8 EXC_STYLE_LEVELCOUNT
No built-in style.
Definition: xlstyle.hxx:236
const sal_uInt8 EXC_XF_DIFF_FONT
Definition: xlstyle.hxx:152
const sal_uInt8 EXC_XF_TEXTDIR_RTL
Definition: xlstyle.hxx:175
const sal_uInt16 EXC_COLOR_BIFF2_WHITE
Definition: xlstyle.hxx:202
const sal_uInt8 EXC_FONTUNDERL_DOUBLE_ACC
Definition: xlstyle.hxx:122
const sal_uInt8 EXC_FONTFAM_DECORATIVE
Definition: xlstyle.hxx:90
const sal_uInt8 EXC_LINE_DASHED
Definition: xlstyle.hxx:40
const sal_uInt8 EXC_LINE_THIN
Definition: xlstyle.hxx:38
const sal_uInt8 EXC_STYLE_ROWLEVEL
"Normal" style.
Definition: xlstyle.hxx:225
const sal_uInt16 EXC_ID4_XF
Definition: xlstyle.hxx:133
const sal_uInt16 EXC_ID4_FORMAT
Definition: xlstyle.hxx:65
const sal_uInt8 EXC_FONTUNDERL_SINGLE
Definition: xlstyle.hxx:119
const sal_uInt16 EXC_COLOR_CHBORDERAUTO
Chart window background color (BIFF8 charts).
Definition: xlstyle.hxx:212
const sal_uInt8 EXC_LINE_MEDIUM_DASHED
Definition: xlstyle.hxx:45
const sal_uInt16 EXC_FONTATTR_STRIKEOUT
Definition: xlstyle.hxx:100
const sal_uInt8 EXC_LINE_NONE
Definition: xlstyle.hxx:37
const sal_uInt8 EXC_STYLEEXT_HIDDEN
Definition: xlstyle.hxx:244
const sal_uInt16 EXC_COLOR_WINDOWTEXT
System window background color (BIFF3-BIFF4).
Definition: xlstyle.hxx:207
const sal_uInt16 EXC_XF_NOTFOUND
Excel index to default cell XF.
Definition: xlstyle.hxx:140
const sal_uInt8 EXC_FONTUNDERL_DOUBLE
Definition: xlstyle.hxx:120
const sal_uInt16 EXC_ID2_FONT
Definition: xlstyle.hxx:73
bool operator==(const XclFontData &rLeft, const XclFontData &rRight)
Definition: xlstyle.cxx:517
const sal_uInt8 EXC_XF_DIFF_VALFMT
Shrink to fit into cell.
Definition: xlstyle.hxx:151
const sal_uInt8 EXC_XF_VER_TOP
Definition: xlstyle.hxx:167
const sal_uInt8 EXC_LINE_THIN_DASHDOTDOT
Definition: xlstyle.hxx:48
const sal_uInt8 EXC_XF2_BOTTOMLINE
Definition: xlstyle.hxx:183
const sal_uInt8 EXC_STYLE_NOLEVEL
Number of outline level styles.
Definition: xlstyle.hxx:237
const sal_uInt16 EXC_FONTATTR_ITALIC
Definition: xlstyle.hxx:98
const sal_uInt16 EXC_ID2_FORMAT
Definition: xlstyle.hxx:64
const sal_uInt16 EXC_COLOR_BIFF2_BLACK
Definition: xlstyle.hxx:201
const sal_uInt8 EXC_XF2_LOCKED
Definition: xlstyle.hxx:178
const sal_uInt16 EXC_XF_STYLE
Definition: xlstyle.hxx:146
const sal_uInt16 EXC_ID_PALETTE
Definition: xlstyle.hxx:199
const sal_uInt8 EXC_XF2_LEFTLINE
Definition: xlstyle.hxx:180
const sal_uInt16 EXC_XF_LOCKED
Definition: xlstyle.hxx:144
const sal_uInt8 EXC_XF_VER_JUSTIFY
Definition: xlstyle.hxx:170
const sal_uInt16 EXC_XF_STYLEPARENT
Definition: xlstyle.hxx:147
const sal_uInt16 EXC_STYLE_BUILTIN
Definition: xlstyle.hxx:221
const sal_uInt16 EXC_ID3_XF
Definition: xlstyle.hxx:132
const sal_uInt16 EXC_ID_STYLEEXT
Default value for unused level.
Definition: xlstyle.hxx:241
const sal_uInt16 EXC_FONTESC_NONE
Definition: xlstyle.hxx:125
const sal_uInt16 EXC_FONTATTR_NONE
Definition: xlstyle.hxx:96
const sal_uInt16 EXC_ID_EFONT
Both.
Definition: xlstyle.hxx:195
const sal_uInt16 EXC_ID_STYLE
Font auto color (system window text color).
Definition: xlstyle.hxx:219
const sal_uInt8 EXC_XF_VER_BOTTOM
Definition: xlstyle.hxx:169
const sal_uInt8 EXC_PATT_NONE
Definition: xlstyle.hxx:54
const sal_uInt8 EXC_XF_VER_CENTER
Definition: xlstyle.hxx:168
const sal_uInt8 EXC_LINE_MEDIUM_SLANT_DASHDOT
Definition: xlstyle.hxx:50
const sal_uInt8 EXC_LINE_THIN_DASHDOT
Definition: xlstyle.hxx:46
const sal_uInt8 EXC_FONTUNDERL_NONE
Definition: xlstyle.hxx:118
const sal_uInt16 EXC_FONTATTR_BOLD
Definition: xlstyle.hxx:97
const sal_uInt16 EXC_XF_HIDDEN
Definition: xlstyle.hxx:145
const sal_uInt8 EXC_XF_HOR_FILL
Definition: xlstyle.hxx:162
const sal_uInt8 EXC_STYLE_COMMA_0
"Percent" style.
Definition: xlstyle.hxx:230
const sal_uInt16 EXC_FONTWGHT_ULTRALIGHT
Definition: xlstyle.hxx:107
const sal_uInt8 EXC_PATT_SOLID
Definition: xlstyle.hxx:55
const sal_uInt8 EXC_XF2_BACKGROUND
Definition: xlstyle.hxx:184
const sal_uInt16 EXC_COLOR_WINDOWTEXT3
First user defined color.
Definition: xlstyle.hxx:205
const sal_uInt32 EXC_XF_MAXCOUNT
Definition: xlstyle.hxx:136
const sal_uInt8 EXC_PATT_75_PERC
Definition: xlstyle.hxx:57
const sal_uInt16 EXC_FONTWGHT_LIGHT
Definition: xlstyle.hxx:108
const sal_uInt16 EXC_COLOR_CHWINDOWBACK
Chart window text color (BIFF8 charts).
Definition: xlstyle.hxx:211
const sal_uInt8 EXC_FONTCSET_ANSI_LATIN
Definition: xlstyle.hxx:93
const sal_uInt8 EXC_LINE_MEDIUM
Definition: xlstyle.hxx:39
const sal_uInt16 EXC_XF_LINEBREAK
Styles don't have a parent.
Definition: xlstyle.hxx:148
const sal_uInt32 EXC_XF_DIAGONAL_BL_TO_TR
Top-left to bottom-right.
Definition: xlstyle.hxx:190
const sal_uInt8 EXC_PATT_12_5_PERC
Definition: xlstyle.hxx:59
const sal_uInt8 EXC_XF_HOR_RIGHT
Definition: xlstyle.hxx:161
const sal_uInt16 EXC_FONTWGHT_THIN
Definition: xlstyle.hxx:106
const sal_uInt8 EXC_FONTUNDERL_SINGLE_ACC
Definition: xlstyle.hxx:121
const sal_uInt8 EXC_XF_HOR_JUSTIFY
Definition: xlstyle.hxx:163
const sal_uInt16 EXC_ID5_XF
Definition: xlstyle.hxx:134
const sal_uInt8 EXC_XF_VER_DISTRIB
Definition: xlstyle.hxx:171
const sal_uInt8 EXC_STYLEEXT_BUILTIN
Definition: xlstyle.hxx:243
const sal_uInt16 EXC_COLOR_WINDOWBACK3
System window text color (BIFF3-BIFF4).
Definition: xlstyle.hxx:206
const sal_uInt32 EXC_XFID_NOTFOUND
Special index for "not found" state.
Definition: xlstyle.hxx:142
const sal_uInt8 EXC_STYLE_HYPERLINK
"Currency [0]" style.
Definition: xlstyle.hxx:232
const sal_uInt16 EXC_FORMAT_NOTFOUND
Definition: xlstyle.hxx:69
const sal_uInt8 EXC_LINE_THICK
Definition: xlstyle.hxx:42
const size_t EXC_FONT_MAXCOUNT4
Definition: xlstyle.hxx:79
const sal_uInt16 EXC_FONTWGHT_BOLD
Definition: xlstyle.hxx:113
const sal_uInt32 EXC_XF_DIAGONAL_TL_TO_BR
Definition: xlstyle.hxx:189
const sal_uInt8 EXC_XF_HOR_LEFT
Definition: xlstyle.hxx:159
const sal_uInt8 EXC_FONTFAM_ROMAN
Definition: xlstyle.hxx:85
const sal_uInt8 EXC_XF_DIFF_ALIGN
Definition: xlstyle.hxx:153
const sal_uInt8 EXC_PATT_25_PERC
Definition: xlstyle.hxx:58
const sal_uInt8 EXC_STYLE_COMMA
"ColLevel_*" styles.
Definition: xlstyle.hxx:227
const sal_uInt8 EXC_STYLE_FOLLOWED_HYPERLINK
"Hyperlink" style.
Definition: xlstyle.hxx:233
const sal_uInt16 EXC_COLOR_CHWINDOWTEXT
System button background color (face color).
Definition: xlstyle.hxx:210
const sal_uInt8 EXC_XF_DIFF_AREA
Definition: xlstyle.hxx:155
const sal_uInt8 EXC_LINE_DOUBLE
Definition: xlstyle.hxx:43
const sal_uInt8 EXC_LINE_MEDIUM_DASHDOT
Definition: xlstyle.hxx:47
const sal_uInt16 EXC_FONTATTR_OUTLINE
Definition: xlstyle.hxx:101
const sal_uInt16 EXC_XF_DEFAULTCELL
Excel index to default style XF.
Definition: xlstyle.hxx:139
const sal_uInt8 EXC_XF_TEXTDIR_CONTEXT
Definition: xlstyle.hxx:173
const sal_uInt16 EXC_ID3_FONT
Definition: xlstyle.hxx:74
const sal_uInt16 EXC_FORMAT_OFFSET5
Definition: xlstyle.hxx:67
const sal_uInt8 EXC_STYLE_NORMAL
Definition: xlstyle.hxx:224
const sal_uInt8 EXC_XF2_VALFMT_MASK
Definition: xlstyle.hxx:177
const sal_uInt8 EXC_STYLE_USERDEF
"Followed_Hyperlink" style.
Definition: xlstyle.hxx:234
const sal_uInt16 EXC_FONTESC_SUB
Definition: xlstyle.hxx:127
const sal_uInt16 EXC_XF8_SHRINK
Definition: xlstyle.hxx:186
const sal_uInt8 EXC_XF_DIFF_PROT
Definition: xlstyle.hxx:156
const sal_uInt16 EXC_FONTWGHT_DONTKNOW
Definition: xlstyle.hxx:105
NfIndexTableOffset