46#include <editeng/editids.hrc>
52#include <document.hxx>
58#include <stlsheet.hxx>
76#include <com/sun/star/container/XIndexAccess.hpp>
77#include <com/sun/star/beans/XPropertySet.hpp>
78#include <com/sun/star/frame/XModel.hpp>
93 explicit PaletteIndex(
ColorVec&& rColorTable ) :
maColor( std::move(rColorTable) ) {}
96 virtual ::sal_Int32 SAL_CALL getCount()
override
101 virtual uno::Any SAL_CALL getByIndex( ::sal_Int32
Index )
override
108 virtual uno::Type SAL_CALL getElementType()
override
110 return ::cppu::UnoType<sal_Int32>::get();
112 virtual sal_Bool SAL_CALL hasElements()
override
133 aColors.resize( nColors );
137 uno::Reference< beans::XPropertySet > xProps( pDocShell->
GetModel(), uno::UNO_QUERY );
140 uno::Reference< container::XIndexAccess > xIndex(
new PaletteIndex( std::move(aColors) ) );
141 xProps->setPropertyValue(
"ColorPalette",
uno::Any( xIndex ) );
173 const size_t nMinRecordSize = 4;
174 const size_t nMaxRecords =
rStrm.GetRecLeft() / nMinRecordSize;
177 SAL_WARN(
"sc",
"Parsing error: " << nMaxRecords <<
178 " max possible entries, but " <<
nCount <<
" claimed, truncating");
195 mbHasCharSet( false ),
224 pDocShell->GetItem( SID_ATTR_CHAR_FONTLIST ) ) )
226 if(
const FontList* pFontList = pInfoItem->GetFontList() )
245 return (eFontEnc == RTL_TEXTENCODING_DONTKNOW) ?
GetTextEncoding() : eFontEnc;
290 sal_uInt32 nHeight =
rStrm.ReaduInt32();
291 sal_uInt32 nStyle =
rStrm.ReaduInt32();
292 sal_uInt16 nWeight =
rStrm.ReaduInt16();
296 sal_uInt32 nColor =
rStrm.ReaduInt32();
298 sal_uInt32 nFontFlags1 =
rStrm.ReaduInt32();
300 sal_uInt32 nFontFlags3 =
rStrm.ReaduInt32();
325#define PUTITEM( item, sc_which, ee_which ) \
326 ScfTools::PutItem( rItemSet, item, (bEE ? (static_cast<sal_uInt16>(ee_which)) : (sc_which)), bSkipPoolDefs )
332 rtl_TextEncoding eTempTextEnc = (bEE && (eFontEnc ==
GetTextEncoding())) ?
424 nFlags =
rStrm.ReaduInt16();
440 nFlags =
rStrm.ReaduInt16();
490 xFontCharMap->HasChar( 0x3041 ) ||
491 xFontCharMap->HasChar( 0x30A1 ) ||
492 xFontCharMap->HasChar( 0x3111 ) ||
493 xFontCharMap->HasChar( 0x3131 ) ||
494 xFontCharMap->HasChar( 0x3301 ) ||
495 xFontCharMap->HasChar( 0x3401 ) ||
496 xFontCharMap->HasChar( 0x4E01 ) ||
497 xFontCharMap->HasChar( 0x7E01 ) ||
498 xFontCharMap->HasChar( 0xA001 ) ||
499 xFontCharMap->HasChar( 0xAC01 ) ||
500 xFontCharMap->HasChar( 0xCC01 ) ||
501 xFontCharMap->HasChar( 0xF901 ) ||
502 xFontCharMap->HasChar( 0xFF71 );
505 xFontCharMap->HasChar( 0x05D1 ) ||
506 xFontCharMap->HasChar( 0x0631 ) ||
507 xFontCharMap->HasChar( 0x0721 ) ||
508 xFontCharMap->HasChar( 0x0911 ) ||
509 xFontCharMap->HasChar( 0x0E01 ) ||
510 xFontCharMap->HasChar( 0xFB21 ) ||
511 xFontCharMap->HasChar( 0xFB51 ) ||
512 xFontCharMap->HasChar( 0xFE71 );
532 aCtrlFontData.
maName =
"Helv";
537 aCtrlFontData.
maName =
"Tahoma";
553 aAppFontData.
maName =
"Arial";
598 sal_uInt16 nFontIdx,
bool bSkipPoolDefs )
const
601 pFont->FillToItemSet( rItemSet,
eType, bSkipPoolDefs );
608 pFont->WriteFontProperties( rPropSet,
eType, pFontColor );
651 aFormat =
rStrm.ReadByteString(
false );
656 aFormat =
rStrm.ReadByteString(
false );
661 aFormat =
rStrm.ReadByteString(
false );
666 aFormat =
rStrm.ReadUniString();
693 OUString aFormat =
rStrm.ReadUniString();
702 OSL_ENSURE(
maIndexMap.empty(),
"XclImpNumFmtBuffer::CreateScFormats - already created" );
705 for(
const auto& [rXclNumFmt, rNumFmt] :
GetFormatMap() )
709 if( !rNumFmt.maFormat.isEmpty() )
711 OUString aFormat( rNumFmt.maFormat );
718 nKey = rFormatter.
GetFormatIndex( rNumFmt.meOffset, rNumFmt.meLanguage );
727 XclImpIndexMap::const_iterator aIt =
maIndexMap.find( nXclNumFmt );
768 mnHorAlign = ::extract_value< sal_uInt8 >( nFlags, 0, 3 );
773 mnHorAlign = ::extract_value< sal_uInt8 >( nAlign, 0, 3 );
780 mnVerAlign = ::extract_value< sal_uInt8 >( nAlign, 4, 2 );
781 mnOrient = ::extract_value< sal_uInt8 >( nAlign, 6, 2 );
786 mnHorAlign = ::extract_value< sal_uInt8 >( nAlign, 0, 3 );
787 mnVerAlign = ::extract_value< sal_uInt8 >( nAlign, 4, 3 );
789 mnOrient = ::extract_value< sal_uInt8 >( nAlign, 8, 2 );
794 mnHorAlign = ::extract_value< sal_uInt8 >( nAlign, 0, 3 );
795 mnVerAlign = ::extract_value< sal_uInt8 >( nAlign, 4, 3 );
797 mnRotation = ::extract_value< sal_uInt8 >( nAlign, 8, 8 );
798 mnIndent = ::extract_value< sal_uInt8 >( nMiscAttrib, 0, 4 );
800 mnTextDir = ::extract_value< sal_uInt8 >( nMiscAttrib, 6, 2 );
805 mnHorAlign = extract_value< sal_uInt8 >( nAlign, 0, 3 );
807 mnVerAlign = ::extract_value< sal_uInt8 >( nAlign, 4, 3 );
808 mnRotation = ::extract_value< sal_uInt8 >( nAlign, 8, 8 );
809 mnIndent = ::extract_value< sal_uInt8 >( nMiscAttrib, 0, 4 );
811 mnTextDir = ::extract_value< sal_uInt8 >( nMiscAttrib, 6, 2 );
829 sal_uInt16 nScIndent =
mnIndent * 200;
843 bool bAsianVert = bStacked && pFont && pFont->
HasAsianChars();
888 mnBottomLine = ::extract_value< sal_uInt8 >( nArea, 22, 3 );
892 mnBottomColor = ::extract_value< sal_uInt16 >( nArea, 25, 7 );
899 mnLeftLine = ::extract_value< sal_uInt8 >( nBorder1, 0, 4 );
900 mnRightLine = ::extract_value< sal_uInt8 >( nBorder1, 4, 4 );
901 mnTopLine = ::extract_value< sal_uInt8 >( nBorder1, 8, 4 );
902 mnBottomLine = ::extract_value< sal_uInt8 >( nBorder1, 12, 4 );
903 mnLeftColor = ::extract_value< sal_uInt16 >( nBorder1, 16, 7 );
904 mnRightColor = ::extract_value< sal_uInt16 >( nBorder1, 23, 7 );
905 mnTopColor = ::extract_value< sal_uInt16 >( nBorder2, 0, 7 );
906 mnBottomColor = ::extract_value< sal_uInt16 >( nBorder2, 7, 7 );
911 mnDiagLine = ::extract_value< sal_uInt8 >( nBorder2, 21, 4 );
912 mnDiagColor = ::extract_value< sal_uInt16 >( nBorder2, 14, 7 );
919 mnLeftLine = ::extract_value< sal_uInt8 >( nLineStyle, 0, 4 );
920 mnRightLine = ::extract_value< sal_uInt8 >( nLineStyle, 4, 4 );
921 mnTopLine = ::extract_value< sal_uInt8 >( nLineStyle, 8, 4 );
922 mnBottomLine = ::extract_value< sal_uInt8 >( nLineStyle, 12, 4 );
923 mnLeftColor = ::extract_value< sal_uInt16 >( nLineColor, 0, 7 );
924 mnRightColor = ::extract_value< sal_uInt16 >( nLineColor, 7, 7 );
925 mnTopColor = ::extract_value< sal_uInt16 >( nLineColor, 16, 7 );
926 mnBottomColor = ::extract_value< sal_uInt16 >( nLineColor, 23, 7 );
948 static const sal_uInt16 ppnLineParam[][ 4 ] =
951 { 0, table::BorderLineStyle::SOLID },
973 rLine.
SetWidth( ppnLineParam[ nXclLine ][ 0 ] );
975 ppnLineParam[ nXclLine ][ 1 ]) );
988 aBoxItem.
SetLine( &aLine, SvxBoxItemLine::LEFT );
990 aBoxItem.
SetLine( &aLine, SvxBoxItemLine::RIGHT );
992 aBoxItem.
SetLine( &aLine, SvxBoxItemLine::TOP );
994 aBoxItem.
SetLine( &aLine, SvxBoxItemLine::BOTTOM );
1034 mnPattern = ::extract_value< sal_uInt8 >( nArea, 0, 6 );
1035 mnForeColor = ::extract_value< sal_uInt16 >( nArea, 6, 5 );
1036 mnBackColor = ::extract_value< sal_uInt16 >( nArea, 11, 5 );
1042 mnPattern = ::extract_value< sal_uInt8 >( nArea, 16, 6 );
1043 mnForeColor = ::extract_value< sal_uInt16 >( nArea, 0, 7 );
1044 mnBackColor = ::extract_value< sal_uInt16 >( nArea, 7, 7 );
1050 mnPattern = ::extract_value< sal_uInt8 >( nBorder2, 26, 6 );
1051 mnForeColor = ::extract_value< sal_uInt16 >( nArea, 0, 7 );
1052 mnBackColor = ::extract_value< sal_uInt16 >( nArea, 7, 7 );
1058 mnForeColor = ::extract_value< sal_uInt16 >( nColor, 0, 7 );
1059 mnBackColor = ::extract_value< sal_uInt16 >( nColor, 7, 7 );
1060 mnPattern = ::extract_value< sal_uInt8 >( nPattern, 10, 6 );
1102 mpStyleSheet( nullptr ),
1114 sal_uInt8 nReadFont, nReadNumFmt, nFlags;
1115 nReadFont =
rStrm.ReaduInt8();
1117 nReadNumFmt =
rStrm.ReaduInt8();
1118 nFlags =
rStrm.ReaduInt8();
1135 sal_uInt16 nTypeProt, nAlign, nArea;
1137 nReadFont =
rStrm.ReaduInt8();
1138 nReadNumFmt =
rStrm.ReaduInt8();
1139 nTypeProt =
rStrm.ReaduInt16();
1140 nAlign =
rStrm.ReaduInt16();
1141 nArea =
rStrm.ReaduInt16();
1146 mnParent = ::extract_value< sal_uInt16 >( nAlign, 4, 12 );
1147 SetUsedFlags( ::extract_value< sal_uInt8 >( nTypeProt, 10, 6 ) );
1161 sal_uInt16 nTypeProt, nAlign, nArea;
1163 nReadFont =
rStrm.ReaduInt8();
1164 nReadNumFmt =
rStrm.ReaduInt8();
1165 nTypeProt =
rStrm.ReaduInt16();
1166 nAlign =
rStrm.ReaduInt16();
1167 nArea =
rStrm.ReaduInt16();
1172 mnParent = ::extract_value< sal_uInt16 >( nTypeProt, 4, 12 );
1173 SetUsedFlags( ::extract_value< sal_uInt8 >( nAlign, 10, 6 ) );
1187 sal_uInt16 nTypeProt, nAlign;
1190 nTypeProt =
rStrm.ReaduInt16();
1191 nAlign =
rStrm.ReaduInt16();
1192 nArea =
rStrm.ReaduInt32();
1197 mnParent = ::extract_value< sal_uInt16 >( nTypeProt, 4, 12 );
1198 SetUsedFlags( ::extract_value< sal_uInt8 >( nAlign, 10, 6 ) );
1209 sal_uInt32 nBorder1, nBorder2;
1210 sal_uInt16 nTypeProt, nAlign, nMiscAttrib, nArea;
1213 nTypeProt =
rStrm.ReaduInt16();
1214 nAlign =
rStrm.ReaduInt16();
1215 nMiscAttrib =
rStrm.ReaduInt16();
1216 nBorder1 =
rStrm.ReaduInt32();
1217 nBorder2 =
rStrm.ReaduInt32( );
1218 nArea =
rStrm.ReaduInt16();
1222 mnParent = ::extract_value< sal_uInt16 >( nTypeProt, 4, 12 );
1223 SetUsedFlags( ::extract_value< sal_uInt8 >( nMiscAttrib, 10, 6 ) );
1340 std::vector<ScAttrEntry>& rAttrs,
SCROW nRow1,
SCROW nRow2, sal_uInt32 nForceScNumFmt)
1367 ScResId(STR_STYLENAME_STANDARD), SfxStyleFamily::Para));
1388 bool bHasGap =
false;
1389 if (rAttrs.empty() && nRow1 > 0)
1393 if (!rAttrs.empty() && rAttrs.back().nEndRow + 1 < nRow1)
1402 rAttrs.push_back(aEntry);
1408 rAttrs.push_back(aEntry);
1442 aXF.
mnXclNumFmt = ::extract_value< sal_uInt16 >( nFlags2, 0, 6 );
1443 aXF.
mnXclFont = ::extract_value< sal_uInt16 >( nFlags2, 6, 2 );
1474 mpStyleSheet( nullptr )
1482 sal_uInt16 nXFIndex;
1483 nXFIndex =
rStrm.ReaduInt16();
1500 nExtFlags =
rStrm.ReaduInt8();
1519 bool bCreatePattern =
false;
1529 ScResId( STR_STYLENAME_STANDARD ), SfxStyleFamily::Para ) );
1530 OSL_ENSURE(
mpStyleSheet,
"XclImpStyle::CreateStyleSheet - Default style not found" );
1531 bCreatePattern =
true;
1542 bCreatePattern =
true;
1575 std::unique_ptr<XclImpXF> xXF = std::make_unique<XclImpXF>(
GetRoot());
1577 maXFList.emplace_back(std::move(xXF));
1582 std::unique_ptr<XclImpStyle> xStyle(std::make_unique<XclImpStyle>(
GetRoot()));
1583 xStyle->ReadStyle(
rStrm);
1585 rStyleList.emplace_back(std::move(xStyle));
1587 OSL_ENSURE(
maStylesByXf.count( pStyle->
GetXfId() ) == 0,
"XclImpXFBuffer::ReadStyle - multiple styles with equal XF identifier" );
1605struct IgnoreCaseCompare
1607 bool operator()( std::u16string_view rName1, std::u16string_view rName2 )
const
1616 std::map< OUString, XclImpStyle*, IgnoreCaseCompare > aCellStyles;
1617 std::vector< XclImpStyle* > aConflictNameStyles;
1629 OUString aStandardName =
ScResId( STR_STYLENAME_STANDARD );
1631 if( (pStyleSheet->GetName() != aStandardName) && (bReserveAll || !pStyleSheet->IsUserDefined()) )
1632 if( aCellStyles.count( pStyleSheet->GetName() ) == 0 )
1633 aCellStyles[ pStyleSheet->GetName() ] =
nullptr;
1640 OSL_ENSURE( bReserveAll || (aCellStyles.count( aStyleName ) == 0),
1641 "XclImpXFBuffer::CreateUserStyles - multiple styles with equal built-in identifier" );
1642 if( aCellStyles.count( aStyleName ) > 0 )
1643 aConflictNameStyles.push_back( rxStyle.get() );
1645 aCellStyles[ aStyleName ] = rxStyle.get();
1653 if( !rxStyle->GetName().isEmpty() )
1655 if( aCellStyles.count( rxStyle->GetName() ) > 0 )
1656 aConflictNameStyles.push_back( rxStyle.get() );
1658 aCellStyles[ rxStyle->GetName() ] = rxStyle.get();
1665 OUString aUnusedName;
1669 aUnusedName = pStyle->GetName() +
" " + OUString::number( ++
nIndex );
1671 while( aCellStyles.count( aUnusedName ) > 0 );
1672 aCellStyles[ aUnusedName ] = pStyle;
1676 for(
auto& [rStyleName, rpStyle] : aCellStyles )
1678 rpStyle->CreateUserStyle( rStyleName );
1683 XclImpStyleMap::iterator aIt =
maStylesByXf.find( nXFIndex );
1684 return (aIt ==
maStylesByXf.end()) ? nullptr : aIt->second->CreateStyleSheet();
1710 OSL_ENSURE(
mnScRow2 < rNextRange.
mnScRow1,
"XclImpXFRange::Expand - rows out of order" );
1723 OSL_ENSURE(
maIndexList.empty(),
"XclImpXFRangeColumn::SetDefaultXF - Setting Default Column XF is not empty" );
1735 Find( pPrevRange, pNextRange, nNextIndex, nScRow );
1741 if( pPrevRange->
Contains( nScRow ) )
1752 if( nFirstScRow == nLastScRow )
1758 else if( nFirstScRow == nScRow )
1762 if( !pPrevRange || !pPrevRange->
Expand( nScRow, rXFIndex ) )
1765 else if( nLastScRow == nScRow )
1768 if( !pNextRange || !pNextRange->
Expand( nScRow, rXFIndex ) )
1780 else if( pPrevRange->
Expand( nScRow, rXFIndex ) )
1788 if( pNextRange && pNextRange->
Expand( nScRow, rXFIndex ) )
1808 rpPrevRange = rpNextRange =
nullptr;
1818 if( rpNextRange->
mnScRow1 <= nScRow )
1820 rpPrevRange = rpNextRange;
1821 rpNextRange =
nullptr;
1827 if( nScRow < rpPrevRange->mnScRow1 )
1829 rpNextRange = rpPrevRange;
1830 rpPrevRange =
nullptr;
1842 while( ((rnNextIndex - nPrevIndex) > 1) && (rpPrevRange->
mnScRow2 < nScRow) )
1844 nMidIndex = (nPrevIndex + rnNextIndex) / 2;
1846 OSL_ENSURE( pMidRange,
"XclImpXFRangeColumn::Find - missing XF index range" );
1847 if( nScRow < pMidRange->mnScRow1 )
1849 rpNextRange = pMidRange;
1850 rnNextIndex = nMidIndex;
1854 rpPrevRange = pMidRange;
1855 nPrevIndex = nMidIndex;
1860 if( nScRow <= rpPrevRange->mnScRow2 )
1862 rnNextIndex = nPrevIndex + 1;
1875 if( prevRange.
Expand( nextRange ) )
1901 size_t nIndex =
static_cast< size_t >( nScCol );
1950 size_t nIndex =
static_cast< size_t >( nScCol );
1953 OSL_ENSURE( !
maColumns[
nIndex ],
"XclImpXFRangeBuffer::SetColumnDefXF - default column of XFs already has values" );
1981 if( (nScCol1 < nScCol2) || (nScRow1 < nScRow2) )
1994 SCCOL pendingColStart = -1;
1995 SCCOL pendingColEnd = -1;
2003 std::vector<ScAttrEntry> aAttrs;
2004 aAttrs.reserve(rColumn.
end() - rColumn.
begin());
2006 for (
const auto& rxStyle : rColumn)
2014 sal_uInt32 nForceScNumFmt = rXFIndex.
IsBoolCell() ?
2020 if (aAttrs.empty() || aAttrs.back().nEndRow != rDoc.
MaxRow())
2025 aAttrs.push_back(aEntry);
2028 aAttrs.shrink_to_fit();
2029 assert(aAttrs.size() > 0);
2031 aAttrParam.
mvData.swap(aAttrs);
2035 if( pendingColStart != -1 && pendingColEnd == nScCol - 1 && aAttrParam == aPendingAttrParam )
2039 if( pendingColStart != -1 )
2040 rDocImport.
setAttrEntries(nScTab, pendingColStart, pendingColEnd, std::move(aPendingAttrParam));
2041 pendingColStart = pendingColEnd = nScCol;
2042 aPendingAttrParam = std::move( aAttrParam );
2047 if( pendingColStart != -1 )
2048 rDocImport.
setAttrEntries(nScTab, pendingColStart, pendingColEnd, std::move(aPendingAttrParam));
2060 bool bMultiCol = rStart.
Col() != rEnd.
Col();
2061 bool bMultiRow = rStart.
Row() != rEnd.
Row();
2069 if( bMultiCol || bMultiRow )
2077 bTextWrap = pEditObj->GetParagraphCount() > 1;
constexpr auto convertTwipToMm100(N n)
void SetFont(const vcl::Font &rNewFont)
bool GetFontCharMap(FontCharMapRef &rxFontCharMap) const
void IncCol(SCCOL nDelta=1)
Accessor class to ScDocument.
void setAttrEntries(SCTAB nTab, SCCOL nColStart, SCCOL nColEnd, Attrs &&rAttrs)
Set an array of cell attributes to specified range of columns.
SC_DLLPUBLIC ScPatternAttr * GetDefPattern() const
SC_DLLPUBLIC SCCOL MaxCol() const
SC_DLLPUBLIC ScDocumentPool * GetPool()
SC_DLLPUBLIC void ApplyPatternAreaTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, const ScPatternAttr &rAttr)
SC_DLLPUBLIC SCROW MaxRow() const
SC_DLLPUBLIC void DoMerge(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, bool bDeleteCaptions=true)
SC_DLLPUBLIC void ApplyAttr(SCCOL nCol, SCROW nRow, SCTAB nTab, const SfxPoolItem &rAttr)
SC_DLLPUBLIC ScStyleSheetPool * GetStyleSheetPool() const
SC_DLLPUBLIC const EditTextObject * GetEditText(const ScAddress &rPos) const
SC_DLLPUBLIC CellType GetCellType(SCCOL nCol, SCROW nRow, SCTAB nTab) const
SC_DLLPUBLIC void ApplyStyleAreaTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, const ScStyleSheet &rStyle)
SC_DLLPUBLIC const SfxPoolItem * GetAttr(SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt16 nWhich) const
static SC_DLLPUBLIC void AddLanguage(SfxItemSet &rSet, const SvNumberFormatter &rFormatter)
Adds a language item to the item set, if the number format item contains a language that differs from...
const OUString * GetStyleName() const
void SetStyleSheet(ScStyleSheet *pNewStyle, bool bClearDirectFormat=true)
SfxItemSet & GetItemSet()
void push_back(const ScRange &rRange)
virtual SfxStyleSheetBase & Make(const OUString &, SfxStyleFamily eFam, SfxStyleSearchBits nMask=SfxStyleSearchBits::All) override
virtual SC_DLLPUBLIC SfxItemSet & GetItemSet() override
A wrapper for a UNO property set.
const T & Put(std::unique_ptr< T > xItem, sal_uInt16 nWhich=0)
SfxItemState GetItemState(sal_uInt16 nWhich, bool bSrchInParent=true, const SfxPoolItem **ppItem=nullptr) const
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
css::uno::Reference< css::frame::XModel3 > GetModel() const
virtual SfxStyleSheetBase * Find(const OUString &, SfxStyleFamily eFam, SfxStyleSearchBits n=SfxStyleSearchBits::All)
virtual SfxStyleSheetBase * Next()
virtual SfxStyleSheetBase * First()
const editeng::SvxBorderLine * GetLine(SvxBoxItemLine nLine) const
void SetLine(const editeng::SvxBorderLine *pNew, SvxBoxItemLine nLine)
void SetColor(const Color &rCol)
void SetLine(const editeng::SvxBorderLine *pNew)
Stores all default colors for a specific BIFF version.
Color GetDefColor(sal_uInt16 nXclIndex) const
Returns the default color for a (non-zero-based) Excel color or COL_AUTO on error.
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.
void SetManualRowHeight(SCROW nScRow)
XclImpFontBuffer(const XclImpFontBuffer &)=delete
delete copy constructor
XclImpFont maFont4
Application font (for column width).
void Initialize()
Clears all buffered data, used to set up for a new sheet.
void WriteDefaultCtrlFontProperties(ScfPropertySet &rPropSet) const
Writes default font properties for form controls to the passed property set.
const XclImpFont * GetFont(sal_uInt16 nFontIndex) const
Returns the object that stores all contents of a FONT record.
void UpdateAppFont(const XclFontData &rFontData, bool bHasCharSet)
Updates the application default font.
void ReadFont(XclImpStream &rStrm)
Reads a FONT record.
void FillToItemSet(SfxItemSet &rItemSet, XclFontItemType eType, sal_uInt16 nFontIdx, bool bSkipPoolDefs=false) const
Fills all font properties from a FONT record to the item set.
XclImpFont maCtrlFont
Built-in font with index 4.
XclFontData maAppFont
List of all FONT records in the Excel file.
std::vector< XclImpFont > maFontList
void ReadEfont(XclImpStream &rStrm)
Reads an EFONT record (BIFF2 font color).
void WriteFontProperties(ScfPropertySet &rPropSet, XclFontPropSetType eType, sal_uInt16 nFontIdx, const Color *pFontColor=nullptr) const
Writes all font properties to the passed property set.
Stores all data of an Excel font and provides import of FONT records.
void SetFontData(const XclFontData &rFontData, bool bHasCharSet)
Sets the passed font data and all used flags to 'used'.
XclImpFont(const XclImpRoot &rRoot)
const XclFontData & GetFontData() const
Returns read-only access to font data.
bool HasAsianChars() const
Returns true, if this font contains characters for Asian scripts (CJK).
bool mbHasCmplx
true = Font contains Asian script characters.
void ReadFont(XclImpStream &rStrm)
Reads a FONT record for all BIFF versions.
bool mbWeightUsed
true = Color used.
rtl_TextEncoding GetFontEncoding() const
Returns the text encoding for strings used with this font.
bool mbUnderlUsed
true = Escapement type used.
void GuessScriptType()
Tests whether the font contains CJK or CTL characters.
bool mbEscapemUsed
true = Weight used.
bool mbItalicUsed
true = Underline style used.
void ReadFontColor(XclImpStream &rStrm)
Reads and sets the font color.
bool mbHasCharSet
All font attributes.
bool mbHeightUsed
true = Font name, family, charset used.
void ReadFontData5(XclImpStream &rStrm)
Reads and sets height, flags, color, boldness, script, family and charset.
void ReadCFFontBlock(XclImpStream &rStrm)
Reads the font block from a CF (conditional format) record.
bool mbHasWstrn
true = Font contains own character set info.
void SetAllUsedFlags(bool bUsed)
Sets all font attributes to used or unused.
void ReadFontData2(XclImpStream &rStrm)
Reads and sets height and flags.
void ReadFontName8(XclImpStream &rStrm)
Reads and sets a Unicode string as font name.
void WriteFontProperties(ScfPropertySet &rPropSet, XclFontPropSetType eType, const Color *pFontColor=nullptr) const
Writes all font properties to the passed property set.
bool mbOutlineUsed
true = Strikeout used.
bool HasCharSet() const
Returns true, if the font character set is valid.
void ReadEfont(XclImpStream &rStrm)
Reads an EFONT record (BIFF2 font color).
bool mbHasAsian
true = Font contains Western script characters.
bool mbColorUsed
true = Font height used.
bool mbStrikeUsed
true = Italic used.
bool mbFontNameUsed
true = Font contains Complex script characters.
void FillToItemSet(SfxItemSet &rItemSet, XclFontItemType eType, bool bSkipPoolDefs=false) const
Fills all font properties to the item set.
bool mbShadowUsed
true = Outlined used.
void ReadFontName2(XclImpStream &rStrm)
Reads and sets a byte string as font name.
static void InsertUrl(XclImpRoot &rRoot, const XclRange &rXclRange, const OUString &rUrl)
Inserts the URL into a range of cells.
void Initialize()
Clears all buffered data, used to set up for a new sheet.
void FillScFmtToItemSet(SfxItemSet &rItemSet, sal_uInt32 nScNumFmt, bool bSkipPoolDefs=false) const
Fills a Calc number format to the passed item set.
sal_uInt16 mnNextXclIdx
Maps Excel format indexes to Calc formats.
sal_uInt16 ReadCFFormat(XclImpStream &rStrm, bool bIFmt)
Read NumFmt from conditional format record.
XclImpNumFmtBuffer(const XclImpRoot &rRoot)
void FillToItemSet(SfxItemSet &rItemSet, sal_uInt16 nXclNumFmt, bool bSkipPoolDefs=false) const
Fills an Excel number format to the passed item set.
void CreateScFormats()
Creates the number formats in the Calc document.
void ReadFormat(XclImpStream &rStrm)
Reads a FORMAT record.
sal_uInt32 GetScFormat(sal_uInt16 nXclNumFmt) const
Returns the format key with the passed Excel index or NUMBERFORMAT_ENTRY_NOT_FOUND on error.
XclImpIndexMap maIndexMap
Stores the default colors for the current BIFF version and the contents of a PALETTE record.
XclImpPalette(const XclImpRoot &rRoot)
void ReadPalette(XclImpStream &rStrm)
Reads a PALETTE record.
const XclImpRoot & mrRoot
Colors read from file.
void Initialize()
Clears all buffered data, used to set up for a new sheet.
Color GetColor(sal_uInt16 nXclIndex) const
Returns the color for a (non-zero-based) Excel palette entry.
::std::vector< Color > ColorVec
Access to global data from other classes.
XclImpXFBuffer & GetXFBuffer() const
Returns the cell formatting attributes buffer.
ScDocumentImport & GetDocImport()
XclImpFontBuffer & GetFontBuffer() const
Returns the font buffer.
XclImpPalette & GetPalette() const
Returns the color buffer.
const XclImpRoot & GetRoot() const
Returns this root instance - for code readability in derived classes.
XclImpNumFmtBuffer & GetNumFmtBuffer() const
Returns the number format buffer.
This class is used to import record oriented streams.
Contains all data of a cell style associated with an XF record.
XclImpStyle(const XclImpRoot &rRoot)
ScStyleSheet * mpStyleSheet
Final name used in the Calc document.
void ReadStyle(XclImpStream &rStrm)
Reads a STYLE record.
OUString maFinalName
True = style not visible in GUI.
sal_uInt16 mnXfId
Cell style name.
sal_uInt16 GetXfId() const
bool mbHidden
True = customized builtin style.
bool mbBuiltin
Level for builtin column/row styles.
sal_uInt8 mnLevel
Identifier for builtin styles.
ScStyleSheet * CreateStyleSheet()
Creates a cell style sheet and inserts it into the Calc document.
sal_uInt8 mnBuiltinId
Formatting for this cell style.
void CreateUserStyle(const OUString &rFinalName)
Creates the Calc style sheet, if this is a user-defined style.
bool mbCustom
True = builtin style.
Contains all XF records occurred in the file.
sal_uInt16 GetFontIndex(sal_uInt16 nXFIndex) const
Returns the index to the Excel font used in the specified XF record.
XclImpXFBuffer(const XclImpXFBuffer &)=delete
make noncopyable
XclImpStyleList maBuiltinStyles
List of contents of all XF record.
void ReadStyle(XclImpStream &rStrm)
Reads a STYLE record.
void Initialize()
Clears all buffered data, used to set up for a new sheet.
XclImpXF * GetXF(sal_uInt16 nXFIndex)
Returns the object that stores all contents of an XF record.
const XclImpFont * GetFont(sal_uInt16 nXFIndex) const
Returns the Excel font used in the specified XF record.
void CreateUserStyles()
Creates all user defined style sheets.
XclImpStyleMap maStylesByXf
List of user defined cell styles.
std::vector< std::unique_ptr< XclImpStyle > > XclImpStyleList
XclImpStyleList maUserStyles
List of built-in cell styles.
void ReadXF(XclImpStream &rStrm)
Reads an XF record.
ScStyleSheet * CreateStyleSheet(sal_uInt16 nXFIndex)
Creates a cell style sheet of the passed XF and inserts it into the Calc document.
std::vector< std::unique_ptr< XclImpXF > > maXFList
Represents an XF record index with additional information.
sal_uInt16 GetXFIndex() const
void SetBoolXF(const ScAddress &rScPos, sal_uInt16 nXFIndex)
Inserts a new XF index for boolean cells.
XclImpXFRangeBuffer(const XclImpXFRangeBuffer &)=delete
make noncopyable
void SetColumnDefXF(SCCOL nScCol, sal_uInt16 nXFIndex)
Inserts a new XF index for all cells in a column.
virtual ~XclImpXFRangeBuffer() override
void SetHyperlink(const XclRange &rXclRange, const OUString &rUrl)
Inserts a range of hyperlink cells.
std::vector< std::pair< XclRange, OUString > > maHyperlinks
Array of column XF index buffers.
void SetBlankXF(const ScAddress &rScPos, sal_uInt16 nXFIndex)
Inserts a new XF index for blank cells.
void Finalize()
Applies styles and cell merging to the current sheet in the document.
void SetXF(const ScAddress &rScPos, sal_uInt16 nXFIndex)
Inserts a new XF index.
XclImpXFInsertMode
Insertion mode of an XF index.
@ xlXFModeBlank
Cell with a single Boolean value.
@ xlXFModeBoolCell
Filled cell.
void SetRowDefXF(SCROW nScRow, sal_uInt16 nXFIndex)
Inserts a new XF index for all cells in a row.
ScRangeList maMergeList
Maps URLs to hyperlink cells.
std::vector< std::shared_ptr< XclImpXFRangeColumn > > maColumns
void Initialize()
Clears all buffered data, used to set up for a new sheet.
void SetMerge(SCCOL nScCol1, SCROW nScRow1, SCCOL nScCol2, SCROW nScRow2)
Inserts a complete merged cell range.
void SetBorderLine(const ScRange &rRange, SCTAB nScTab, SvxBoxItemLine nLine)
Copies border of the last cell of the range to the first cell to keep it visible when the range is me...
Contains the XF indexes for every used cell in a column.
IndexList::iterator end()
void SetXF(SCROW nScRow, const XclImpXFIndex &rXFIndex)
Inserts a new (encoded) XF index (first try to expand the last range).
void Insert(XclImpXFRange *pXFRange, sal_uLong nIndex)
Insert a range into the list at the specified index.
void Find(XclImpXFRange *&rpPrevRange, XclImpXFRange *&rpNextRange, sal_uLong &rnNextIndex, SCROW nScRow)
Finds the previous and next row range from row position nScRow.
void TryConcatPrev(sal_uLong nIndex)
Tries to concatenate a range with its predecessor.
void SetDefaultXF(const XclImpXFIndex &rXFIndex, const XclImpRoot &rRoot)
Inserts a single row range into the list.
IndexList::iterator begin()
Contains an (encoded) XF index for a range of rows in a single column.
bool Contains(SCROW nScRow) const
Returns true, if nScRow is contained in own row range.
bool Expand(SCROW nScRow, const XclImpXFIndex &rXFIndex)
Returns true, if the range has been expanded.
XclImpXFIndex maXFIndex
The last row of an equal-formatted range.
SCROW mnScRow2
The first row of an equal-formatted range.
Contains all data of a XF record and a Calc item set.
const ScPatternAttr & CreatePattern(bool bSkipPoolDefs=false)
Creates a Calc item set containing an item set with all cell properties.
XclImpCellBorder maBorder
All alignment attributes.
XclImpCellProt maProtection
Calc cell style sheet.
sal_uInt16 mnXclFont
Index to number format.
ScStyleSheet * mpStyleSheet
Calc item set.
virtual ~XclImpXF() override
XclImpCellArea maArea
Border line style.
ScPatternAttrPtr mpPattern
void ReadXF8(XclImpStream &rStrm)
void ReadXF3(XclImpStream &rStrm)
void SetUsedFlags(sal_uInt8 nUsedFlags)
Sets all "attribute used" flags according to the passed mask.
sal_uInt8 GetHorAlign() const
void ReadXF2(XclImpStream &rStrm)
sal_uInt16 GetFontIndex() const
void ReadXF(XclImpStream &rStrm)
Reads an XF record.
void ApplyPatternToAttrVector(::std::vector< ScAttrEntry > &rAttrs, SCROW nRow1, SCROW nRow2, sal_uInt32 nForceScNumFmt)
void ReadXF5(XclImpStream &rStrm)
XclImpCellAlign maAlignment
Cell protection flags.
XclImpXF(const XclImpXF &)=delete
make noncopyable
void ReadXF4(XclImpStream &rStrm)
void ApplyPattern(SCCOL nScCol1, SCROW nScRow1, SCCOL nScCol2, SCROW nScRow2, SCTAB nScTab)
Inserts all formatting attributes to the specified area in the Calc document.
sal_uInt16 mnXclNumFmt
Background area style.
static void ApplyPatternForBiff2CellFormat(const XclImpRoot &rRoot, const ScAddress &rScPos, sal_uInt8 nFlags1, sal_uInt8 nFlags2, sal_uInt8 nFlags3)
Converts formatting information from BIFF2 cell record data directly.
void InsertFormat(sal_uInt16 nXclNumFmt, const OUString &rFormat)
Inserts a new number format for the specified Excel format index.
void InitializeImport()
Clears all buffered data, used to set up for a new sheet.
sal_uInt32 GetStdScNumFmt() const
Returns the core index of the current standard number format.
const XclNumFmtMap & GetFormatMap() const
Returns the current number format map.
SfxObjectShell * GetDocShell() const
Returns the object shell of the Calc document.
rtl_TextEncoding GetTextEncoding() const
Returns the text encoding to import/export byte strings.
OutputDevice * GetPrinter() const
Returns pointer to the printer of the Calc document.
XclTracer & GetTracer() const
Returns the filter tracer.
SvNumberFormatter & GetFormatter() const
Returns the number formatter of the Calc document.
SCTAB GetCurrScTab() const
Returns the current Calc sheet index.
void SetCharWidth(const XclFontData &rFontData)
Sets the width of the '0' - '9' digit character as well as the ' ' space char (using the default font...
ScStyleSheetPool & GetStyleSheetPool() const
Returns the style sheet pool of the Calc document.
XclBiff GetBiff() const
Returns the current BIFF version of the importer/exporter.
RootData & GetOldRoot() const
Returns old RootData struct.
ScDocument & GetDoc() const
Returns reference to the destination document (import) or source document (export).
XclFontPropSetHelper & GetFontPropSetHelper() const
Returns the property set helper for fonts.
void TraceFillPattern(bool bFillPattern)
void TraceDates(sal_uInt16 nNumFmt)
void TraceBorderLineStyle(bool bBorderLineStyle)
Contains base members for XF record import/export.
bool mbBorderUsed
true = alignment used.
bool IsCellXF() const
Returns true, if this is a hard cell format.
bool mbAreaUsed
true = border data used.
bool mbProtUsed
true = cell XF, false = style XF.
bool HasUsedFlags() const
Returns true, if any "attribute used" flags are ste in this XF.
bool mbFmtUsed
true = font index used.
bool mbAlignUsed
true = number format used.
bool mbCellXF
Index to parent style XF.
void SetAllUsedFlags(bool bUsed)
Sets all "attribute used" flags to the passed state.
bool mbFontUsed
true = cell protection used.
void SetWidth(tools::Long nWidth)
void SetColor(const Color &rColor)
void SetBorderLineStyle(SvxBorderLineStyle nNew)
void setColor(Color const &rColor)
Color const & getFinalColor() const
constexpr ::Color COL_TRANSPARENT(ColorTransparency, 0xFF, 0xFF, 0xFF, 0xFF)
constexpr TypedWhichId< SvxContourItem > EE_CHAR_OUTLINE(EE_CHAR_START+8)
constexpr TypedWhichId< SvxFontItem > EE_CHAR_FONTINFO_CJK(EE_CHAR_START+17)
constexpr TypedWhichId< SvxUnderlineItem > EE_CHAR_UNDERLINE(EE_CHAR_START+5)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT(EE_CHAR_START+2)
constexpr TypedWhichId< SvxShadowedItem > EE_CHAR_SHADOW(EE_CHAR_START+9)
constexpr TypedWhichId< SvxWeightItem > EE_CHAR_WEIGHT(EE_CHAR_START+4)
constexpr TypedWhichId< SvxColorItem > EE_CHAR_COLOR(EE_CHAR_START+0)
constexpr TypedWhichId< SvxWeightItem > EE_CHAR_WEIGHT_CTL(EE_CHAR_START+22)
constexpr TypedWhichId< SvxCrossedOutItem > EE_CHAR_STRIKEOUT(EE_CHAR_START+6)
constexpr TypedWhichId< SvxPostureItem > EE_CHAR_ITALIC(EE_CHAR_START+7)
constexpr TypedWhichId< SvxEscapementItem > EE_CHAR_ESCAPEMENT(EE_CHAR_START+10)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT_CTL(EE_CHAR_START+20)
constexpr TypedWhichId< SvxWeightItem > EE_CHAR_WEIGHT_CJK(EE_CHAR_START+21)
constexpr TypedWhichId< SvxPostureItem > EE_CHAR_ITALIC_CJK(EE_CHAR_START+23)
constexpr TypedWhichId< SvxFontItem > EE_CHAR_FONTINFO_CTL(EE_CHAR_START+18)
constexpr TypedWhichId< SvxPostureItem > EE_CHAR_ITALIC_CTL(EE_CHAR_START+24)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT_CJK(EE_CHAR_START+19)
constexpr TypedWhichId< SvxFontItem > EE_CHAR_FONTINFO(EE_CHAR_START+1)
#define LANGUAGE_ENGLISH_US
#define SAL_WARN(area, stream)
#define SAL_N_ELEMENTS(arr)
tools::Long const nBorder
int compareToIgnoreAsciiCase(std::u16string_view s1, std::u16string_view s2)
css::uno::Reference< css::linguistic2::XProofreadingIterator > get(css::uno::Reference< css::uno::XComponentContext > const &context)
vcl::Font GetFont(vcl::Font const &rFont, DrawModeFlags nDrawMode, StyleSettings const &rStyleSettings)
OUString ScResId(TranslateId aId)
constexpr TypedWhichId< SvxFontHeightItem > ATTR_FONT_HEIGHT(101)
constexpr TypedWhichId< SfxBoolItem > ATTR_VERTICAL_ASIAN(137)
constexpr TypedWhichId< SvxFontItem > ATTR_CJK_FONT(111)
constexpr TypedWhichId< SvxPostureItem > ATTR_CTL_FONT_POSTURE(119)
constexpr TypedWhichId< SvxFontItem > ATTR_CTL_FONT(116)
constexpr TypedWhichId< SvxFontHeightItem > ATTR_CJK_FONT_HEIGHT(112)
constexpr TypedWhichId< SvxPostureItem > ATTR_FONT_POSTURE(103)
constexpr TypedWhichId< SvxWeightItem > ATTR_FONT_WEIGHT(102)
constexpr TypedWhichId< SvxColorItem > ATTR_FONT_COLOR(109)
constexpr TypedWhichId< SvxWeightItem > ATTR_CJK_FONT_WEIGHT(113)
constexpr TypedWhichId< SvxLineItem > ATTR_BORDER_TLBR(141)
constexpr TypedWhichId< SvxShadowedItem > ATTR_FONT_SHADOWED(108)
constexpr TypedWhichId< SvxContourItem > ATTR_FONT_CONTOUR(107)
constexpr TypedWhichId< SvxBrushItem > ATTR_BACKGROUND(148)
constexpr TypedWhichId< SvxJustifyMethodItem > ATTR_VER_JUSTIFY_METHOD(133)
constexpr TypedWhichId< SvxHorJustifyItem > ATTR_HOR_JUSTIFY(129)
constexpr TypedWhichId< SvxRotateModeItem > ATTR_ROTATE_MODE(136)
constexpr TypedWhichId< SvxBoxItem > ATTR_BORDER(150)
constexpr TypedWhichId< SvxJustifyMethodItem > ATTR_HOR_JUSTIFY_METHOD(130)
constexpr TypedWhichId< SfxUInt32Item > ATTR_VALUE_FORMAT(146)
constexpr TypedWhichId< SvxFrameDirectionItem > ATTR_WRITINGDIR(138)
constexpr TypedWhichId< SvxCrossedOutItem > ATTR_FONT_CROSSEDOUT(106)
constexpr TypedWhichId< SvxMarginItem > ATTR_MARGIN(143)
constexpr TypedWhichId< SvxLineItem > ATTR_BORDER_BLTR(142)
constexpr TypedWhichId< SvxVerJustifyItem > ATTR_VER_JUSTIFY(132)
constexpr TypedWhichId< SvxFontItem > ATTR_FONT(100)
constexpr TypedWhichId< SvxWeightItem > ATTR_CTL_FONT_WEIGHT(118)
constexpr TypedWhichId< ScLineBreakCell > ATTR_LINEBREAK(139)
constexpr TypedWhichId< SvxPostureItem > ATTR_CJK_FONT_POSTURE(114)
constexpr TypedWhichId< SvxFontHeightItem > ATTR_CTL_FONT_HEIGHT(117)
constexpr TypedWhichId< SvxUnderlineItem > ATTR_FONT_UNDERLINE(104)
XclImpColRowSettings * pColRowBuff
const ScPatternAttr * pPattern
std::vector< ScAttrEntry > mvData
sal_uInt8 mnTextDir
Text orientation.
SvxCellHorJustify GetScHorAlign() const
Returns the Calc horizontal alignment.
sal_uInt8 mnOrient
Vertical alignment.
SvxCellJustifyMethod GetScHorJustifyMethod() const
Returns horizontal justification method as Calc's attribute.
sal_uInt8 mnVerAlign
Horizontal alignment.
sal_uInt8 mnIndent
Text rotation angle.
SvxCellVerJustify GetScVerAlign() const
Returns the Calc vertical alignment.
SvxCellJustifyMethod GetScVerJustifyMethod() const
Returns vertical justification method as Calc's attribute.
sal_uInt8 mnRotation
CTL text direction.
SvxFrameDirection GetScFrameDir() const
Returns the Calc frame direction.
bool mbLineBreak
Indentation.
bool mbShrink
true = Multi-line text.
sal_uInt16 mnBackColor
Palette index to foreground color.
sal_uInt8 mnPattern
Palette index to background color.
sal_uInt8 mnRightLine
Style of left line.
sal_uInt8 mnDiagLine
Style of bottom line.
sal_uInt16 mnDiagColor
Palette index for bottom line.
bool mbDiagTLtoBR
Style of diagonal line(s).
sal_uInt8 mnTopLine
Style of right line.
sal_uInt8 mnLeftLine
Palette index for diagonal line(s).
sal_uInt16 mnTopColor
Palette index for right line.
sal_uInt16 mnRightColor
Palette index for left line.
sal_uInt16 mnBottomColor
Palette index for top line.
bool mbDiagBLtoTR
true = Top-left to bottom-right on.
sal_uInt8 mnBottomLine
Style of top line.
bool mbHidden
true = Locked against editing.
This struct helps reading and writing Excel fonts.
OUString maStyle
Font name.
sal_uInt8 mnCharSet
Windows font family.
sal_uInt16 mnHeight
String with styles (bold, italic).
bool mbOutline
true = Struck out.
sal_uInt16 mnWeight
Font height in twips (1/20 of a point).
FontWeight GetScWeight() const
Returns the Calc font weight.
void SetScPosture(FontItalic eScPosture)
Sets the Calc font posture.
FontFamily GetScFamily(rtl_TextEncoding eDefTextEnc) const
Returns the Calc font family.
FontStrikeout GetScStrikeout() const
Returns the Calc strike-out style.
bool mbItalic
Underline style.
sal_uInt8 mnUnderline
Windows character set.
FontLineStyle GetScUnderline() const
Returns the Calc font underline style.
bool mbStrikeout
true = Italic.
FontItalic GetScPosture() const
Returns the Calc font posture.
void SetScWeight(FontWeight eScWeight)
Sets the Calc font weight.
sal_uInt8 mnFamily
Escapement type.
sal_uInt16 mnEscapem
Boldness: 400=normal, 700=bold.
bool mbShadow
true = Outlined.
rtl_TextEncoding GetFontEncoding() const
Returns the font text encoding.
model::ComplexColor maComplexColor
true = Shadowed.
SvxEscapement GetScEscapement() const
Returns the Calc escapement style.
Extends the XclCellAlign struct for import.
void FillFromCF(sal_uInt16 nAlign, sal_uInt16 nMiscAttrib)
Fills this struct with CF record data.
void FillFromXF8(sal_uInt16 nAlign, sal_uInt16 nMiscAttrib)
Fills this struct with BIFF8 XF record data.
void FillToItemSet(SfxItemSet &rItemSet, const XclImpFont *pFont, bool bSkipPoolDefs=false) const
Inserts items representing this alignment style into the item set.
void FillFromXF4(sal_uInt16 nAlign)
Fills this struct with BIFF4 XF record data.
void FillFromXF3(sal_uInt16 nAlign)
Fills this struct with BIFF3 XF record data.
void FillFromXF2(sal_uInt8 nFlags)
Fills this struct with BIFF2 XF record data.
void FillFromXF5(sal_uInt16 nAlign)
Fills this struct with BIFF5/BIFF7 XF record data.
bool mbPattUsed
true = Background color used.
void FillFromXF5(sal_uInt32 nArea)
Fills this struct with BIFF5/BIFF7 XF record data.
bool mbBackUsed
true = Foreground color used.
void FillFromXF2(sal_uInt8 nFlags)
Fills this struct with BIFF2 XF record data.
void FillFromXF3(sal_uInt16 nArea)
Fills this struct with BIFF3/BIFF4 XF record data.
void FillFromXF8(sal_uInt32 nBorder2, sal_uInt16 nArea)
Fills this struct with BIFF8 XF record data.
void FillFromCF8(sal_uInt16 nPattern, sal_uInt16 nColor, sal_uInt32 nFlags)
Fills this struct with BIFF8 CF (conditional format) record data.
void SetUsedFlags(bool bUsed)
Sets colors and pattern state to used or unused.
XclImpCellArea()
true = Pattern used.
void FillToItemSet(SfxItemSet &rItemSet, const XclImpPalette &rPalette, bool bSkipPoolDefs=false) const
Inserts a brush item representing this area style into the item set.
Extends the XclCellBorder struct for import.
void FillFromXF3(sal_uInt32 nBorder)
Fills this struct with BIFF3/BIFF4 XF record data.
XclImpCellBorder()
true = Diagonal line style used.
void FillFromXF5(sal_uInt32 nBorder, sal_uInt32 nArea)
Fills this struct with BIFF5/BIFF7 XF record data.
void FillToItemSet(SfxItemSet &rItemSet, const XclImpPalette &rPalette, bool bSkipPoolDefs=false) const
Inserts a box item representing this border style into the item set.
void FillFromXF2(sal_uInt8 nFlags)
Fills this struct with BIFF2 XF record data.
void FillFromCF8(sal_uInt16 nLineStyle, sal_uInt32 nLineColor, sal_uInt32 nFlags)
Fills this struct with BIFF8 CF (conditional format) record data.
void FillFromXF8(sal_uInt32 nBorder1, sal_uInt32 nBorder2)
Fills this struct with BIFF8 XF record data.
bool HasAnyOuterBorder() const
Returns true, if any of the outer border lines is visible.
void SetUsedFlags(bool bOuterUsed, bool bDiagUsed)
Sets outer line states and diagonal line states to used or unused.
bool mbDiagUsed
true = Bottom line style used.
bool mbRightUsed
true = Left line style used.
bool mbBottomUsed
true = Top line style used.
bool mbTopUsed
true = Right line style used.
void FillFromXF3(sal_uInt16 nProt)
Fills this struct with BIFF3-BIFF8 XF record data.
void FillFromXF2(sal_uInt8 nNumFmt)
Fills this struct with BIFF2 XF record data.
void FillToItemSet(SfxItemSet &rItemSet, bool bSkipPoolDefs=false) const
Inserts items representing this protection style into the item set.
A 2D cell range address struct with Excel column and row indexes.
::cppu::WeakImplHelper< container::XIndexAccess > XIndexAccess_BASE
::std::vector< Color > ColorVec
::cppu::WeakImplHelper< container::XIndexAccess > XIndexAccess_BASE
#define PUTITEM(item, sc_which, ee_which)
const sal_uInt8 EXC_ORIENT_NONE
const sal_uInt16 EXC_BORDER_THICK
const sal_uInt16 EXC_BORDER_MEDIUM
const sal_uInt16 EXC_BORDER_THIN
@ EXC_BIFF8
MS Excel 5.0, MS Excel 7.0 (95)
const sal_uInt8 EXC_ROT_STACKED
Text rotation: 90 deg clockwise.
const sal_uInt16 EXC_BORDER_HAIR
const sal_uInt32 EXC_CF_AREA_PATTERN
Any border line modified?
const sal_uInt32 EXC_CF_FONT_STYLE
NumberFormat String or Id?
const sal_uInt32 EXC_CF_AREA_BGCOLOR
Foreground color modified?
const sal_uInt32 EXC_CF_BORDER_RIGHT
Left border line modified?
const sal_uInt32 EXC_CF_BORDER_TOP
Right border line modified?
const sal_uInt32 EXC_CF_AREA_FGCOLOR
Pattern modified?
const sal_uInt32 EXC_CF_FONT_STRIKEOUT
Font posture or weight modified?
const sal_uInt32 EXC_CF_BORDER_LEFT
const sal_uInt32 EXC_CF_BORDER_BOTTOM
Top border line modified?
const sal_uInt32 EXC_CF_FONT_UNDERL
Default flags.
const sal_uInt16 EXC_FONTWGHT_NORMAL
const sal_uInt16 EXC_COLOR_WINDOWBACK
System window text color (>=BIFF5).
const sal_uInt16 EXC_FONT_NOTFOUND
Application font index.
const sal_uInt8 EXC_XF2_HIDDEN
const sal_uInt8 EXC_LINE_HAIR
const sal_uInt16 EXC_FONTATTR_SHADOW
const sal_uInt8 EXC_XF2_TOPLINE
const sal_uInt8 EXC_XF_DIFF_BORDER
XclFontItemType
Enumerates different types of Which-IDs for font items.
@ HeaderFooter
Use edit engine Which-IDs (EE_CHAR_*).
const sal_uInt16 EXC_STYLE_XFMASK
const sal_uInt16 EXC_FONTATTR_UNDERLINE
const sal_uInt16 EXC_COLOR_USEROFFSET
const sal_uInt8 EXC_XF_HOR_CENTER_AS
const sal_uInt8 EXC_XF2_RIGHTLINE
XclFontPropSetType
Enumerates different types for objects with font settings (using different property names).
@ EXC_FONTPROPSET_CONTROL
All text objects in charts.
const sal_uInt8 EXC_STYLEEXT_CUSTOM
const sal_uInt8 EXC_XF_DIFF_FONT
const sal_uInt16 EXC_COLOR_BIFF2_WHITE
const sal_uInt8 EXC_LINE_THIN
const sal_uInt8 EXC_FONTUNDERL_SINGLE
const sal_uInt16 EXC_FONTATTR_STRIKEOUT
const sal_uInt8 EXC_LINE_NONE
const sal_uInt8 EXC_STYLEEXT_HIDDEN
const sal_uInt16 EXC_COLOR_WINDOWTEXT
System window background color (BIFF3-BIFF4).
const sal_uInt16 EXC_XF_NOTFOUND
Excel index to default cell XF.
const sal_uInt8 EXC_XF_DIFF_VALFMT
Shrink to fit into cell.
const sal_uInt8 EXC_XF2_BOTTOMLINE
const sal_uInt8 EXC_STYLE_NOLEVEL
Number of outline level styles.
const sal_uInt16 EXC_FONTATTR_ITALIC
const sal_uInt16 EXC_COLOR_BIFF2_BLACK
const sal_uInt8 EXC_XF2_LOCKED
const sal_uInt16 EXC_XF_STYLE
const sal_uInt8 EXC_XF2_LEFTLINE
const sal_uInt16 EXC_XF_LOCKED
const sal_uInt8 EXC_XF_VER_JUSTIFY
const sal_uInt16 EXC_STYLE_BUILTIN
const sal_uInt16 EXC_ID_STYLEEXT
Default value for unused level.
const sal_uInt8 EXC_PATT_NONE
const sal_uInt8 EXC_FONTUNDERL_NONE
const sal_uInt16 EXC_FONTATTR_BOLD
const sal_uInt16 EXC_XF_HIDDEN
const sal_uInt8 EXC_XF_HOR_FILL
const sal_uInt8 EXC_PATT_SOLID
const sal_uInt8 EXC_XF2_BACKGROUND
const sal_uInt16 EXC_XF_LINEBREAK
Styles don't have a parent.
const sal_uInt32 EXC_XF_DIAGONAL_BL_TO_TR
Top-left to bottom-right.
const sal_uInt8 EXC_PATT_12_5_PERC
const sal_uInt8 EXC_XF_VER_DISTRIB
const sal_uInt8 EXC_STYLEEXT_BUILTIN
const sal_uInt16 EXC_FONTWGHT_BOLD
const sal_uInt32 EXC_XF_DIAGONAL_TL_TO_BR
const sal_uInt8 EXC_XF_DIFF_ALIGN
const sal_uInt8 EXC_XF_DIFF_AREA
const sal_uInt16 EXC_FONTATTR_OUTLINE
const sal_uInt8 EXC_STYLE_NORMAL
const sal_uInt8 EXC_XF2_VALFMT_MASK
const sal_uInt8 EXC_STYLE_USERDEF
"Followed_Hyperlink" style.
const sal_uInt16 EXC_XF8_SHRINK
const sal_uInt8 EXC_XF_DIFF_PROT
constexpr sal_uInt32 NUMBERFORMAT_ENTRY_NOT_FOUND