20 #ifndef INCLUDED_SC_SOURCE_FILTER_INC_XIHELPER_HXX
21 #define INCLUDED_SC_SOURCE_FILTER_INC_XIHELPER_HXX
35 class SharedStringPool;
71 SCTAB nScTab,
bool bWarn );
240 std::vector< XclImpHFPortionInfo >
273 const OUString& rEncodedUrl );
284 const OUString& rEncodedUrl );
290 static bool DecodeLink( OUString& rApplic, OUString& rTopic,
const OUString& rEncUrl );
virtual ~XclImpCachedValue()
This class provides methods to convert an XclImpString.
sal_uInt16 mnMaxLineHt
Height of previous lines in twips.
static std::unique_ptr< EditTextObject > CreateTextObject(const XclImpRoot &rRoot, const XclImpString &rString)
Returns a new edit engine text object.
static bool DecodeLink(OUString &rApplic, OUString &rTopic, const OUString &rEncUrl)
Decodes the passed URL to OLE or DDE link components.
const sal_uInt8 EXC_ERR_NA
void InsertLineBreak()
Inserts a line break and adjusts the current selection object.
XclImpUrlHelper()=delete
We don't want anybody to instantiate this class, since it is just a collection of static methods...
SCSIZE mnScCols
List of cached cell values.
XclImpHFPortionInfo()
Maximum font height for the current text line.
XclFontDataPtr mxFontData
Current text to insert into edit engine.
void SetAttribs()
Sets the font attributes at the current selection.
void ResetFontData()
Resets font data to application default font.
sal_uInt16 GetMaxLineHeight(XclImpHFPortion ePortion) const
Returns the maximum line height of the specified portion.
This struct helps reading and writing Excel fonts.
sal_uInt8 mnType
Boolean value or Excel error code.
void ConvertRangeList(ScRangeList &rScRanges, const XclRangeList &rXclRanges, SCTAB nScTab, bool bWarn)
Converts the passed Excel cell range list to a Calc cell range list.
const sal_uInt8 EXC_CACHEDVAL_ERROR
Accessor class to ScDocument.
static void SetToDocument(ScDocumentImport &rDoc, const ScAddress &rPos, const XclImpRoot &rRoot, const XclImpString &rString, sal_uInt16 nXFIndex)
virtual ~XclImpHFConverter() override
void SetNewPortion(XclImpHFPortion eNew)
Changes current header/footer portion to eNew.
Converts an Excel header/footer string into three edit engine text objects.
Provides functions to convert Excel cell addresses to Calc cell addresses.
const OUString & GetString() const
Returns the cached string value, if this value is a string, else an empty string. ...
double GetValue() const
Returns the cached number, if this value has number type, else 0.0.
size_t SCSIZE
size_t typedef to be able to find places where code was changed from USHORT to size_t and is used to ...
ScMatrixRef CreateScMatrix(svl::SharedStringPool &rPool) const
Creates a new ScMatrix object and fills it with the contained values.
void UpdateMaxLineHeight(XclImpHFPortion ePortion)
Updates the maximum line height of the specified portion, using the current font size.
void ParseString(const OUString &rHFString)
Parses the passed string and creates three new edit engine text objects.
::boost::intrusive_ptr< ScMatrix > ScMatrixRef
double mfValue
Cached value is a string.
SCSIZE mnScRows
Number of cached columns.
sal_uInt8 GetType() const
Returns the type of the cached value (EXC_CACHEDVAL_*).
ESelection maSel
Edit engine text object.
std::shared_ptr< EditTextObject > EditTextObjectRef
ESelection & GetCurrSel()
Returns the current selection.
ScTokenArrayPtr mxTokArr
Cached value is a double.
bool ConvertAddress(ScAddress &rScPos, const XclAddress &rXclPos, SCTAB nScTab, bool bWarn)
Converts the passed Excel cell address to a Calc cell address.
void UpdateCurrMaxLineHeight()
Updates the current maximum line height, using the current font size.
OUStringBuffer maCurrText
Edit engine text objects for all portions.
std::vector< std::unique_ptr< XclImpCachedValue > > XclImpValueList
A 2D cell range address list with Excel column and row indexes.
XclImpHFPortion meCurrObj
Font data of current text.
const XclImpHFConverter & operator=(const XclImpHFConverter &)=delete
delete copy-assignment operator
const sal_uInt8 EXC_CACHEDVAL_BOOL
bool CheckAddress(const XclAddress &rXclPos, bool bWarn)
Checks if the passed Excel cell address is valid.
::std::unique_ptr< const ScTokenArray > ScTokenArrayPtr
Contains cached values in a 2-dimensional array.
std::vector< XclImpHFPortionInfo > maInfos
The header/footer edit engine.
XclImpStringHelper()=delete
We don't want anybody to instantiate this class, since it is just a collection of static methods...
A 2D cell address struct with Excel column and row indexes.
XclImpCachedMatrix(XclImpStream &rStrm)
sal_uInt8 mnBoolErr
Cached value is a formula or error code or Boolean.
ScAddress CreateValidAddress(const XclAddress &rXclPos, SCTAB nScTab, bool bWarn)
Returns a valid cell address by moving it into allowed dimensions.
This class contains static methods to decode a URL stored in an Excel file.
XclImpHFPortionInfo::EditTextObjectRef & GetCurrObj()
Returns the current edit engine text object.
XclImpCachedValue(const XclImpCachedValue &)=delete
delete copy constructor
XclImpHFPortionInfo & GetCurrInfo()
Returns the current edit engine text object.
const XclImpUrlHelper & operator=(const XclImpUrlHelper &)=delete
delete copy-assignment operator
XclImpHFPortion
Enumerates the supported header/footer portions.
void FillToItemSet(SfxItemSet &rItemSet, sal_uInt16 nWhichId) const
Creates a ScPageHFItem and inserts it into the passed item set.
::std::unique_ptr< XclFontData > XclFontDataPtr
sal_uInt8 GetXclError() const
Returns the cached Calc error code, if this value has Error type, else 0.
These need to be in global namespace just like their respective types are.
Contains all information about a header/footer portion.
Base class for import/export address converters.
void InsertField(const SvxFieldItem &rFieldItem)
Inserts the passed text field and adjusts the current selection object.
bool ConvertRange(ScRange &rScRange, const XclRange &rXclRange, SCTAB nScTab1, SCTAB nScTab2, bool bWarn)
Converts the passed Excel cell range to a Calc cell range.
const XclImpCachedValue & operator=(const XclImpCachedValue &)=delete
delete copy-assignment operator
const XclImpStringHelper & operator=(const XclImpStringHelper &)=delete
delete copy-assignment operator
XclImpAddressConverter(const XclImpRoot &rRoot)
sal_Int32 GetTotalHeight() const
Returns the total height of the converted header or footer in twips.
XclImpValueList maValueList
void CreateCurrObject()
Creates the edit engine text object of current portion from edit engine.
bool GetBool() const
Returns the cached Boolean value, if this value has Boolean type, else false.
This class is used to import record oriented streams.
XclImpHFConverter(const XclImpHFConverter &)=delete
delete copy constructor
This class stores one cached value of a cached value list (used for instance in CRN, EXTERNNAME, tArray).
Access to global data from other classes.
FormulaError GetScError() const
Returns the cached Calc error code, if this value has Error type, else 0.
This class represents an unformatted or formatted string and provides importing from stream...
sal_Int32 mnHeight
Edit engine selection.
void InsertText()
Inserts maCurrText into edit engine and adjusts the current selection object.
A 2D cell range address struct with Excel column and row indexes.
static void DecodeUrl(OUString &rUrl, OUString &rTabName, bool &rbSameWb, const XclImpRoot &rRoot, const OUString &rEncodedUrl)
Decodes an encoded external document URL with optional sheet name.