Commit 4c49a9b1 authored by Elen.Subbotina's avatar Elen.Subbotina Committed by Alexander Trofimov

XlsFormat - небольшая оптимизация (рефакторинг)

git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@67850 954022d7-b5bf-4e40-9824-e11837661b57
parent 3cf73152
......@@ -24,9 +24,9 @@ public:
static const ElementType type = typeArea;
BIFF_BOOL fStacked;
BIFF_BOOL f100;
BIFF_BOOL fHasShadow;
bool fStacked;
bool f100;
bool fHasShadow;
};
} // namespace XLS
......
......@@ -29,8 +29,9 @@ public:
LongRGB rgbBack;
BIFF_WORD fls;
BIFF_BOOL fAuto;
BIFF_BOOL fInvertNeg;
bool fAuto;
bool fInvertNeg;
IcvChart icvFore;
IcvChart icvBack;
......
......@@ -24,10 +24,9 @@ public:
static const ElementType type = typeArray;
Ref ref_;
BIFF_BOOL fAlwaysCalc;
ArrayParsedFormula formula;
Ref ref_;
ArrayParsedFormula formula;
bool fAlwaysCalc;
};
typedef boost::shared_ptr<Array> ArrayPtr;
......
......@@ -24,12 +24,12 @@ public:
int serialize(std::wostream & _stream);
BIFF_BOOL fShowValue;
BIFF_BOOL fShowPercent;
BIFF_BOOL fShowLabelAndPerc;
BIFF_BOOL fShowLabel;
BIFF_BOOL fShowBubbleSizes;
BIFF_BOOL fShowSeriesName;
bool fShowValue;
bool fShowPercent;
bool fShowLabelAndPerc;
bool fShowLabel;
bool fShowBubbleSizes;
bool fShowSeriesName;
//-----------------------------
......
......@@ -58,6 +58,7 @@ void BOF::readFields(CFRecord& record)
{
unsigned int flags;
record >> flags;
fWin = GETBIT(flags, 0);
fRisc = GETBIT(flags, 1);
fBeta = GETBIT(flags, 2);
......@@ -68,6 +69,7 @@ void BOF::readFields(CFRecord& record)
fOOM = GETBIT(flags, 9);
fGlJmp = GETBIT(flags, 10);
fFontLimit = GETBIT(flags, 13);
verXLHigh = static_cast<unsigned char>(GETBITS(flags, 14, 17));
record >> verLowestBiff;
......
......@@ -42,16 +42,18 @@ public:
BIFF_WORD dt;
BIFF_WORD rupBuild;
BIFF_WORD rupYear;
BIFF_BOOL fWin;
BIFF_BOOL fRisc;
BIFF_BOOL fBeta;
BIFF_BOOL fWinAny;
BIFF_BOOL fMacAny;
BIFF_BOOL fBetaAny;
BIFF_BOOL fRiscAny;
BIFF_BOOL fOOM;
BIFF_BOOL fGlJmp;
BIFF_BOOL fFontLimit;
bool fWin;
bool fRisc;
bool fBeta;
bool fWinAny;
bool fMacAny;
bool fBetaAny;
bool fRiscAny;
bool fOOM;
bool fGlJmp;
bool fFontLimit;
BIFF_WORD verXLHigh;
BIFF_BYTE verLowestBiff;
BIFF_BYTE verLastXLSaved;
......
......@@ -28,7 +28,7 @@ public:
//-----------------------------
BIFF_BYTE id;
BIFF_BYTE rt;
BIFF_BOOL fUnlinkedIfmt;
bool fUnlinkedIfmt;
IFmt ifmt;
ChartParsedFormula formula; //
......
......@@ -27,10 +27,10 @@ public:
BIFF_SHORT pcOverlap;
BIFF_WORD pcGap;
BIFF_BOOL fTranspose;
BIFF_BOOL fStacked;
BIFF_BOOL f100;
BIFF_BOOL fHasShadow;
bool fTranspose;
bool fStacked;
bool f100;
bool fHasShadow;
//------------------------------------
BaseObjectPtr m_chart3D;
};
......
......@@ -57,10 +57,12 @@ void BookBool::readFields(CFRecord& record)
{
unsigned short flags;
record >> flags;
fNoSaveSup = GETBIT(flags, 0);
fHasEnvelope = GETBIT(flags, 2);
fEnvelopeVisible = GETBIT(flags, 3);
fEnvelopeInitDone = GETBIT(flags, 4);
fNoSaveSup = GETBIT(flags, 0);
fHasEnvelope = GETBIT(flags, 2);
fEnvelopeVisible = GETBIT(flags, 3);
fEnvelopeInitDone = GETBIT(flags, 4);
unsigned char grUpdateLinks_num = GETBITS(flags, 5, 6);
switch(grUpdateLinks_num)
{
......@@ -77,6 +79,7 @@ void BookBool::readFields(CFRecord& record)
throw;// EXCEPT::RT::WrongBiffRecord("Unsupported value of grUpdateLinks.", record.getTypeString());
}
fHideBorderUnselLists = GETBIT(flags, 8);
}
......
......@@ -23,13 +23,13 @@ public:
static const ElementType type = typeBookBool;
//-----------------------------
BIFF_BOOL fNoSaveSup;
BIFF_BOOL fHasEnvelope;
BIFF_BOOL fEnvelopeVisible;
BIFF_BOOL fEnvelopeInitDone;
BIFF_BSTR grUpdateLinks;
BIFF_BOOL fHideBorderUnselLists;
bool fNoSaveSup;
bool fHasEnvelope;
bool fEnvelopeVisible;
bool fEnvelopeInitDone;
bool fHideBorderUnselLists;
BIFF_BSTR grUpdateLinks;
};
} // namespace XLS
......
......@@ -26,15 +26,16 @@ public:
//-----------------------------
BIFF_DWORD cb;
BIFF_BOOL fDontAutoRecover;
BIFF_BOOL fHidePivotList;
BIFF_BOOL fFilterPrivacy;
BIFF_BOOL fEmbedFactoids;
bool fDontAutoRecover;
bool fHidePivotList;
bool fFilterPrivacy;
bool fEmbedFactoids;
BIFF_BYTE mdFactoidDisplay;
BIFF_BOOL fSavedDuringRecovery;
BIFF_BOOL fCreatedViaMinimalSave;
BIFF_BOOL fOpenedViaDataRecovery;
BIFF_BOOL fOpenedViaSafeLoad;
bool fSavedDuringRecovery;
bool fCreatedViaMinimalSave;
bool fOpenedViaDataRecovery;
bool fOpenedViaSafeLoad;
BookExt_Conditional11 grbit1;
BookExt_Conditional12 grbit2;
......
......@@ -33,7 +33,8 @@ public:
BIFF_SHORT pcPie2Size;
BIFF_SHORT pcGap;
BIFF_DOUBLE numSplitValue;
BIFF_BOOL fHasShadow;
bool fHasShadow;
BaseObjectPtr m_Custom;
......
......@@ -36,6 +36,7 @@ void CF12::readFields(CFRecord& record)
{
record >> frtRefHeader;
record >> ct >> cp;
unsigned short cce1;
unsigned short cce2;
record >> cce1 >> cce2;
......@@ -43,9 +44,11 @@ void CF12::readFields(CFRecord& record)
rgce1.load(record, cce1);
rgce2.load(record, cce2);
fmlaActive.load(record);
unsigned char flags;
record >> flags;
fStopIfTrue = GETBIT(flags, 1);
record >> ipriority >> icfTemplate;
unsigned char cbTemplateParm;
record >> cbTemplateParm;
......
......@@ -35,31 +35,12 @@ public:
CFParsedFormulaNoCCE rgce1;
CFParsedFormulaNoCCE rgce2;
CFParsedFormula fmlaActive;
BIFF_BOOL fStopIfTrue;
BIFF_WORD ipriority;
BIFF_WORD icfTemplate;
CFExTemplateParams rgbTemplateParms;
BiffStructurePtr rgbCT;
public:
//BO_ATTRIB_MARKUP_BEGIN
//BO_ATTRIB_MARKUP_COMPLEX(frtRefHeader)
//BO_ATTRIB_MARKUP_ATTRIB(ct)
//BO_ATTRIB_MARKUP_ATTRIB(cp)
//BO_ATTRIB_MARKUP_COMPLEX(dxf)
//BO_ATTRIB_MARKUP_COMPLEX(rgce1)
//BO_ATTRIB_MARKUP_COMPLEX(rgce2)
//BO_ATTRIB_MARKUP_COMPLEX(fmlaActive)
//BO_ATTRIB_MARKUP_ATTRIB(fStopIfTrue)
//BO_ATTRIB_MARKUP_ATTRIB(ipriority)
//BO_ATTRIB_MARKUP_ATTRIB(icfTemplate)
//rgbTemplateParms.toXML(proc.getParent(), static_cast<unsigned char>(icfTemplate));
//if(rgbCT)
//{
// //BO_ATTRIB_MARKUP_COMPLEX(*rgbCT)
//}
//BO_ATTRIB_MARKUP_END
bool fStopIfTrue;
};
typedef boost::shared_ptr<CF12> CF12Ptr;
......
......@@ -25,14 +25,7 @@ public:
//-----------------------------
BIFF_WORD wOffset;
BIFF_WORD at;
BIFF_BOOL cAutoCatLabelReal;
//BO_ATTRIB_MARKUP_BEGIN
//BO_ATTRIB_MARKUP_ATTRIB(wOffset)
//BO_ATTRIB_MARKUP_ATTRIB(at)
//BO_ATTRIB_MARKUP_ATTRIB(cAutoCatLabelReal)
//BO_ATTRIB_MARKUP_END
bool cAutoCatLabelReal;
};
} // namespace XLS
......
......@@ -27,9 +27,9 @@ public:
BIFF_SHORT catLabel;
BIFF_SHORT catMark;
BIFF_BOOL fBetween;
BIFF_BOOL fMaxCross;
BIFF_BOOL fReversed;
bool fBetween;
bool fMaxCross;
bool fReversed;
};
} // namespace XLS
......
......@@ -30,11 +30,11 @@ public:
BIFF_SHORT pcDepth;
BIFF_WORD pcGap;
BIFF_BOOL fPerspective;
BIFF_BOOL fCluster;
BIFF_BOOL f3DScaling;
BIFF_BOOL fNotPieChart;
BIFF_BOOL fWalls2D;
bool fPerspective;
bool fCluster;
bool f3DScaling;
bool fNotPieChart;
bool fWalls2D;
};
......
......@@ -24,7 +24,7 @@ public:
int serialize(std::wostream & _stream);
//-----------------------------
BIFF_BOOL fVaried;
bool fVaried;
BIFF_WORD icrt;
};
......
......@@ -28,12 +28,12 @@ public:
BIFF_WORD coldx;
IXFCell ixfe;
BIFF_BOOL fHidden;
BIFF_BOOL fUserSet;
BIFF_BOOL fBestFit;
BIFF_BOOL fPhonetic;
bool fHidden;
bool fUserSet;
bool fBestFit;
bool fPhonetic;
BIFF_BYTE iOutLevel;
BIFF_BOOL fCollapsed;
bool fCollapsed;
};
} // namespace XLS
......
......@@ -27,7 +27,7 @@ public:
//-----------------------------
BIFF_WORD ccf;
BIFF_BOOL fToughRecalc;
bool fToughRecalc;
BIFF_WORD nID;
SqRefU sqref;
BIFF_BSTR refBound;
......
......@@ -23,7 +23,7 @@ public:
static const ElementType type = typeDVal;
//-----------------------------
BIFF_BOOL fWnClosed;
bool fWnClosed;
BIFF_DWORD xLeft;
BIFF_DWORD yTop;
BIFF_LONG idObj;
......
......@@ -26,15 +26,9 @@ public:
//-----------------------------
FrtRefHeaderU frtRefHeaderU;
BIFF_BOOL fNewBorder;
XFProps xfprops;
public:
//BO_ATTRIB_MARKUP_BEGIN
//BO_ATTRIB_MARKUP_COMPLEX(frtRefHeaderU)
//BO_ATTRIB_MARKUP_ATTRIB(fNewBorder)
//BO_ATTRIB_MARKUP_COMPLEX(xfprops)
//BO_ATTRIB_MARKUP_END
bool fNewBorder;
};
} // namespace XLS
......
......@@ -35,6 +35,7 @@ void Dat::readFields(CFRecord& record)
{
unsigned short flags;
record >> flags;
fHasBordHorz = GETBIT(flags, 0);
fHasBordVert = GETBIT(flags, 1);
fHasBordOutline = GETBIT(flags, 2);
......
......@@ -23,18 +23,10 @@ public:
static const ElementType type = typeDat;
//-----------------------------
BIFF_BOOL fHasBordHorz;
BIFF_BOOL fHasBordVert;
BIFF_BOOL fHasBordOutline;
BIFF_BOOL fShowSeriesKey;
//BO_ATTRIB_MARKUP_BEGIN
//BO_ATTRIB_MARKUP_ATTRIB(fHasBordHorz)
//BO_ATTRIB_MARKUP_ATTRIB(fHasBordVert)
//BO_ATTRIB_MARKUP_ATTRIB(fHasBordOutline)
//BO_ATTRIB_MARKUP_ATTRIB(fShowSeriesKey)
//BO_ATTRIB_MARKUP_END
bool fHasBordHorz;
bool fHasBordVert;
bool fHasBordOutline;
bool fShowSeriesKey;
};
} // namespace XLS
......
......@@ -25,7 +25,8 @@ public:
BIFF_WORD xi;
BIFF_WORD yi;
BIFF_WORD iss;
BIFF_BOOL fUnknown;
bool fUnknown;
};
} // namespace XLS
......
......@@ -25,11 +25,11 @@ public:
int serialize(std::wostream & _stream);
BIFF_BOOL fSerName;
BIFF_BOOL fCatName;
BIFF_BOOL fValue;
BIFF_BOOL fPercent;
BIFF_BOOL fBubSizes;
bool fSerName;
bool fCatName;
bool fValue;
bool fPercent;
bool fBubSizes;
XLUnicodeStringMin2 rgchSep;
......
......@@ -45,10 +45,12 @@ void DefaultRowHeight::readFields(CFRecord& record)
unsigned short flags;
record >> flags;
fUnsynced = GETBIT(flags, 0);
fDyZero = GETBIT(flags, 1);
fExAsc = GETBIT(flags, 2);
fExDsc = GETBIT(flags, 3);
fUnsynced = GETBIT(flags, 0);
fDyZero = GETBIT(flags, 1);
fExAsc = GETBIT(flags, 2);
fExDsc = GETBIT(flags, 3);
if(!fDyZero)
{
record >> miyRw;
......
......@@ -23,10 +23,11 @@ public:
static const ElementType type = typeDefaultRowHeight;
//-----------------------------
BIFF_BOOL fUnsynced;
BIFF_BOOL fDyZero;
BIFF_BOOL fExAsc;
BIFF_BOOL fExDsc;
bool fUnsynced;
bool fDyZero;
bool fExAsc;
bool fExDsc;
BIFF_SHORT miyRw; // measured in twips (1/20 of of a printer's point)
BIFF_SHORT miyRwHidden;
......
......@@ -25,12 +25,12 @@ public:
//-----------------------------
BIFF_BYTE valType;
BIFF_BYTE errStyle;
BIFF_BOOL fStrLookup;
BIFF_BOOL fAllowBlank;
BIFF_BOOL fSuppressCombo;
bool fStrLookup;
bool fAllowBlank;
bool fSuppressCombo;
BIFF_BYTE mdImeMode;
BIFF_BOOL fShowInputMsg;
BIFF_BOOL fShowErrorMsg;
bool fShowInputMsg;
bool fShowErrorMsg;
BIFF_BYTE typOperator;
XLUnicodeString PromptTitle;
......
......@@ -28,13 +28,13 @@ public:
static const ElementType type = typeExternName;
//-----------------------------
BIFF_BOOL fBuiltIn;
BIFF_BOOL fWantAdvise;
BIFF_BOOL fWantPict;
BIFF_BOOL fOle;
BIFF_BOOL fOleLink;
bool fBuiltIn;
bool fWantAdvise;
bool fWantPict;
bool fOle;
bool fOleLink;
BIFF_WORD cf;
BIFF_BOOL fIcon;
bool fIcon;
BiffStructurePtr body;
//-----------------------------
......
......@@ -25,32 +25,11 @@ public:
static const ElementType type = typeFeatHdr;
//-----------------------------
BIFF_BOOL is_contained_in_Globals;
bool is_contained_in_Globals;
SharedFeatureType isf;
BIFF_DWORD cbHdrData;
EnhancedProtection protection;
OSHARED::PropertyBagStore prop;
public:
//BO_ATTRIB_MARKUP_BEGIN
//BO_ATTRIB_MARKUP_ATTRIB(isf)
//BO_ATTRIB_MARKUP_ATTRIB(cbHdrData)
//if(cbHdrData)
//{
// switch(isf)
// {
// case SharedFeatureType::ISFPROTECTION:
// //BO_ATTRIB_MARKUP_COMPLEX(protection)
// break;
// case SharedFeatureType::ISFFACTOID:
// if(is_contained_in_Globals)
// {
// //BO_ATTRIB_MARKUP_COMPLEX(prop)
// }
// break;
// }
//}
//BO_ATTRIB_MARKUP_END
};
} // namespace XLS
......
......@@ -45,12 +45,13 @@ void Font::readFields(CFRecord& record)
unsigned short flags;
record >> dyHeight >> flags;
fItalic = GETBIT(flags, 1);
fStrikeOut = GETBIT(flags, 3);
fOutline = GETBIT(flags, 4);
fShadow = GETBIT(flags, 5);
fCondense = GETBIT(flags, 6);
fExtend = GETBIT(flags, 7);
fItalic = GETBIT(flags, 1);
fStrikeOut = GETBIT(flags, 3);
fOutline = GETBIT(flags, 4);
fShadow = GETBIT(flags, 5);
fCondense = GETBIT(flags, 6);
fExtend = GETBIT(flags, 7);
record >> icv >> bls >> sss >> uls >> bFamily >> bCharSet;
record.skipNunBytes(1);
......@@ -94,7 +95,7 @@ int Font::serialize_rPr(std::wostream & stream, bool rtl, bool defRPr)
else
CP_XML_ATTR(L"b", false);
if ((fItalic.value()) && (fItalic))
if (fItalic)
{
CP_XML_ATTR(L"i", fItalic);
}
......@@ -312,15 +313,15 @@ int Font::serialize_properties(std::wostream & stream, bool rPr)
}
}
if ((fCondense.value()) && (*fCondense.value()))
if (fCondense)
{
CP_XML_NODE(L"condense")
{
CP_XML_ATTR(L"val", (int)(*fCondense.value()));
CP_XML_ATTR(L"val", 1);
}
}
if ((fExtend.value()) && (fExtend))
if (fExtend)
{
CP_XML_NODE(L"extend")
{
......@@ -336,7 +337,7 @@ int Font::serialize_properties(std::wostream & stream, bool rPr)
}
}
if ((fItalic.value()) && (fItalic))
if (fItalic)
{
CP_XML_NODE(L"i")
{
......@@ -362,7 +363,7 @@ int Font::serialize_properties(std::wostream & stream, bool rPr)
}
}
if ((fOutline.value()) && (fOutline))
if (fOutline)
{
CP_XML_NODE(L"outline")
{
......@@ -378,7 +379,7 @@ int Font::serialize_properties(std::wostream & stream, bool rPr)
// }
//}
if ((fShadow.value()) && (fShadow))
if (fShadow)
{
CP_XML_NODE(L"shadow")
{
......@@ -386,7 +387,7 @@ int Font::serialize_properties(std::wostream & stream, bool rPr)
}
}
if ((fStrikeOut.value()) && (fStrikeOut))
if (fStrikeOut)
{
CP_XML_NODE(L"strike")
{
......
......@@ -35,12 +35,12 @@ public:
//-----------------------------
BIFF_WORD dyHeight; // measured in twips (1/20 of of a printer's point)
BIFF_BOOL fItalic;
BIFF_BOOL fStrikeOut;
BIFF_BOOL fOutline;
BIFF_BOOL fShadow;
BIFF_BOOL fCondense;
BIFF_BOOL fExtend;
bool fItalic;
bool fStrikeOut;
bool fOutline;
bool fShadow;
bool fCondense;
bool fExtend;
BIFF_WORD icv;
BIFF_WORD bls;
......
......@@ -29,9 +29,9 @@ public:
//-----------------------------
Cell cell;
FormulaValue val;
BIFF_BOOL fAlwaysCalc;
bool fAlwaysCalc;
BackwardOnlyParam<bool> fFill;
BIFF_BOOL fShrFmla;
bool fShrFmla;
BackwardOnlyParam<bool> fClearErrors;
CellParsedFormula formula;
......
......@@ -24,8 +24,8 @@ public:
//-----------------------------
BIFF_WORD frt;
BIFF_BOOL fAutoSize;
BIFF_BOOL fAutoPosition;
bool fAutoSize;
bool fAutoPosition;
};
......
......@@ -23,16 +23,10 @@ public:
static const ElementType type = typeHFPicture;
//-----------------------------
BIFF_BOOL fIsDrawing;
BIFF_BOOL fIsDrawingGroup;
BIFF_BOOL fContinue;
bool fIsDrawing;
bool fIsDrawingGroup;
bool fContinue;
//OfficeArtDgContainer rgDrawing;
public:
//BO_ATTRIB_MARKUP_BEGIN
//BO_ATTRIB_MARKUP_ATTRIB(fIsDrawing)
//BO_ATTRIB_MARKUP_ATTRIB(fIsDrawingGroup)
//BO_ATTRIB_MARKUP_ATTRIB(fContinue)
//BO_ATTRIB_MARKUP_END
};
......
......@@ -25,10 +25,10 @@ public:
//-----------------------------
BIFF_BSTR guidSView;
BIFF_BOOL fHFDiffOddEven;
BIFF_BOOL fHFDiffFirst;
BIFF_BOOL fHFScaleWithDoc;
BIFF_BOOL fHFAlignMargins;
bool fHFDiffOddEven;
bool fHFDiffFirst;
bool fHFScaleWithDoc;
bool fHFAlignMargins;
BIFF_WORD cchHeaderEven;
BIFF_WORD cchFooterEven;
BIFF_WORD cchHeaderFirst;
......
......@@ -131,15 +131,17 @@ void Lbl::readFields(CFRecord& record)
{
unsigned short flags;
record >> flags >> chKey;
fHidden = GETBIT(flags, 0);
fFunc = GETBIT(flags, 1);
fOB = GETBIT(flags, 2);
fProc = GETBIT(flags, 3);
fCalcExp = GETBIT(flags, 4);
fBuiltin = GETBIT(flags, 5);
fGrp = GETBITS(flags, 6, 11);
fPublished = GETBIT(flags, 13);
fWorkbookParam = GETBIT(flags, 14);
fHidden = GETBIT(flags, 0);
fFunc = GETBIT(flags, 1);
fOB = GETBIT(flags, 2);
fProc = GETBIT(flags, 3);
fCalcExp = GETBIT(flags, 4);
fBuiltin = GETBIT(flags, 5);
fGrp = GETBITS(flags, 6, 11);
fPublished = GETBIT(flags, 13);
fWorkbookParam = GETBIT(flags, 14);
unsigned char cch;
unsigned short cce;
record >> cch >> cce;
......
......@@ -28,15 +28,15 @@ public:
const XLUnicodeStringNoCch getName() const;
//-----------------------------
BIFF_BOOL fHidden;
BIFF_BOOL fFunc;
BIFF_BOOL fOB;
BIFF_BOOL fProc;
BIFF_BOOL fCalcExp;
BIFF_BOOL fBuiltin;
bool fHidden;
bool fFunc;
bool fOB;
bool fProc;
bool fCalcExp;
bool fBuiltin;
BIFF_BYTE fGrp;
BIFF_BOOL fPublished;
BIFF_BOOL fWorkbookParam;
bool fPublished;
bool fWorkbookParam;
BIFF_BYTE chKey;
BIFF_WORD itab;
XLUnicodeStringNoCch Name_bin;
......
......@@ -31,11 +31,11 @@ public:
BIFF_DWORD dy;
BIFF_BYTE wSpace;
BIFF_BOOL fAutoPosition;
BIFF_BOOL fAutoPosX;
BIFF_BOOL fAutoPosY;
BIFF_BOOL fVert;
BIFF_BOOL fWasDataTable;
bool fAutoPosition;
bool fAutoPosX;
bool fAutoPosY;
bool fVert;
bool fWasDataTable;
};
......
......@@ -21,8 +21,8 @@ public:
void readFields(CFRecord& record);
BIFF_WORD iss;
BIFF_BOOL fDelete;
BIFF_BOOL fLabel;
bool fDelete;
bool fLabel;
int serialize(std::wostream & _stream);
......
......@@ -25,9 +25,9 @@ public:
int serialize(std::wostream & _stream);
//-----------------------------
BIFF_BOOL fStacked;
BIFF_BOOL f100;
BIFF_BOOL fHasShadow;
bool fStacked;
bool f100;
bool fHasShadow;
};
......
......@@ -26,9 +26,9 @@ public:
LongRGB rgb;
BIFF_WORD lns;
BIFF_WORD we;
BIFF_BOOL fAuto;
BIFF_BOOL fAxisOn;
BIFF_BOOL fAutoCo;
bool fAuto;
bool fAxisOn;
bool fAutoCo;
IcvChart icv;
};
......
......@@ -21,32 +21,32 @@ public:
void writeFields(CFRecord& record);
void readFields(CFRecord& record);
//-----------------------------
BIFF_BOOL fGhostRow;
BIFF_BOOL fGhostCol;
BIFF_BOOL fEdit;
BIFF_BOOL fDelete;
BIFF_BOOL fCopy;
BIFF_BOOL fPasteAll;
BIFF_BOOL fPasteFormulas;
BIFF_BOOL fPasteValues;
BIFF_BOOL fPasteFormats;
BIFF_BOOL fPasteComments;
BIFF_BOOL fPasteDataValidation;
BIFF_BOOL fPasteBorders;
BIFF_BOOL fPasteColWidths;
BIFF_BOOL fPasteNumberFormats;
BIFF_BOOL fMerge;
BIFF_BOOL fSplitFirst;
BIFF_BOOL fSplitAll;
BIFF_BOOL fRowColShift;
BIFF_BOOL fClearAll;
BIFF_BOOL fClearFormats;
BIFF_BOOL fClearContents;
BIFF_BOOL fClearComments;
BIFF_BOOL fAssign;
BIFF_BOOL fCoerce;
BIFF_BOOL fAdjust;
BIFF_BOOL fCellMeta;
bool fGhostRow;
bool fGhostCol;
bool fEdit;
bool fDelete;
bool fCopy;
bool fPasteAll;
bool fPasteFormulas;
bool fPasteValues;
bool fPasteFormats;
bool fPasteComments;
bool fPasteDataValidation;
bool fPasteBorders;
bool fPasteColWidths;
bool fPasteNumberFormats;
bool fMerge;
bool fSplitFirst;
bool fSplitAll;
bool fRowColShift;
bool fClearAll;
bool fClearFormats;
bool fClearContents;
bool fClearComments;
bool fAssign;
bool fCoerce;
bool fAdjust;
bool fCellMeta;
LPWideString stName;
......
......@@ -27,9 +27,9 @@ public:
LongRGB rgbBack;
BIFF_WORD imk;
BIFF_BOOL fAuto;
BIFF_BOOL fNotShowInt;
BIFF_BOOL fNotShowBrd;
bool fAuto;
bool fNotShowInt;
bool fNotShowBrd;
IcvChart icvFore;
IcvChart icvBack;
......
......@@ -24,8 +24,8 @@ public:
static const ElementType type = typeNamePublish;
//-----------------------------
BIFF_BOOL fPublished;
BIFF_BOOL fWorkbookParam;
bool fPublished;
bool fWorkbookParam;
XLNameUnicodeString strName;
public:
//BO_ATTRIB_MARKUP_BEGIN
......
......@@ -25,7 +25,7 @@ public:
static const ElementType type = typeNote;
//-----------------------------
// BIFF_BOOL is_contained_in_Workbook_;
// bool is_contained_in_Workbook_;
NoteSh note_sh;
// NoteRR note_rr;
......
......@@ -24,9 +24,9 @@ public:
//-----------------------------
BIFF_WORD wScalePLV;
BIFF_BOOL fPageLayoutView;
BIFF_BOOL fRulerVisible;
BIFF_BOOL fWhitespaceHidden;
bool fPageLayoutView;
bool fRulerVisible;
bool fWhitespaceHidden;
public:
//BO_ATTRIB_MARKUP_BEGIN
//BO_ATTRIB_MARKUP_ATTRIB(wScalePLV)
......
......@@ -27,8 +27,8 @@ public:
//-----------------------------
BIFF_WORD anStart;
BIFF_WORD pcDonut;
BIFF_BOOL fHasShadow;
BIFF_BOOL fShowLdrLines;
bool fHasShadow;
bool fShowLdrLines;
};
} // namespace XLS
......
......@@ -23,7 +23,7 @@ public:
static const ElementType type = typePrintGrid;
//-----------------------------
BIFF_BOOL fPrintGrid;
bool fPrintGrid;
public:
//BO_ATTRIB_MARKUP_BEGIN
//BO_ATTRIB_MARKUP_ATTRIB(fPrintGrid)
......
......@@ -25,8 +25,8 @@ public:
int serialize(std::wostream & _stream);
//-----------------------------
BIFF_BOOL fRdrAxLab;
BIFF_BOOL fHasShadow;
bool fRdrAxLab;
bool fHasShadow;
};
} // namespace XLS
......
......@@ -25,8 +25,8 @@ public:
int serialize(std::wostream & _stream);
//-----------------------------
BIFF_BOOL fRdrAxLab;
BIFF_BOOL fHasShadow;
bool fRdrAxLab;
bool fHasShadow;
};
} // namespace XLS
......
......@@ -29,15 +29,15 @@ public:
BIFF_WORD miyRw;
BIFF_BYTE iOutLevel;
BIFF_BOOL fCollapsed;
BIFF_BOOL fDyZero;
BIFF_BOOL fUnsynced;
BIFF_BOOL fGhostDirty;
bool fCollapsed;
bool fDyZero;
bool fUnsynced;
bool fGhostDirty;
BIFF_WORD ixfe_val;
BIFF_BOOL fExAsc;
BIFF_BOOL fExDes;
BIFF_BOOL fPhonetic;
bool fExAsc;
bool fExDes;
bool fPhonetic;
BackwardOnlyParam<unsigned int> in_block_position;
};
......
......@@ -27,9 +27,9 @@ public:
//-----------------------------
BIFF_WORD pcBubbleSizeRatio;
BIFF_WORD wBubbleSize;
BIFF_BOOL fBubbles;
BIFF_BOOL fShowNegBubbles;
BIFF_BOOL fHasShadow;
bool fBubbles;
bool fShowNegBubbles;
bool fHasShadow;
};
......
......@@ -23,9 +23,9 @@ public:
static const ElementType type = typeSerFmt;
//-----------------------------
BIFF_BOOL fSmoothedLine;
BIFF_BOOL f3DBubbles;
BIFF_BOOL fArShadow;
bool fSmoothedLine;
bool f3DBubbles;
bool fArShadow;
};
} // namespace XLS
......
......@@ -29,15 +29,15 @@ public:
BIFF_WORD iFitWidth;
BIFF_WORD iFitHeight;
BIFF_BOOL fLeftToRight;
BIFF_BOOL fPortrait;
BIFF_BOOL fNoPls;
BIFF_BOOL fNoColor;
BIFF_BOOL fDraft;
BIFF_BOOL fNotes;
BIFF_BOOL fNoOrient;
BIFF_BOOL fUsePage;
BIFF_BOOL fEndNotes;
bool fLeftToRight;
bool fPortrait;
bool fNoPls;
bool fNoColor;
bool fDraft;
bool fNotes;
bool fNoOrient;
bool fUsePage;
bool fEndNotes;
BIFF_BYTE iErrors;
BIFF_WORD iRes;
......
......@@ -26,7 +26,7 @@ void ShtProps::writeFields(CFRecord& record)
SETBIT(flags, 0, fManSerAlloc);
SETBIT(flags, 1, fPlotVisOnly);
SETBIT(flags, 2, fNotSizeWith);
BIFF_BOOL fManPlotArea = fAlwaysAutoPlotArea;
bool fManPlotArea = fAlwaysAutoPlotArea;
SETBIT(flags, 3, fManPlotArea);
SETBIT(flags, 4, fAlwaysAutoPlotArea);
record << flags << mdBlank;
......
......@@ -23,11 +23,11 @@ public:
static const ElementType type = typeShtProps;
//-----------------------------
BIFF_BOOL fManSerAlloc;
BIFF_BOOL fManPlotArea;
BIFF_BOOL fPlotVisOnly;
BIFF_BOOL fNotSizeWith;
BIFF_BOOL fAlwaysAutoPlotArea;
bool fManSerAlloc;
bool fManPlotArea;
bool fPlotVisOnly;
bool fNotSizeWith;
bool fAlwaysAutoPlotArea;
BIFF_BYTE mdBlank;
};
......
......@@ -25,13 +25,13 @@ public:
//-----------------------------
BIFF_BOOL fCol;
BIFF_BOOL fKey1Dsc;
BIFF_BOOL fKey2Dsc;
BIFF_BOOL fKey3Dsc;
BIFF_BOOL fCaseSensitive;
bool fCol;
bool fKey1Dsc;
bool fKey2Dsc;
bool fKey3Dsc;
bool fCaseSensitive;
BIFF_SHORT iOrder;
BIFF_BOOL fAltMethod;
bool fAltMethod;
XLUnicodeStringNoCch stKey1;
XLUnicodeStringNoCch stKey2;
......
......@@ -25,9 +25,9 @@ public:
static const ElementType type = typeSortData;
//-----------------------------
BIFF_BOOL fCol;
BIFF_BOOL fCaseSensitive;
BIFF_BOOL fAltMethod;
bool fCol;
bool fCaseSensitive;
bool fAltMethod;
BIFF_BYTE sfp;
BIFF_BSTR rfx;
......
......@@ -41,8 +41,10 @@ void Style::readFields(CFRecord& record)
{
unsigned short flags;
record >> flags;
ixfe = GETBITS(flags, 0, 11);
fBuiltIn = GETBIT(flags, 15);
ixfe = GETBITS(flags, 0, 11);
fBuiltIn = GETBIT(flags, 15);
if(fBuiltIn)
{
record >> builtInData;
......
......@@ -26,11 +26,11 @@ public:
int serialize(std::wostream & stream);
//-----------------------------
BIFF_WORD ixfe;
BIFF_BOOL fBuiltIn;
BIFF_WORD ixfe;
BuiltInStyle builtInData;
XLUnicodeString user;
bool fBuiltIn;
};
} // namespace XLS
......
......@@ -28,9 +28,9 @@ public:
int serialize(std::wostream & stream);
//-----------------------------
BIFF_BOOL fBuiltIn;
BIFF_BOOL fHidden;
BIFF_BOOL fCustom;
bool fBuiltIn;
bool fHidden;
bool fCustom;
BIFF_BYTE iCategory;
BuiltInStyle builtInData;
LPWideString stName;
......
......@@ -25,8 +25,8 @@ public:
int serialize(std::wostream & _stream);
//-----------------------------
BIFF_BOOL fFillSurface;
BIFF_BOOL f3DPhongShade;
bool fFillSurface;
bool f3DPhongShade;
};
} // namespace XLS
......
......@@ -26,11 +26,11 @@ public:
//-----------------------------
Ref ref_;
BIFF_BOOL fAlwaysCalc;
BIFF_BOOL fRw;
BIFF_BOOL fTbl2;
BIFF_BOOL fDeleted1;
BIFF_BOOL fDeleted2;
bool fAlwaysCalc;
bool fRw;
bool fTbl2;
bool fDeleted1;
bool fDeleted2;
BIFF_BSTR r1;
BIFF_BSTR r2;
......
......@@ -24,8 +24,8 @@ public:
static const ElementType type = typeTableStyle;
//-----------------------------
BIFF_BOOL fIsPivot;
BIFF_BOOL fIsTable;
bool fIsPivot;
bool fIsTable;
BIFF_DWORD ctse;
LPWideStringNoCch rgchName;
......
......@@ -34,17 +34,17 @@ public:
BIFF_LONG dx;
BIFF_LONG dy;
BIFF_BOOL fAutoColor;
BIFF_BOOL fShowKey;
BIFF_BOOL fShowValue;
BIFF_BOOL fAutoText;
BIFF_BOOL fGenerated;
BIFF_BOOL fDeleted;
BIFF_BOOL fAutoMode;
BIFF_BOOL fShowLabelAndPerc;
BIFF_BOOL fShowPercent;
BIFF_BOOL fShowBubbleSizes;
BIFF_BOOL fShowLabel;
bool fAutoColor;
bool fShowKey;
bool fShowValue;
bool fAutoText;
bool fGenerated;
bool fDeleted;
bool fAutoMode;
bool fShowLabelAndPerc;
bool fShowPercent;
bool fShowBubbleSizes;
bool fShowLabel;
Icv icvText;
BIFF_BYTE dlp;
......
......@@ -32,10 +32,10 @@ public:
BIFF_BYTE wBkgMode;
LongRGB rgb;
BIFF_BOOL fAutoCo;
BIFF_BOOL fAutoMode;
bool fAutoCo;
bool fAutoMode;
BIFF_BYTE rot;
BIFF_BOOL fAutoRot;
bool fAutoRot;
BIFF_BYTE iReadingOrder;
Icv icv;
......
......@@ -32,22 +32,22 @@ public:
BIFF_DWORD dy;
BIFF_WORD wTabRatio;
BIFF_BOOL fDspFmlaBar;
BIFF_BOOL fDspStatus;
bool fDspFmlaBar;
bool fDspStatus;
BIFF_BSTR mdNoteDisp;
BIFF_BOOL fDspHScroll;
BIFF_BOOL fDspVScroll;
BIFF_BOOL fBotAdornment;
BIFF_BOOL fZoom;
bool fDspHScroll;
bool fDspVScroll;
bool fBotAdornment;
bool fZoom;
BIFF_BSTR fHideObj;
BIFF_BOOL fPrintIncl;
BIFF_BOOL fRowColIncl;
BIFF_BOOL fInvalidTabId;
BIFF_BOOL fTimedUpdate;
BIFF_BOOL fAllMemChanges;
BIFF_BOOL fOnlySync;
BIFF_BOOL fPersonalView;
BIFF_BOOL fIconic;
bool fPrintIncl;
bool fRowColIncl;
bool fInvalidTabId;
bool fTimedUpdate;
bool fAllMemChanges;
bool fOnlySync;
bool fPersonalView;
bool fIconic;
BIFF_WORD wMergeInterval;
XLUnicodeString st;
......
......@@ -30,32 +30,32 @@ public:
Icv icvHdr;
PaneType pnnSel;
BIFF_BOOL fShowBrks;
BIFF_BOOL fDspFmlaSv;
BIFF_BOOL fDspGridSv;
BIFF_BOOL fDspRwColSv;
BIFF_BOOL fDspGutsSv;
BIFF_BOOL fDspZerosSv;
BIFF_BOOL fHorizontal;
BIFF_BOOL fVertical;
BIFF_BOOL fPrintRwCol;
BIFF_BOOL fPrintGrid;
BIFF_BOOL fFitToPage;
BIFF_BOOL fPrintArea;
BIFF_BOOL fOnePrintArea;
BIFF_BOOL fFilterMode;
BIFF_BOOL fEzFilter;
BIFF_BOOL fFrozen;
bool fShowBrks;
bool fDspFmlaSv;
bool fDspGridSv;
bool fDspRwColSv;
bool fDspGutsSv;
bool fDspZerosSv;
bool fHorizontal;
bool fVertical;
bool fPrintRwCol;
bool fPrintGrid;
bool fFitToPage;
bool fPrintArea;
bool fOnePrintArea;
bool fFilterMode;
bool fEzFilter;
bool fFrozen;
BIFF_BOOL fFrozenNoSplit;
BIFF_BOOL fSplitV;
BIFF_BOOL fSplitH;
BIFF_BOOL fHiddenRw;
BIFF_BOOL fHiddenCol;
BIFF_BOOL fFilterUnique;
BIFF_BOOL fSheetLayoutView;
BIFF_BOOL fPageLayoutView;
BIFF_BOOL fRuler;
bool fFrozenNoSplit;
bool fSplitV;
bool fSplitH;
bool fHiddenRw;
bool fHiddenCol;
bool fFilterUnique;
bool fSheetLayoutView;
bool fPageLayoutView;
bool fRuler;
BIFF_BSTR ref8TopLeft;
BIFF_DOUBLE operNumX;
......
......@@ -27,13 +27,13 @@ public:
BIFF_SHORT yWn;
BIFF_SHORT dxWn;
BIFF_SHORT dyWn;
BIFF_BOOL fHidden;
BIFF_BOOL fIconic;
BIFF_BOOL fVeryHidden;
BIFF_BOOL fDspHScroll;
BIFF_BOOL fDspVScroll;
BIFF_BOOL fBotAdornment;
BIFF_BOOL fNoAFDateGroup;
bool fHidden;
bool fIconic;
bool fVeryHidden;
bool fDspHScroll;
bool fDspVScroll;
bool fBotAdornment;
bool fNoAFDateGroup;
BIFF_WORD itabCur;
BIFF_WORD itabFirst;
BIFF_WORD ctabSel;
......
......@@ -24,18 +24,18 @@ public:
static const ElementType type = typeWindow2;
//-----------------------------
BIFF_BOOL fDspFmlaRt;
BIFF_BOOL fDspGridRt;
BIFF_BOOL fDspRwColRt;
BIFF_BOOL fFrozenRt;
BIFF_BOOL fDspZerosRt;
BIFF_BOOL fDefaultHdr;
BIFF_BOOL fRightToLeft;
BIFF_BOOL fDspGuts;
BIFF_BOOL fFrozenNoSplit;
BIFF_BOOL fSelected;
BIFF_BOOL fPaged;
BIFF_BOOL fSLV;
bool fDspFmlaRt;
bool fDspGridRt;
bool fDspRwColRt;
bool fFrozenRt;
bool fDspZerosRt;
bool fDefaultHdr;
bool fRightToLeft;
bool fDspGuts;
bool fFrozenNoSplit;
bool fSelected;
bool fPaged;
bool fSLV;
bool is_contained_in_chart_substream;
......
......@@ -23,17 +23,17 @@ public:
static const ElementType type = typeWsBool;
//-----------------------------
BIFF_BOOL fShowAutoBreaks;
BIFF_BOOL fDialog;
BIFF_BOOL fApplyStyles;
BIFF_BOOL fRowSumsBelow;
BIFF_BOOL fColSumsRight;
BIFF_BOOL fFitToPage;
BIFF_BOOL fDspGuts;
BIFF_BOOL fSyncHoriz;
BIFF_BOOL fSyncVert;
BIFF_BOOL fAltExprEval;
BIFF_BOOL fAltFormulaEntry;
bool fShowAutoBreaks;
bool fDialog;
bool fApplyStyles;
bool fRowSumsBelow;
bool fColSumsRight;
bool fFitToPage;
bool fDspGuts;
bool fSyncHoriz;
bool fSyncVert;
bool fAltExprEval;
bool fAltFormulaEntry;
};
......
......@@ -25,7 +25,7 @@ public:
//-----------------------------
BIFF_WORD ccrn;
BIFF_WORD itab;
BIFF_BOOL itab_exist;
bool itab_exist;
//if(itab_exist)
//{
......
......@@ -30,14 +30,16 @@ public:
//-----------------------------
FontIndex ifnt;
BIFF_WORD ifmt;
BIFF_BOOL fLocked;
BIFF_BOOL fHidden;
BIFF_BOOL fStyle;
BIFF_BOOL f123Prefix;
BIFF_WORD ixfParent;
CellXF cell;
StyleXF style;
BIFF_WORD ixfParent;
CellXF cell;
StyleXF style;
bool fLocked;
bool fHidden;
bool fStyle;
bool f123Prefix;
};
} // namespace XLS
......
......@@ -49,7 +49,6 @@ typedef BiffAttributeSimple<_UINT16> BIFF_WORD;
typedef BiffAttributeSimple<_INT16> BIFF_SHORT;
typedef BiffAttributeSimple<_UINT32> BIFF_DWORD;
typedef BiffAttributeSimple<_INT32> BIFF_LONG;
typedef BiffAttributeSimple<bool> BIFF_BOOL;
typedef BiffAttributeSimple<double> BIFF_DOUBLE;
typedef BiffAttributeSimple<std::wstring> BIFF_BSTR;
......
......@@ -130,9 +130,9 @@ int CELL_GROUP::serialize(std::wostream & stream)
if (row->rw + 1 == current_row_number)
{
bool xf_set = true;
if ((row->fGhostDirty.value()) && ( *row->fGhostDirty.value()== false)) xf_set = false;
if (row->fGhostDirty == false) xf_set = false;
if (row->ixfe_val.value() && xf_set)
if (row->ixfe_val && xf_set)
{
if (row->ixfe_val > cellStyleXfs_count)
{
......@@ -153,15 +153,15 @@ int CELL_GROUP::serialize(std::wostream & stream)
{
CP_XML_ATTR(L"outlineLevel", row->iOutLevel);
}
if ((row->fCollapsed.value()) && (row->fCollapsed))
if (row->fCollapsed)
{
CP_XML_ATTR(L"collapsed", row->fCollapsed);
}
if ((row->fExAsc.value()) && (row->fExAsc))
if (row->fExAsc)
{
CP_XML_ATTR(L"thickTop", true);
}
if ((row->fExDes.value()) && (row->fExDes))
if (row->fExDes)
{
CP_XML_ATTR(L"thickBot", true);
}
......@@ -207,7 +207,7 @@ int CELL_GROUP::serialize(std::wostream & stream)
CP_XML_ATTR(L"r", current_row_number);
bool xf_set = true;
if ((row->fGhostDirty.value()) && ( *row->fGhostDirty.value()== false)) xf_set = false;
if (row->fGhostDirty == false) xf_set = false;
if (row->ixfe_val.value() && xf_set)
{
......@@ -231,7 +231,7 @@ int CELL_GROUP::serialize(std::wostream & stream)
{
CP_XML_ATTR(L"outlineLevel", row->iOutLevel);
}
if ((row->fCollapsed.value()) && (row->fCollapsed))
if (row->fCollapsed)
{
CP_XML_ATTR(L"collapsed", row->fCollapsed);
}
......
......@@ -89,11 +89,11 @@ int COLUMNS::serialize(std::wostream & stream)
CP_XML_ATTR(L"style", column_info->ixfe - cellStyleXfs_count);
}
if ((column_info->fBestFit.value()) && (column_info->fBestFit))
if (column_info->fBestFit)
{
CP_XML_ATTR(L"bestFit", column_info->fBestFit);
}
if ((column_info->fHidden.value()) && (column_info->fHidden))
if (column_info->fHidden)
{
CP_XML_ATTR(L"hidden", column_info->fHidden);
}
......
......@@ -306,7 +306,7 @@ std::wstring CRT::getOoxChartType()
case typeScatter:
{
Scatter * sc = dynamic_cast<Scatter *>(m_ChartType.get());
if ((sc->fBubbles.value()) && (sc->fBubbles))
if (sc->fBubbles)
{
m_iChartType = CHART_TYPE_Bubble;
return L"c:bubbleChart";
......
......@@ -78,7 +78,7 @@ const bool FORMULA::loadContent(BinProcessor& proc)
//proc.optional<SUB>(); // I haven't found any mention about SUB in the docs
}
if ((formula) && (formula->fShrFmla.value()) && (formula->fShrFmla))
if ((formula) && (formula->fShrFmla))
{
for (int i = 0; i < shared_formulas_locations_ref_.size(); i++)
{
......@@ -146,7 +146,7 @@ int FORMULA::serialize(std::wostream & stream)
CP_XML_STREAM() << xml::utils::replace_text_to_xml(f_);
}
}
else if ((formula->fShrFmla.value()) && (formula->fShrFmla == true) && m_sharedIndex >= 0)
else if (formula->fShrFmla && m_sharedIndex >= 0)
{
CP_XML_NODE(L"f")
{
......
......@@ -98,7 +98,7 @@ int GLOBALS::serialize(std::wostream & stream)
DefaultRowHeight* def_row = dynamic_cast<DefaultRowHeight*>(m_DefaultRowHeight.get());
if (def_row)
{
if(!def_row->fDyZero.value() || ((def_row->fDyZero.value()) && (!def_row->fDyZero)))
if(!def_row->fDyZero)
{
CP_XML_ATTR(L"defaultRowHeight", def_row->miyRw / 20.);
CP_XML_ATTR(L"customHeight", true);
......@@ -108,8 +108,8 @@ int GLOBALS::serialize(std::wostream & stream)
CP_XML_ATTR(L"zeroHeight", true);
CP_XML_ATTR(L"defaultRowHeight", def_row->miyRwHidden /20.);
}
if ((def_row->fExAsc.value()) && (def_row->fExAsc)) CP_XML_ATTR(L"thickTop", true);
if ((def_row->fExDsc.value()) && (def_row->fExDsc)) CP_XML_ATTR(L"thickBottom", true);
if (def_row->fExAsc) CP_XML_ATTR(L"thickTop", true);
if (def_row->fExDsc) CP_XML_ATTR(L"thickBottom", true);
}
}
......
......@@ -76,9 +76,10 @@ int STYLES::serialize(std::wostream & stream)
{
CP_XML_ATTR(L"name", styleExt->stName.value());
if ((styleExt->fBuiltIn.value()) && (*styleExt->fBuiltIn.value()))
if (styleExt->fBuiltIn)
{
CP_XML_ATTR(L"builtinId", styleExt->builtInData.istyBuiltIn);
if (styleExt->builtInData.iLevel > 0 && styleExt->builtInData.iLevel < 255)
{
CP_XML_ATTR(L"iLevel", styleExt->builtInData.iLevel);
......@@ -93,7 +94,7 @@ int STYLES::serialize(std::wostream & stream)
{
CP_XML_ATTR(L"name", style->user.value());
if ((style->fBuiltIn.value()) && (*style->fBuiltIn.value()))
if (style->fBuiltIn)
{
CP_XML_ATTR(L"builtinId", style->builtInData.istyBuiltIn);
if (style->builtInData.iLevel > 0 && style->builtInData.iLevel < 255)
......
......@@ -43,7 +43,7 @@ const bool XFS::loadContent(BinProcessor& proc)
// style & complex
XF* xfs = dynamic_cast<XF*>(elements_.front().get());
if ((xfs->fStyle.value()) && (*xfs->fStyle.value()))
if (xfs->fStyle)
{
m_arCellStyles.push_back(elements_.front());
cellStyleXfs_count++;
......
......@@ -992,7 +992,7 @@ void xlsx_drawing_context::serialize_text(std::wostream & stream, _drawing_state
if (drawing_state->wordart.bold) CP_XML_ATTR(L"b", 1);
if (drawing_state->wordart.italic) CP_XML_ATTR(L"i", 1);
if (drawing_state->wordart.underline) CP_XML_ATTR(L"u", 1);
if (drawing_state->wordart.underline) CP_XML_ATTR(L"u", L"sng");
if (drawing_state->wordart.strike) CP_XML_ATTR(L"strike", L"sngStrike");
CP_XML_ATTR(L"kern", 10);
......@@ -1545,7 +1545,7 @@ void xlsx_drawing_context::set_chart_sheet_anchor(double width, double height)
set_anchor(stream.str());
current_drawing_states->back()->type_anchor = 2;
current_drawing_states->back()->type_anchor = 3;
}
void xlsx_drawing_context::serialize(std::wostream & strm)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment