29 #include <document.hxx>
43 bool bEndOfSheet =
false;
45 SAL_INFO(
"sc",
"Read sheet " << nTab);
58 pStyle->
SetFormat( &rDoc, nCol, nRow, nTab, nStyle );
74 pStyle->
SetFormat( &rDoc, nCol, nRow, nTab, nStyle );
81 pStyle->
SetFormat( &rDoc, nCol, nRow, nTab, nStyle );
91 pStyle->
SetFormat( &rDoc, nCol, nRow, nTab, nStyle );
109 std::unique_ptr<ScTokenArray> pArray;
117 nStyle = nStyle >> 3;
119 pStyle->
SetFormat( &rDoc, nCol, nRow, nTab, nStyle );
143 , mnMaxTab(
utl::ConfigManager::IsFuzzing() ? 128 :
MAXTAB)
162 sal_uInt16
i = 1, j = 1;
169 std::unique_ptr<ScQProStyle> pStyleElement(
new ScQProStyle );
190 eRet =
readSheet( nTab, rDoc, pStyleElement.get() );
203 pStyleElement->setAlign( i, nAlign );
204 pStyleElement->setFont( i, nFont );
210 sal_uInt16 nPtSize, nFontAttr;
213 pStyleElement->setFontRecord( j, nFontAttr, nPtSize );
219 pStyleElement->setFontType( j, aLabel );
261 eRet = aReader.
parse(aDocument);
292 fprintf( stderr,
"Read record 0x%x length 0x%x at offset 0x%x\n",
295 #if 1 // rather verbose
298 int i, chunk = std::min(len, 16);
299 unsigned char data[16];
302 for (i = 0; i < chunk; i++)
303 fprintf( stderr,
"%.2x ", data[i] );
304 fprintf( stderr,
"| " );
305 for (i = 0; i < chunk; i++)
306 fprintf( stderr,
"%c", data[i] < 127 && data[i] > 30 ? data[i] :
'.' );
307 fprintf( stderr,
"\n" );
SvStream & ReadInt16(sal_Int16 &rInt16)
OUString readString(sal_uInt16 nLength)
SC_DLLPUBLIC svl::SharedStringPool & GetSharedStringPool()
SvStream & ReadUInt16(sal_uInt16 &rUInt16)
sal_uInt64 Seek(sal_uInt64 nPos)
SC_DLLPUBLIC void SetValue(SCCOL nCol, SCROW nRow, SCTAB nTab, const double &rVal)
void SetHardRecalcState(HardRecalcState eVal)
SC_DLLPUBLIC void SetTextCell(const ScAddress &rPos, const OUString &rStr)
Call this if you are not sure whether to put this as an edit text or a simple text.
SC_DLLPUBLIC void SetImportingXML(bool bVal)
SC_DLLPUBLIC bool RenameTab(SCTAB nTab, const OUString &rName, bool bExternalDocument=false)
ErrCode parse(ScDocument &rDoc)
void SetLookUpColRowNames(bool bVal)
void SetInsertingFromOtherDoc(bool bVal)
SC_DLLPUBLIC const ScDocOptions & GetDocOptions() const
void EnableExecuteLink(bool bVal)
ErrCode import(ScDocument &rDoc)
static SC_DLLPUBLIC void Init()
DLL-init/exit-code must be linked to the DLL only.
ScQProReader(SvStream *pStream)
sal_uInt16 getLength() const
SC_DLLPUBLIC bool InsertTab(SCTAB nPos, const OUString &rName, bool bExternalDocument=false, bool bUndoDeleteTab=false)
ErrCode readSheet(SCTAB nTab, ScDocument &rDoc, ScQProStyle *pStyle)
void SetBufferSize(sal_uInt16 m_nBufSize)
SvStream & ReadUChar(unsigned char &rChar)
SvStream & ReadDouble(double &rDouble)
#define SCERR_IMPORT_OPEN
exports com.sun.star.chart2. data
SC_DLLPUBLIC void EnsureTable(SCTAB nTab)
SC_DLLPUBLIC void CalcAfterLoad(bool bStartListening=true)
void SetFormat(ScDocument *pDoc, sal_uInt8 nCol, sal_uInt16 nRow, SCTAB nTab, sal_uInt16 nStyle)
SC_DLLPUBLIC ScFormulaCell * SetFormulaCell(const ScAddress &rPos, ScFormulaCell *pCell)
Set formula cell, and transfer its ownership to the document.
SC_DLLPUBLIC void SetDocOptions(const ScDocOptions &rOpt)
SAL_DLLPUBLIC_EXPORT bool TestImportQPW(SvStream &rStream)
CalcAll() without broadcast/notify but setting up new listeners.
#define SAL_INFO(area, stream)
void SetStreamCharSet(rtl_TextEncoding eCharSet)
rtl_TextEncoding GetStreamCharSet() const
#define SCERR_IMPORT_FORMAT
SC_DLLPUBLIC void MakeTable(SCTAB nTab, bool _bNeedsNameCheck=true)
OUString read_uInt8s_ToOUString(SvStream &rStrm, std::size_t nUnits, rtl_TextEncoding eEnc)