LibreOffice Module sc (master)  1
xestyle.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 <svl/zforlist.hxx>
24 #include <svl/nfkeytab.hxx>
25 #include <editeng/svxfont.hxx>
26 #include "xerecord.hxx"
27 #include "xlstyle.hxx"
28 #include "xeroot.hxx"
29 #include <fonthelper.hxx>
30 #include <memory>
31 #include <vector>
32 
33 /* ============================================================================
34 - Buffers for style records (PALETTE, FONT, FORMAT, XF, STYLE).
35 ============================================================================ */
36 
37 const sal_uInt16 EXC_ID_FONTLIST = 0x8031;
38 const sal_uInt16 EXC_ID_FORMATLIST = 0x801E;
39 const sal_uInt16 EXC_ID_XFLIST = 0x8043;
40 const sal_uInt16 EXC_ID_DXFS = 0x9999;
41 
42 // PALETTE record - color information =========================================
43 
46 {
56 };
57 
58 class XclExpPaletteImpl;
59 
75 {
76 public:
77  explicit XclExpPalette( const XclExpRoot& rRoot );
78  virtual ~XclExpPalette() override;
79 
83  sal_uInt32 InsertColor( const Color& rColor, XclExpColorType eType, sal_uInt16 nAutoDefault = 0 );
85  static sal_uInt32 GetColorIdFromIndex( sal_uInt16 nIndex );
86 
88  void Finalize();
89 
91  sal_uInt16 GetColorIndex( sal_uInt32 nColorId ) const;
92 
97  void GetMixedColors(
98  sal_uInt16& rnXclForeIx, sal_uInt16& rnXclBackIx, sal_uInt8& rnXclPattern,
99  sal_uInt32 nForeColorId, sal_uInt32 nBackColorId ) const;
100 
103  Color GetColor( sal_uInt16 nXclIndex ) const;
104 
106  virtual void Save( XclExpStream& rStrm ) override;
107  virtual void SaveXml( XclExpXmlStream& rStrm ) override;
108 
109 private:
111  virtual void WriteBody( XclExpStream& rStrm ) override;
112 
113 private:
114  typedef std::shared_ptr< XclExpPaletteImpl > XclExpPaletteImplRef;
115  XclExpPaletteImplRef mxImpl;
116 };
117 
118 // FONT record - font information =============================================
119 
120 const size_t EXC_FONTLIST_NOTFOUND = static_cast< size_t >( -1 );
121 
124 {
126  sal_Int16 GetFirstUsedScript(
127  const XclExpRoot& rRoot,
128  const SfxItemSet& rItemSet );
129 
132  const XclExpRoot& rRoot,
133  const SfxItemSet& rItemSet,
134  sal_Int16 nScript );
135 
141  ScDxfFont GetDxfFontFromItemSet(const XclExpRoot& rRoot, const SfxItemSet& rSet);
142 
145  bool CheckItems(
146  const XclExpRoot& rRoot,
147  const SfxItemSet& rItemSet,
148  sal_Int16 nScript,
149  bool bDeep );
150 }
151 
153 class XclExpFont : public XclExpRecord, protected XclExpRoot
154 {
155 public:
156  explicit XclExpFont( const XclExpRoot& rRoot,
157  const XclFontData& rFontData, XclExpColorType eColorType );
158 
160  const XclFontData& GetFontData() const { return maData; }
162  sal_uInt32 GetFontColorId() const { return mnColorId; }
165  virtual bool Equals( const XclFontData& rFontData, sal_uInt32 nHash ) const;
166 
167  virtual void SaveXml( XclExpXmlStream& rStrm ) override;
168 
169 private:
171  virtual void WriteBody( XclExpStream& rStrm ) override;
172 
173 private:
175  sal_uInt32 mnColorId;
176  sal_uInt32 mnHash;
177 };
178 
179 class XclExpDxfFont : public XclExpRecordBase, protected XclExpRoot
180 {
181 public:
182  XclExpDxfFont(const XclExpRoot& rRoot, const SfxItemSet& rItemSet);
183 
184  virtual void SaveXml(XclExpXmlStream& rStrm) override;
185 private:
186 
188 };
189 
192 {
193 public:
194  explicit XclExpBlindFont( const XclExpRoot& rRoot );
195 
197  virtual bool Equals( const XclFontData& rFontData, sal_uInt32 nHash ) const override;
198 
200  virtual void Save( XclExpStream& rStrm ) override;
201 };
202 
203 class ScPatternAttr;
204 
207 {
208 public:
209  explicit XclExpFontBuffer( const XclExpRoot& rRoot );
210 
212  const XclExpFont* GetFont( sal_uInt16 nXclFont ) const;
214  const XclFontData& GetAppFontData() const;
215 
219  sal_uInt16 Insert( const XclFontData& rFontData,
220  XclExpColorType eColorType, bool bAppFont = false );
223  sal_uInt16 Insert( const SvxFont& rFont,
224  XclExpColorType eColorType );
229  sal_uInt16 Insert( const SfxItemSet& rItemSet, sal_Int16 nScript,
230  XclExpColorType eColorType, bool bAppFont );
231 
233  virtual void Save( XclExpStream& rStrm ) override;
234  virtual void SaveXml( XclExpXmlStream& rStrm ) override;
235 
236 private:
238  void InitDefaultFonts();
240  size_t Find( const XclFontData& rFontData );
241 
242 private:
245 
246  XclExpFontList maFontList;
247  size_t mnXclMaxSize;
248 };
249 
250 // FORMAT record - number formats =============================================
251 
254 {
255  sal_uInt32 mnScNumFmt;
256  sal_uInt16 mnXclNumFmt;
257  OUString maNumFmtString;
258 
259  explicit XclExpNumFmt( sal_uInt32 nScNumFmt, sal_uInt16 nXclNumFmt, const OUString& rFrmt ) :
260  mnScNumFmt( nScNumFmt ), mnXclNumFmt( nXclNumFmt ), maNumFmtString( rFrmt ) {}
261 
262  void SaveXml( XclExpXmlStream& rStrm );
263 };
264 
265 typedef ::std::unique_ptr< SvNumberFormatter > SvNumberFormatterPtr;
266 
269 {
270 public:
271  explicit XclExpNumFmtBuffer( const XclExpRoot& rRoot );
272  virtual ~XclExpNumFmtBuffer() override;
273 
275  sal_uInt32 GetStandardFormat() const { return mnStdFmt; }
276 
280  sal_uInt16 Insert( sal_uInt32 nScNumFmt );
281 
283  virtual void Save( XclExpStream& rStrm ) override;
284  virtual void SaveXml( XclExpXmlStream& rStrm ) override;
285 
286  OUString GetFormatCode ( sal_uInt32 nScNumFmt );
287 
288 private:
290  void WriteFormatRecord( XclExpStream& rStrm, sal_uInt16 nXclNumFmt, const OUString& rFormatStr );
292  void WriteFormatRecord( XclExpStream& rStrm, const XclExpNumFmt& rFormat );
293 
294 private:
295  typedef ::std::vector< XclExpNumFmt > XclExpNumFmtVec;
296 
298  XclExpNumFmtVec maFormatMap;
299  std::unique_ptr<NfKeywordTable> mpKeywordTable;
300  sal_uInt32 mnStdFmt;
301  sal_uInt16 mnXclOffset;
302 };
303 
304 // XF, STYLE record - Cell formatting =========================================
305 
309 {
312  bool FillFromItemSet( const SfxItemSet& rItemSet, bool bStyle = false );
313 
315  void FillToXF3( sal_uInt16& rnProt ) const;
316 
317  void SaveXml( XclExpXmlStream& rStrm ) const;
318 };
319 
323 {
328  bool FillFromItemSet(const XclRoot& rRoot, const SfxItemSet& rItemSet,
329  bool bForceLineBreak, XclBiff eBiff, bool bStyle = false );
330 
332  void FillToXF5( sal_uInt16& rnAlign ) const;
334  void FillToXF8( sal_uInt16& rnAlign, sal_uInt16& rnMiscAttrib ) const;
335 
336  void SaveXml( XclExpXmlStream& rStrm ) const;
337 };
338 
342 {
343  sal_uInt32 mnLeftColorId;
344  sal_uInt32 mnRightColorId;
345  sal_uInt32 mnTopColorId;
346  sal_uInt32 mnBottomColorId;
347  sal_uInt32 mnDiagColorId;
348 
349  explicit XclExpCellBorder();
350 
354  bool FillFromItemSet( const SfxItemSet& rItemSet,
355  XclExpPalette& rPalette, XclBiff eBiff, bool bStyle = false );
357  void SetFinalColors( const XclExpPalette& rPalette );
358 
360  void FillToXF5( sal_uInt32& rnBorder, sal_uInt32& rnArea ) const;
362  void FillToXF8( sal_uInt32& rnBorder1, sal_uInt32& rnBorder2 ) const;
363 
365  void FillToCF8( sal_uInt16& rnLine, sal_uInt32& rnColor ) const;
366 
367  void SaveXml( XclExpXmlStream& rStrm ) const;
368 };
369 
373 {
374  sal_uInt32 mnForeColorId;
375  sal_uInt32 mnBackColorId;
376  Color maForeColor; // Actual foreground color
377  Color maBackColor; // Actual background color
378 
379  explicit XclExpCellArea();
380  explicit XclExpCellArea(Color aForeColor, Color aBackColor);
381 
384  bool FillFromItemSet(
385  const SfxItemSet& rItemSet, XclExpPalette& rPalette,
386  bool bStyle );
388  void SetFinalColors( const XclExpPalette& rPalette );
389 
391  void FillToXF5( sal_uInt32& rnArea ) const;
393  void FillToXF8( sal_uInt32& rnBorder2, sal_uInt16& rnArea ) const;
394 
396  void FillToCF8( sal_uInt16& rnPattern, sal_uInt16& rnColor ) const;
397 
398  void SaveXml( XclExpXmlStream& rStrm ) const;
399 };
400 
402 {
404 
405  bool FillFromItemSet( const SfxItemSet& rItemSet );
406 
407  void SaveXml( XclExpXmlStream& rStrm ) const;
408 };
409 
412 {
413  sal_uInt32 mnXFId;
414  sal_uInt16 mnXFIndex;
415 
416  explicit XclExpXFId();
417  explicit XclExpXFId( sal_uInt32 nXFId )
418  : mnXFId( nXFId ), mnXFIndex( EXC_XF_DEFAULTCELL ) {}
419 
421  void ConvertXFIndex( const XclExpRoot& rRoot );
422 };
423 
424 class SfxStyleSheetBase;
425 
427 class XclExpXF : public XclXFBase, public XclExpRecord, protected XclExpRoot
428 {
429 public:
431  explicit XclExpXF(
432  const XclExpRoot& rRoot,
433  const ScPatternAttr& rPattern,
434  sal_Int16 nScript,
435  sal_uInt32 nScForceNumFmt = NUMBERFORMAT_ENTRY_NOT_FOUND,
436  sal_uInt16 nForceXclFont = EXC_FONT_NOTFOUND,
437  bool bForceLineBreak = false );
439  explicit XclExpXF(
440  const XclExpRoot& rRoot,
441  const SfxStyleSheetBase& rStyleSheet );
442 
444  const XclExpCellProt& GetProtectionData() const { return maProtection; }
446  const XclExpCellAlign& GetAlignmentData() const { return maAlignment; }
448  const XclExpCellBorder& GetBorderData() const { return maBorder; }
450  const XclExpCellArea& GetAreaData() const { return maArea; }
451 
454  bool Equals(
455  const ScPatternAttr& rPattern,
456  sal_uInt32 nScForceNumFmt,
457  sal_uInt16 nForceXclFont,
458  bool bForceLineBreak ) const;
459 
462  bool Equals( const SfxStyleSheetBase& rStyleSheet ) const;
463 
465  void SetFinalColors();
466 
468  bool Equals( const XclExpXF& rCmpXF ) const;
469 
470  void SetXmlIds( sal_uInt32 nBorderId, sal_uInt32 nFillId );
471 
472  virtual void SaveXml( XclExpXmlStream& rStrm ) override;
473 
474  const SfxItemSet* GetItemSet() const { return mpItemSet; }
475 
476  sal_uInt32 GetScNumFmt() const { return mnScNumFmt; }
477  sal_uInt16 GetXclFont() const { return mnXclFont; }
478 
479 protected:
480  explicit XclExpXF( const XclExpRoot& rRoot, bool bCellXF );
481 
482 protected: // access for XclExpDefaultXF
484 
489  sal_uInt32 mnParentXFId;
490  sal_uInt32 mnScNumFmt;
491  sal_uInt16 mnXclFont;
492  sal_uInt16 mnXclNumFmt;
493  sal_Int32 mnBorderId;
494  sal_Int32 mnFillId;
495 
496 private:
497  using XclXFBase::Equals;
498 
500  void InitDefault();
503  void Init(
504  const SfxItemSet& rItemSet,
505  sal_Int16 nScript,
506  sal_uInt32 nForceScNumFmt,
507  sal_uInt16 nForceXclFont,
508  bool bForceLineBreak,
509  bool bDefStyle );
510 
515  sal_uInt8 GetUsedFlags() const;
516 
517  void WriteBody5( XclExpStream& rStrm );
518  void WriteBody8( XclExpStream& rStrm );
519 
521  virtual void WriteBody( XclExpStream& rStrm ) override;
522 };
523 
525 class XclExpDefaultXF : public XclExpXF
526 {
527 public:
528  explicit XclExpDefaultXF( const XclExpRoot& rRoot, bool bCellXF );
529 
531  void SetFont( sal_uInt16 nXclFont );
533  void SetNumFmt( sal_uInt16 nXclNumFmt );
534 };
535 
538 class XclExpStyle : public XclExpRecord
539 {
540 public:
541  explicit XclExpStyle( sal_uInt32 nXFId, const OUString& rStyleName );
542  explicit XclExpStyle( sal_uInt32 nXFId, sal_uInt8 nStyleId, sal_uInt8 nLevel );
543 
545  bool IsBuiltIn() const { return mnStyleId != EXC_STYLE_USERDEF; }
546 
547  virtual void SaveXml( XclExpXmlStream& rStrm ) override;
548 
549 private:
551  virtual void WriteBody( XclExpStream& rStrm ) override;
552 
553 private:
554  OUString maName;
558 };
559 
575 class XclExpXFBuffer : public XclExpRecordBase, protected XclExpRoot
576 {
577 public:
578  explicit XclExpXFBuffer( const XclExpRoot& rRoot );
579 
581  void Initialize();
582 
585  sal_uInt32 Insert( const ScPatternAttr* pPattern, sal_Int16 nScript );
592  sal_uInt32 InsertWithFont(
593  const ScPatternAttr* pPattern, sal_Int16 nScript,
594  sal_uInt16 nForceXclFont,
595  bool bForceLineBreak );
603  sal_uInt32 InsertWithNumFmt(
604  const ScPatternAttr* pPattern, sal_Int16 nScript,
605  sal_uInt32 nForceScNumFmt,
606  bool bForceLineBreak );
609  sal_uInt32 InsertStyle( const SfxStyleSheetBase* pStyleSheet );
611  static sal_uInt32 GetXFIdFromIndex( sal_uInt16 nXFIndex );
613  static sal_uInt32 GetDefCellXFId();
614 
616  const XclExpXF* GetXFById( sal_uInt32 nXFId ) const;
617 
619  void Finalize();
620 
622  sal_uInt16 GetXFIndex( sal_uInt32 nXFId ) const;
623 
624  sal_Int32 GetXmlStyleIndex( sal_uInt32 nXFId ) const;
625  sal_Int32 GetXmlCellIndex( sal_uInt32 nXFId ) const;
626 
628  virtual void Save( XclExpStream& rStrm ) override;
629  virtual void SaveXml( XclExpXmlStream& rStrm ) override;
630 
631 private:
634 
635 private:
637  sal_uInt32 FindXF( const ScPatternAttr& rPattern, sal_uInt32 nForceScNumFmt,
638  sal_uInt16 nForceXclFont, bool bForceLineBreak ) const;
640  sal_uInt32 FindXF( const SfxStyleSheetBase& rStyleSheet ) const;
641 
643  sal_uInt32 FindBuiltInXF( sal_uInt8 nStyleId, sal_uInt8 nLevel ) const;
644 
647  sal_uInt32 InsertCellXF( const ScPatternAttr* pPattern, sal_Int16 nScript,
648  sal_uInt32 nForceScNumFmt,
649  sal_uInt16 nForceXclFont, bool bForceLineBreak );
652  sal_uInt32 InsertStyleXF( const SfxStyleSheetBase& rStyleSheet );
653 
655  void InsertUserStyles();
656 
659  sal_uInt32 AppendBuiltInXF( XclExpXFRef const & xXF,
660  sal_uInt8 nStyleId, sal_uInt8 nLevel = EXC_STYLE_NOLEVEL );
663  sal_uInt32 AppendBuiltInXFWithStyle( XclExpXFRef const & xXF,
664  sal_uInt8 nStyleId, sal_uInt8 nLevel = EXC_STYLE_NOLEVEL );
665 
667  void InsertDefaultRecords();
668 
670  void AppendXFIndex( sal_uInt32 nXFId );
671 
672  void AddBorderAndFill( const XclExpXF& rXF );
673  void SaveXFXml( XclExpXmlStream& rStrm, XclExpXF& rXF );
674 
675 private:
678  {
683  explicit XclExpBuiltInInfo();
684  };
685  typedef ::std::map< sal_uInt32, XclExpBuiltInInfo > XclExpBuiltInMap;
686  typedef ::std::vector< XclExpCellBorder > XclExpBorderList;
687  typedef ::std::vector< XclExpCellArea > XclExpFillList;
688 
690  struct FindKey
691  {
692  bool mbCellXF; // is this a hard cell format, or a cell style
694  sal_uInt32 mnScNumFmt;
695  sal_uInt16 mnXclFont;
696 
697  bool operator<(const FindKey& other) const
698  {
699  if (mbCellXF != other.mbCellXF)
700  return mbCellXF < other.mbCellXF;
701  if (mpItemSet != other.mpItemSet)
702  return mpItemSet < other.mpItemSet;
703  if (mnScNumFmt != other.mnScNumFmt)
704  return mnScNumFmt < other.mnScNumFmt;
705  return mnXclFont < other.mnXclFont;
706  }
707  };
708  static FindKey ToFindKey(XclExpXF const &);
709 
710  XclExpXFList maXFList;
711  std::map<FindKey, std::vector<sal_uInt32>>
715  XclExpBuiltInMap maBuiltInMap;
719  XclExpXFList maSortedXFList;
720  XclExpBorderList maBorders;
721  XclExpFillList maFills;
722 
723 };
724 
725 class XclExpDxf : public XclExpRecordBase, protected XclExpRoot
726 {
727 public:
728  XclExpDxf( const XclExpRoot& rRoot, std::unique_ptr<XclExpCellAlign> pAlign, std::unique_ptr<XclExpCellBorder> pBorder,
729  std::unique_ptr<XclExpDxfFont> pFont, std::unique_ptr<XclExpNumFmt> pNumberFmt,
730  std::unique_ptr<XclExpCellProt> pProt, std::unique_ptr<XclExpColor> pColor);
731  XclExpDxf( const XclExpRoot& rRoot, std::unique_ptr<XclExpCellArea> pCellArea);
732  virtual ~XclExpDxf() override;
733 
734  virtual void SaveXml( XclExpXmlStream& rStrm ) override;
735  void SaveXmlExt( XclExpXmlStream& rStrm);
736 
737 private:
738  std::unique_ptr<XclExpCellAlign> mpAlign;
739  std::unique_ptr<XclExpCellBorder> mpBorder;
740  std::unique_ptr<XclExpDxfFont> mpFont;
741  std::unique_ptr<XclExpNumFmt> mpNumberFmt;
742  std::unique_ptr<XclExpCellProt> mpProt;
743  std::unique_ptr<XclExpColor> mpColor;
744  std::unique_ptr<XclExpCellArea> mpCellArea;
745 };
746 
747 class XclExpDxfs : public XclExpRecordBase, protected XclExpRoot
748 {
749 public:
750  XclExpDxfs( const XclExpRoot& rRoot );
751 
752  sal_Int32 GetDxfId(const OUString& rName) const;
753  sal_Int32 GetDxfByColor(Color aColor) const;
754  void AddColor(Color aColor);
755 
756  virtual void SaveXml( XclExpXmlStream& rStrm) override;
757 private:
758  typedef std::vector< std::unique_ptr<XclExpDxf> > DxfContainer;
759  std::map<OUString, sal_Int32> maStyleNameToDxfId;
760  std::map<Color, sal_Int32> maColorToDxfId;
761  DxfContainer maDxf;
762  std::unique_ptr<NfKeywordTable> mpKeywordTable;
763 };
764 
766 {
767 public:
768  explicit XclExpXmlStyleSheet( const XclExpRoot& rRoot );
769 
770  virtual void SaveXml( XclExpXmlStream& rStrm ) override;
771 };
772 
773 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
sal_uInt16 GetXclFont() const
Definition: xestyle.hxx:477
std::unique_ptr< XclExpNumFmt > mpNumberFmt
Definition: xestyle.hxx:741
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:1243
void FillToXF8(sal_uInt16 &rnAlign, sal_uInt16 &rnMiscAttrib) const
Fills the data to the passed fields of a BIFF8 XF record.
Definition: xestyle.cxx:1555
void SaveXml(XclExpXmlStream &rStrm) const
Definition: xestyle.cxx:1951
XclExpBuiltInMap maBuiltInMap
List of all STYLE records.
Definition: xestyle.hxx:715
Stores all XF records (cell formats and cell styles) in the document.
Definition: xestyle.hxx:575
virtual void Save(XclExpStream &rStrm) override
Writes all FORMAT records contained in this buffer.
Definition: xestyle.cxx:1374
vcl::Font GetFontFromItemSet(const XclExpRoot &rRoot, const SfxItemSet &rItemSet, sal_Int16 nScript)
Returns a VCL font object filled from the passed item set.
Definition: xestyle.cxx:883
XclExpColorType
For internal use only. TODO:moggi: find a better/correct value.
Definition: xestyle.hxx:45
sal_Int32 nIndex
XclBiff
An enumeration for all Excel file format types (BIFF types).
Definition: xlconst.hxx:29
XclExpDxf(const XclExpRoot &rRoot, std::unique_ptr< XclExpCellAlign > pAlign, std::unique_ptr< XclExpCellBorder > pBorder, std::unique_ptr< XclExpDxfFont > pFont, std::unique_ptr< XclExpNumFmt > pNumberFmt, std::unique_ptr< XclExpCellProt > pProt, std::unique_ptr< XclExpColor > pColor)
Definition: xestyle.cxx:3212
sal_uInt32 mnStdFmt
Replacement table.
Definition: xestyle.hxx:300
sal_uInt32 mnScNumFmt
Definition: xestyle.hxx:255
sal_uInt16 mnXclFont
Calc number format index.
Definition: xestyle.hxx:491
XclExpXFList::RecordRefType XclExpXFRef
Definition: xestyle.hxx:633
const sal_uInt16 EXC_XF_DEFAULTCELL
Excel index to default style XF.
Definition: xlstyle.hxx:139
static FindKey ToFindKey(XclExpXF const &)
Definition: xestyle.cxx:2783
sal_uInt32 GetStandardFormat() const
Returns the core index of the current standard number format.
Definition: xestyle.hxx:275
virtual ~XclExpNumFmtBuffer() override
Definition: xestyle.cxx:1352
This class is used to export Excel record streams.
Definition: xestream.hxx:72
XclExpXFId maXFId
Name of the cell style.
Definition: xestyle.hxx:555
Background area of a cell.
Definition: xestyle.hxx:50
sal_Int32 GetDxfId(const OUString &rName) const
Definition: xestyle.cxx:3172
XclExpRecordList< XclExpXF > XclExpXFList
Definition: xestyle.hxx:632
const size_t EXC_FONTLIST_NOTFOUND
Definition: xestyle.hxx:120
XclExpNumFmtVec maFormatMap
Special number formatter for conversion.
Definition: xestyle.hxx:298
std::map< OUString, sal_Int32 > maStyleNameToDxfId
Definition: xestyle.hxx:759
void SaveXml(XclExpXmlStream &rStrm) const
Definition: xestyle.cxx:1850
virtual void Save(XclExpStream &rStrm) override
Writes all FONT records contained in this buffer.
Definition: xestyle.cxx:1238
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:1067
XclExpPaletteImplRef mxImpl
Definition: xestyle.hxx:115
Border of a cell.
Definition: xestyle.hxx:49
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:3283
sal_uInt32 FindXF(const ScPatternAttr &rPattern, sal_uInt32 nForceScNumFmt, sal_uInt16 nForceXclFont, bool bForceLineBreak) const
Returns the XF ID of the cell XF containing the passed format.
Definition: xestyle.cxx:2714
void SaveXml(XclExpXmlStream &rStrm) const
Definition: xestyle.cxx:1595
const XclExpCellBorder & GetBorderData() const
Returns the cell border settings of this XF.
Definition: xestyle.hxx:448
OUString maNumFmtString
Resulting Excel format index.
Definition: xestyle.hxx:257
const XclExpCellArea & GetAreaData() const
Returns the cell fill settings of this XF.
Definition: xestyle.hxx:450
XclExpPalette(const XclExpRoot &rRoot)
Definition: xestyle.cxx:754
sal_uInt16 Insert(const XclFontData &rFontData, XclExpColorType eColorType, bool bAppFont=false)
Inserts a new font with the passed font data into the buffer if not present.
Definition: xestyle.cxx:1192
const SfxItemSet * GetItemSet() const
Definition: xestyle.hxx:474
void FillToXF3(sal_uInt16 &rnProt) const
Fills the data to the passed fields of a BIFF3-BIFF8 XF record.
Definition: xestyle.cxx:1436
This struct helps reading and writing Excel fonts.
Definition: xlstyle.hxx:285
bool FillFromItemSet(const SfxItemSet &rItemSet, XclExpPalette &rPalette, bool bStyle)
Fills the area attributes from the passed item set.
Definition: xestyle.cxx:1887
void GetMixedColors(sal_uInt16 &rnXclForeIx, sal_uInt16 &rnXclBackIx, sal_uInt8 &rnXclPattern, sal_uInt32 nForeColorId, sal_uInt32 nBackColorId) const
Returns a foreground and background color for the two passed color IDs.
Definition: xestyle.cxx:786
::std::vector< XclExpNumFmt > XclExpNumFmtVec
Definition: xestyle.hxx:295
Spreadsheet grid color.
Definition: xestyle.hxx:55
sal_uInt32 mnForeColorId
Definition: xestyle.hxx:374
XclExpCellAlign maAlignment
Cell protection flags.
Definition: xestyle.hxx:486
void SetXmlIds(sal_uInt32 nBorderId, sal_uInt32 nFillId)
Definition: xestyle.cxx:2214
OUString GetFormatCode(sal_uInt32 nScNumFmt)
Definition: xestyle.cxx:1421
sal_uInt32 GetFontColorId() const
Returns the font color identifier.
Definition: xestyle.hxx:162
void InsertUserStyles()
Inserts an XF and a STYLE record for all user defined style sheets.
Definition: xestyle.cxx:2911
Stores all default colors for a specific BIFF version.
Definition: xlstyle.hxx:250
void SaveXml(XclExpXmlStream &rStrm) const
Definition: xestyle.cxx:1442
XclExpXFBuffer(const XclExpRoot &rRoot)
Definition: xestyle.cxx:2446
const sal_uInt16 EXC_ID_DXFS
For internal use only.
Definition: xestyle.hxx:40
sal_uInt32 mnTopColorId
Color ID for right line.
Definition: xestyle.hxx:345
sal_uInt32 mnBottomColorId
Color ID for top line.
Definition: xestyle.hxx:346
ScfUInt16Vec maXFIndexVec
Contained elements describe built-in XFs.
Definition: xestyle.hxx:716
std::unique_ptr< NfKeywordTable > mpKeywordTable
Definition: xestyle.hxx:762
XclExpFontBuffer(const XclExpRoot &rRoot)
Definition: xestyle.cxx:1168
XclExpXFId()
Real Excel XF index.
Definition: xestyle.cxx:2024
void FillToXF5(sal_uInt16 &rnAlign) const
Fills the data to the passed fields of a BIFF5/BIFF7 XF record.
Definition: xestyle.cxx:1547
sal_uInt32 mnParentXFId
Background area style.
Definition: xestyle.hxx:489
XclExpCellArea maArea
Border line style.
Definition: xestyle.hxx:488
std::shared_ptr< XclExpPaletteImpl > XclExpPaletteImplRef
Definition: xestyle.hxx:114
virtual void WriteBody(XclExpStream &rStrm) override
Writes the contents of the STYLE record.
Definition: xestyle.cxx:2300
const XclExpXF * GetXFById(sal_uInt32 nXFId) const
Returns an XF record by its unique identifier.
Definition: xestyle.cxx:2488
const sal_uInt8 EXC_STYLE_USERDEF
"Followed_Hyperlink" style.
Definition: xlstyle.hxx:234
::std::vector< XclExpCellBorder > XclExpBorderList
Definition: xestyle.hxx:686
static sal_uInt32 GetXFIdFromIndex(sal_uInt16 nXFIndex)
Returns the XF identifier representing a fixed Excel XF index (e.g.
Definition: xestyle.cxx:2478
XclExpNumFmt(sal_uInt32 nScNumFmt, sal_uInt16 nXclNumFmt, const OUString &rFrmt)
format string
Definition: xestyle.hxx:259
virtual void Save(XclExpStream &rStrm) override
Saves the PALETTE record, if it differs from the default palette.
Definition: xestyle.cxx:798
XclExpFontList maFontList
Definition: xestyle.hxx:246
void SetFinalColors()
Sets the resulting Excel palette index from all used color IDs (border and area). ...
Definition: xestyle.cxx:2078
const XclExpCellProt & GetProtectionData() const
Returns the cell protection settings of this XF.
Definition: xestyle.hxx:444
Extends the XclCellArea struct for export.
Definition: xestyle.hxx:372
const XclExpFont * GetFont(sal_uInt16 nXclFont) const
Returns the specified font from font list.
Definition: xestyle.cxx:1182
ScfUInt16Vec maStyleIndexes
Maps XF IDs to XF indexes.
Definition: xestyle.hxx:717
Text in a cell.
Definition: xestyle.hxx:48
sal_uInt32 InsertCellXF(const ScPatternAttr *pPattern, sal_Int16 nScript, sal_uInt32 nForceScNumFmt, sal_uInt16 nForceXclFont, bool bForceLineBreak)
Tries to find the XF record containing the passed format or inserts a new record. ...
Definition: xestyle.cxx:2788
sal_uInt16 mnXclNumFmt
Excel font index.
Definition: xestyle.hxx:492
sal_uInt32 AppendBuiltInXF(XclExpXFRef const &xXF, sal_uInt8 nStyleId, sal_uInt8 nLevel=EXC_STYLE_NOLEVEL)
Inserts a built-in XF record without a STYLE record and returns the XF ID.
Definition: xestyle.cxx:2919
void FillToXF5(sal_uInt32 &rnArea) const
Fills the data to the passed fields of a BIFF5/BIFF7 XF record.
Definition: xestyle.cxx:1910
Access to global data from other classes.
Definition: xeroot.hxx:112
sal_uInt32 InsertStyle(const SfxStyleSheetBase *pStyleSheet)
Inserts the passed cell style.
Definition: xestyle.cxx:2473
::std::vector< XclExpCellArea > XclExpFillList
Definition: xestyle.hxx:687
bool Equals(const ScPatternAttr &rPattern, sal_uInt32 nScForceNumFmt, sal_uInt16 nForceXclFont, bool bForceLineBreak) const
Returns true, if this XF record represents the passed cell formatting.
Definition: xestyle.cxx:2064
const sal_uInt16 EXC_FONT_NOTFOUND
Application font index.
Definition: xlstyle.hxx:77
virtual bool Equals(const XclFontData &rFontData, sal_uInt32 nHash) const
Compares this font with the passed font data.
Definition: xestyle.cxx:974
sal_Int32 GetXmlCellIndex(sal_uInt32 nXFId) const
Definition: xestyle.cxx:2608
size_t mnXclMaxSize
List of all FONT records.
Definition: xestyle.hxx:247
constexpr sal_uInt32 NUMBERFORMAT_ENTRY_NOT_FOUND
void Init(const SfxItemSet &rItemSet, sal_Int16 nScript, sal_uInt32 nForceScNumFmt, sal_uInt16 nForceXclFont, bool bForceLineBreak, bool bDefStyle)
Fills all members from the passed item set.
Definition: xestyle.cxx:2102
void FillToXF5(sal_uInt32 &rnBorder, sal_uInt32 &rnArea) const
Fills the data to the passed fields of a BIFF5/BIFF7 XF record.
Definition: xestyle.cxx:1773
sal_uInt32 mnScNumFmt
XF ID of parent XF record.
Definition: xestyle.hxx:490
bool operator<(const FindKey &other) const
Definition: xestyle.hxx:697
std::map< Color, sal_Int32 > maColorToDxfId
Definition: xestyle.hxx:760
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:2639
XclExpXFList maXFList
Definition: xestyle.hxx:710
sal_uInt32 mnLeftColorId
Definition: xestyle.hxx:343
Base class for all Excel records.
Definition: xerecord.hxx:38
void ConvertXFIndex(const XclExpRoot &rRoot)
Converts the XF identifier in mnXFId to an Excel XF index and stores it in mnXFIndex.
Definition: xestyle.cxx:2030
virtual void WriteBody(XclExpStream &rStrm) override
Writes the contents of the FONT record.
Definition: xestyle.cxx:990
Stores all number formats used in the document.
Definition: xestyle.hxx:268
Extends the XclCellAlign struct for export.
Definition: xestyle.hxx:322
sal_uInt32 InsertColor(const Color &rColor, XclExpColorType eType, sal_uInt16 nAutoDefault=0)
Inserts the color into the list and updates weighting.
Definition: xestyle.cxx:766
Helper functions for font export.
Definition: xestyle.hxx:123
Color maForeColor
Background color ID.
Definition: xestyle.hxx:376
XclExpFont(const XclExpRoot &rRoot, const XclFontData &rFontData, XclExpColorType eColorType)
Definition: xestyle.cxx:959
bool FillFromItemSet(const SfxItemSet &rItemSet, bool bStyle=false)
Fills the protection attributes from the passed item set.
Definition: xestyle.cxx:1428
void InitDefaultFonts()
Initializes the default fonts for the current BIFF version.
Definition: xestyle.cxx:1258
std::vector< std::unique_ptr< XclExpDxf > > DxfContainer
Definition: xestyle.hxx:758
XclExpCellBorder()
Color ID for diagonal line(s).
Definition: xestyle.cxx:1697
sal_uInt32 AppendBuiltInXFWithStyle(XclExpXFRef const &xXF, sal_uInt8 nStyleId, sal_uInt8 nLevel=EXC_STYLE_NOLEVEL)
Inserts a built-in XF and STYLE record and returns the XF ID.
Definition: xestyle.cxx:2931
sal_uInt32 mnColorId
All font attributes.
Definition: xestyle.hxx:175
void SetFinalColors(const XclExpPalette &rPalette)
Fills the mn***Color base members from the mn***ColorId members.
Definition: xestyle.cxx:1905
virtual void Save(XclExpStream &rStrm) override
Writes all XF records contained in this buffer.
Definition: xestyle.cxx:2616
DocumentType eType
const XclFontData & GetFontData() const
Returns read-only access to font data.
Definition: xestyle.hxx:160
::std::unique_ptr< SvNumberFormatter > SvNumberFormatterPtr
Definition: xestyle.hxx:265
XclExpXmlStyleSheet(const XclExpRoot &rRoot)
Definition: xestyle.cxx:3278
composite key for the find-map, so we can do partial key searching
Definition: xestyle.hxx:690
XclFontData maData
Definition: xestyle.hxx:174
Stores all data of an Excel font and provides export of FONT records.
Definition: xestyle.hxx:153
Represents a default XF record.
Definition: xestyle.hxx:525
sal_uInt32 GetScNumFmt() const
Definition: xestyle.hxx:476
Extends the XclCellBorder struct for export.
Definition: xestyle.hxx:341
Contains all cell protection attributes.
Definition: xlstyle.hxx:476
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:1380
sal_uInt16 GetColorIndex(sal_uInt32 nColorId) const
Returns the Excel palette index of the color with passed color ID.
Definition: xestyle.cxx:781
std::unique_ptr< XclExpCellProt > mpProt
Definition: xestyle.hxx:742
sal_uInt32 mnDiagColorId
Color ID for bottom line.
Definition: xestyle.hxx:347
Contains all cell alignment attributes.
Definition: xlstyle.hxx:487
XclExpNumFmtBuffer(const XclExpRoot &rRoot)
Definition: xestyle.cxx:1336
std::unique_ptr< XclExpDxfFont > mpFont
Definition: xestyle.hxx:740
const sal_uInt16 EXC_ID_FONTLIST
Definition: xestyle.hxx:37
sal_uInt32 InsertStyleXF(const SfxStyleSheetBase &rStyleSheet)
Inserts the passed cell style.
Definition: xestyle.cxx:2840
sal_uInt16 Insert(sal_uInt32 nScNumFmt)
Inserts a number format into the format buffer.
Definition: xestyle.cxx:1356
ScDxfFont maDxfData
Definition: xestyle.hxx:187
bool mbPredefined
Level for RowLevel/ColLevel styles.
Definition: xestyle.hxx:681
XclExpFillList maFills
List of borders used by XF records.
Definition: xestyle.hxx:721
void Finalize()
Reduces the XF record list to the maximum allowed number of records.
Definition: xestyle.cxx:2493
void SetNumFmt(sal_uInt16 nXclNumFmt)
Sets the Excel number format index.
Definition: xestyle.cxx:2271
const XclFontData & GetAppFontData() const
Returns the application font data of this file, needed e.g.
Definition: xestyle.cxx:1187
Represents an XF record which contains all formatting data of a cell or cell style.
Definition: xestyle.hxx:427
sal_uInt32 mnHash
Unique color ID for text color.
Definition: xestyle.hxx:176
Stores all used colors in the document.
Definition: xestyle.hxx:74
void WriteFormatRecord(XclExpStream &rStrm, sal_uInt16 nXclNumFmt, const OUString &rFormatStr)
Writes the FORMAT record with index nXclIx and format string rFormatStr.
Definition: xestyle.cxx:1394
std::unique_ptr< NfKeywordTable > mpKeywordTable
Maps core formats to Excel indexes.
Definition: xestyle.hxx:299
void SaveXFXml(XclExpXmlStream &rStrm, XclExpXF &rXF)
Definition: xestyle.cxx:2695
sal_uInt32 FindBuiltInXF(sal_uInt8 nStyleId, sal_uInt8 nLevel) const
Returns the XF ID of a built-in style XF, searches by style identifier.
Definition: xestyle.cxx:2772
sal_uInt8 mnLevel
Built-in style identifier.
Definition: xestyle.hxx:680
std::unique_ptr< XclExpCellAlign > mpAlign
Definition: xestyle.hxx:738
const sal_uInt8 EXC_STYLE_NOLEVEL
Number of outline level styles.
Definition: xlstyle.hxx:237
virtual ~XclExpDxf() override
Definition: xestyle.cxx:3231
void InsertDefaultRecords()
Inserts all default XF and STYLE records.
Definition: xestyle.cxx:2955
Line in a chart.
Definition: xestyle.hxx:52
void FillToCF8(sal_uInt16 &rnPattern, sal_uInt16 &rnColor) const
Fills the data to the passed fields of a BIFF8 CF (conditional format) record.
Definition: xestyle.cxx:1924
const SfxItemSet * mpItemSet
Definition: xestyle.hxx:483
XclExpBorderList maBorders
List of XF records in XF index order.
Definition: xestyle.hxx:720
virtual bool Equals(const XclFontData &rFontData, sal_uInt32 nHash) const override
Returns always false to never find this font while searching the font list.
Definition: xestyle.cxx:1158
virtual ~XclExpPalette() override
Definition: xestyle.cxx:762
virtual void Save(XclExpStream &rStrm) override
Skips writing this record.
Definition: xestyle.cxx:1163
ScfUInt16Vec maCellIndexes
Maps XF IDs to OOXML Style indexes.
Definition: xestyle.hxx:718
sal_uInt8 GetUsedFlags() const
Returns the bits specifying the used attributes.
Definition: xestyle.cxx:2153
void Finalize()
Reduces the color list to the maximum count of the current BIFF version.
Definition: xestyle.cxx:776
void FillToCF8(sal_uInt16 &rnLine, sal_uInt32 &rnColor) const
Fills the data to the passed fields of a BIFF8 CF (conditional format) record.
Definition: xestyle.cxx:1801
sal_uInt8 mnLevel
Built-in style identifier.
Definition: xestyle.hxx:557
void SaveXml(XclExpXmlStream &rStrm)
Definition: xestyle.cxx:1328
const sal_uInt16 EXC_ID_XFLIST
For internal use only.
Definition: xestyle.hxx:39
bool FillFromItemSet(const SfxItemSet &rItemSet, XclExpPalette &rPalette, XclBiff eBiff, bool bStyle=false)
Fills the border attributes from the passed item set.
Definition: xestyle.cxx:1706
Stores a core number format index with corresponding Excel format index.
Definition: xestyle.hxx:253
void WriteBody8(XclExpStream &rStrm)
Definition: xestyle.cxx:2184
bool IsBuiltIn() const
Returns true, if this record represents an Excel built-in style.
Definition: xestyle.hxx:545
sal_uInt32 InsertWithNumFmt(const ScPatternAttr *pPattern, sal_Int16 nScript, sal_uInt32 nForceScNumFmt, bool bForceLineBreak)
Finds or creates a cell XF record for the passed item set, with custom number format.
Definition: xestyle.cxx:2468
sal_uInt16 mnXclNumFmt
Core index of the number format.
Definition: xestyle.hxx:256
virtual void WriteBody(XclExpStream &rStrm) override
Writes the contents of the XF record.
Definition: xestyle.cxx:2201
void AddColor(Color aColor)
Definition: xestyle.cxx:3188
Extends the XclCellProt struct for export.
Definition: xestyle.hxx:308
bool FillFromItemSet(const SfxItemSet &rItemSet)
Definition: xestyle.cxx:2002
Contains color and line style for each cell border line.
Definition: xlstyle.hxx:522
bool CheckItems(const XclExpRoot &rRoot, const SfxItemSet &rItemSet, sal_Int16 nScript, bool bDeep)
Returns true, if at least one font related item is set in the passed item set.
Definition: xestyle.cxx:907
XclExpXFList maSortedXFList
Maps XF IDs to OOXML Cell indexes.
Definition: xestyle.hxx:719
bool FillFromItemSet(const XclRoot &rRoot, const SfxItemSet &rItemSet, bool bForceLineBreak, XclBiff eBiff, bool bStyle=false)
Fills the alignment attributes from the passed item set.
Definition: xestyle.cxx:1449
sal_uInt32 mnRightColorId
Color ID for left line.
Definition: xestyle.hxx:344
static sal_uInt32 GetDefCellXFId()
Returns the XF identifier representing the default cell XF.
Definition: xestyle.cxx:2483
void Initialize()
Inserts predefined built-in styles and user-defined styles.
Definition: xestyle.cxx:2451
sal_Int32 mnFillId
OOXML Border Index.
Definition: xestyle.hxx:494
std::unique_ptr< XclExpColor > mpColor
Definition: xestyle.hxx:743
XclExpBuiltInInfo()
true = STYLE record created.
Definition: xestyle.cxx:2381
const XclExpCellAlign & GetAlignmentData() const
Returns the alignment settings of this XF.
Definition: xestyle.hxx:446
std::map< FindKey, std::vector< sal_uInt32 > > maXFFindMap
List of all XF records.
Definition: xestyle.hxx:712
Represents a STYLE record containing the data of a cell style.
Definition: xestyle.hxx:538
::std::vector< sal_uInt16 > ScfUInt16Vec
Definition: ftools.hxx:255
void SetFinalColors(const XclExpPalette &rPalette)
Fills the mn***Color base members from the mn***ColorId members.
Definition: xestyle.cxx:1764
Color maColor
Definition: xestyle.hxx:403
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:3196
size_t Find(const XclFontData &rFontData)
Tries to find the passed font and returns the current list index.
Definition: xestyle.cxx:1304
unsigned char sal_uInt8
void FillToXF8(sal_uInt32 &rnBorder2, sal_uInt16 &rnArea) const
Fills the data to the passed fields of a BIFF8 XF record.
Definition: xestyle.cxx:1917
void FillToXF8(sal_uInt32 &rnBorder1, sal_uInt32 &rnBorder2) const
Fills the data to the passed fields of a BIFF8 XF record.
Definition: xestyle.cxx:1785
sal_uInt32 mnXFId
Definition: xestyle.hxx:413
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:804
XclExpStyle(sal_uInt32 nXFId, const OUString &rStyleName)
Definition: xestyle.cxx:2277
sal_uInt16 mnXclOffset
Key for standard number format.
Definition: xestyle.hxx:301
XclExpDefaultXF(const XclExpRoot &rRoot, bool bCellXF)
Definition: xestyle.cxx:2260
::std::map< sal_uInt32, XclExpBuiltInInfo > XclExpBuiltInMap
Definition: xestyle.hxx:685
DxfContainer maDxf
Definition: xestyle.hxx:761
XclExpXFId(sal_uInt32 nXFId)
Definition: xestyle.hxx:417
Stores the data of all fonts used in the document.
Definition: xestyle.hxx:206
void SaveXml(XclExpXmlStream &rStrm) const
Definition: xestyle.cxx:2013
A combination of unique XF identifier with real Excel XF index.
Definition: xestyle.hxx:411
XclExpCellProt maProtection
Pointer to the item set (we do not own it).
Definition: xestyle.hxx:485
sal_Int32 mnBorderId
Excel number format index.
Definition: xestyle.hxx:493
sal_uInt32 mnBackColorId
Foreground color ID.
Definition: xestyle.hxx:375
sal_uInt32 Insert(const ScPatternAttr *pPattern, sal_Int16 nScript)
Finds or creates a cell XF record for the passed item set.
Definition: xestyle.cxx:2457
Used as placeholder for font index 4, which is not used in Excel.
Definition: xestyle.hxx:191
Contains background colors and pattern for a cell.
Definition: xlstyle.hxx:543
Extended info about a built-in XF.
Definition: xestyle.hxx:677
SvNumberFormatterPtr mxFormatter
Definition: xestyle.hxx:297
sal_uInt16 mnXFIndex
Temporary XF identifier.
Definition: xestyle.hxx:414
virtual void WriteBody(XclExpStream &rStrm) override
Writes the contents of the PALETTE record.
Definition: xestyle.cxx:810
XclExpRecordList< XclExpStyle > maStyleList
map of itemset to vector of positions, to speed up find
Definition: xestyle.hxx:714
bool Equals(const XclXFBase &rCmp) const
Returns true, if this object is equal to the passed.
Definition: xlstyle.cxx:1737
void WriteBody5(XclExpStream &rStrm)
Definition: xestyle.cxx:2167
sal_Int32 GetDxfByColor(Color aColor) const
Definition: xestyle.cxx:3180
XclExpRecordList< XclExpFont > XclExpFontList
Definition: xestyle.hxx:243
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:2220
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:979
sal_Int32 GetXmlStyleIndex(sal_uInt32 nXFId) const
Definition: xestyle.cxx:2600
Text color in a chart.
Definition: xestyle.hxx:51
const sal_uInt16 EXC_ID_FORMATLIST
For internal use only.
Definition: xestyle.hxx:38
bool mbHasStyleRec
true = XF still predefined.
Definition: xestyle.hxx:682
void SaveXmlExt(XclExpXmlStream &rStrm)
Definition: xestyle.cxx:3257
sal_uInt8 mnStyleId
XF identifier for style formatting.
Definition: xestyle.hxx:556
std::unique_ptr< XclExpCellArea > mpCellArea
Definition: xestyle.hxx:744
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:3235
XclExpBlindFont(const XclExpRoot &rRoot)
Definition: xestyle.cxx:1153
Area in a chart.
Definition: xestyle.hxx:53
OUString maName
Definition: xestyle.hxx:554
const SfxItemSet * mpItemSet
Definition: xestyle.hxx:693
static sal_uInt32 GetColorIdFromIndex(sal_uInt16 nIndex)
Returns the color ID representing a fixed Excel palette index (i.e.
Definition: xestyle.cxx:771
void SvStream & rStrm
ScDxfFont GetDxfFontFromItemSet(const XclExpRoot &rRoot, const SfxItemSet &rSet)
Get a dxf related font object from the item set.
Definition: xestyle.cxx:898
Access to global data for a filter object (imported or exported document) from other classes...
Definition: xlroot.hxx:127
void InitDefault()
Initializes with default values.
Definition: xestyle.cxx:2093
Color GetColor(sal_uInt16 nXclIndex) const
Returns the color for a (non-zero-based) Excel palette entry.
Definition: xestyle.cxx:793
Contains base members for XF record import/export.
Definition: xlstyle.hxx:562
virtual void SaveXml(XclExpXmlStream &rStrm) override
Definition: xestyle.cxx:2335
void SetFont(sal_uInt16 nXclFont)
Sets the Excel font index.
Definition: xestyle.cxx:2265
void AddBorderAndFill(const XclExpXF &rXF)
Definition: xestyle.cxx:3030
Color maBackColor
Definition: xestyle.hxx:377
XclExpFontList::RecordRefType XclExpFontRef
Definition: xestyle.hxx:244
sal_uInt32 InsertWithFont(const ScPatternAttr *pPattern, sal_Int16 nScript, sal_uInt16 nForceXclFont, bool bForceLineBreak)
Finds or creates a cell XF record for the passed item set.
Definition: xestyle.cxx:2462
XclExpDxfs(const XclExpRoot &rRoot)
Definition: xestyle.cxx:3043
Base class for single records with any content.
Definition: xerecord.hxx:142
Text color in a form control.
Definition: xestyle.hxx:54
XclExpCellBorder maBorder
All alignment attributes.
Definition: xestyle.hxx:487
void AppendXFIndex(sal_uInt32 nXFId)
Appends a XF index to the internal ID<->index maps.
Definition: xestyle.cxx:3020
sal_Int16 GetFirstUsedScript(const XclExpRoot &rRoot, const SfxItemSet &rItemSet)
Returns the script type of the first font item found in the item set and its parents.
Definition: xestyle.cxx:832
sal_uInt16 GetXFIndex(sal_uInt32 nXFId) const
Returns the Excel XF index of the XF record with passed XF ID.
Definition: xestyle.cxx:2590
XclExpDxfFont(const XclExpRoot &rRoot, const SfxItemSet &rItemSet)
Definition: xestyle.cxx:1019
XclExpXF(const XclExpRoot &rRoot, const ScPatternAttr &rPattern, sal_Int16 nScript, sal_uInt32 nScForceNumFmt=NUMBERFORMAT_ENTRY_NOT_FOUND, sal_uInt16 nForceXclFont=EXC_FONT_NOTFOUND, bool bForceLineBreak=false)
Constructs a cell XF record from the passed Calc cell formatting.
Definition: xestyle.cxx:2035
std::unique_ptr< XclExpCellBorder > mpBorder
Definition: xestyle.hxx:739