// CodeGear C++Builder
// Copyright (c) 1995, 2014 by Embarcadero Technologies, Inc.
// All rights reserved

// (DO NOT EDIT: machine generated header) 'XLSTools5.pas' rev: 28.00 (Windows)

#ifndef Xlstools5HPP
#define Xlstools5HPP

#pragma delphiheader begin
#pragma option push
#pragma option -w-      // All warnings off
#pragma option -Vx      // Zero-length empty class member 
#pragma pack(push,8)
#include <System.hpp>	// Pascal unit
#include <SysInit.hpp>	// Pascal unit
#include <System.Classes.hpp>	// Pascal unit
#include <System.SysUtils.hpp>	// Pascal unit
#include <System.Contnrs.hpp>	// Pascal unit
#include <Xc12Utils5.hpp>	// Pascal unit
#include <Xc12Common5.hpp>	// Pascal unit
#include <Xc12Manager5.hpp>	// Pascal unit
#include <Xc12DataStyleSheet5.hpp>	// Pascal unit
#include <XLSUtils5.hpp>	// Pascal unit
#include <XLSFormulaTypes5.hpp>	// Pascal unit

//-- user supplied -----------------------------------------------------------

namespace Xlstools5
{
//-- type declarations -------------------------------------------------------
class DELPHICLASS TXLSFontRunData;
#pragma pack(push,4)
class PASCALIMPLEMENTATION TXLSFontRunData : public System::TObject
{
	typedef System::TObject inherited;
	
public:
	/* TObject.Create */ inline __fastcall TXLSFontRunData(void) : System::TObject() { }
	/* TObject.Destroy */ inline __fastcall virtual ~TXLSFontRunData(void) { }
	
};

#pragma pack(pop)

class DELPHICLASS TXLSFontRunBuilder;
#pragma pack(push,4)
class PASCALIMPLEMENTATION TXLSFontRunBuilder : public System::TObject
{
	typedef System::TObject inherited;
	
protected:
	Xc12manager5::TXc12Manager* FManager;
	Xc12datastylesheet5::TXc12DataStyleSheet* FStyles;
	System::UnicodeString FText;
	Xc12datastylesheet5::TXc12DynFontRunArray FRuns;
	bool FBold;
	bool FItalic;
	bool FUnderline;
	int FSize;
	System::UnicodeString FFontName;
	unsigned FColor;
	Xc12datastylesheet5::TXc12Font* __fastcall MakeFont(void);
	Xc12datastylesheet5::PXc12FontRun __fastcall IncFontRuns(void);
	bool __fastcall ExtractTag(System::UnicodeString &AText, /* out */ System::UnicodeString &ATag, /* out */ int &AIndex);
	void __fastcall DoSimpleTag(const System::UnicodeString ATag);
	
public:
	__fastcall TXLSFontRunBuilder(Xc12manager5::TXc12Manager* AManager);
	void __fastcall Clear(void);
	void __fastcall FromSimpleTags(const System::UnicodeString AText);
	__property System::UnicodeString Text = {read=FText};
	__property Xc12datastylesheet5::TXc12DynFontRunArray FontRuns = {read=FRuns};
public:
	/* TObject.Destroy */ inline __fastcall virtual ~TXLSFontRunBuilder(void) { }
	
};

#pragma pack(pop)

class DELPHICLASS TXLSFormattedTextItem;
#pragma pack(push,4)
class PASCALIMPLEMENTATION TXLSFormattedTextItem : public System::TObject
{
	typedef System::TObject inherited;
	
protected:
	System::UnicodeString FText;
	Xc12datastylesheet5::TXc12Font* FFont;
	bool FNewLine;
	
public:
	__fastcall TXLSFormattedTextItem(System::UnicodeString AText, Xc12datastylesheet5::TXc12Font* AFont);
	System::UnicodeString __fastcall AsHTML(void);
	System::UnicodeString __fastcall FontAsRTF(void);
	void __fastcall AddSpecialCR(System::WideChar ACR);
	__property System::UnicodeString Text = {read=FText};
	__property Xc12datastylesheet5::TXc12Font* Font = {read=FFont};
	__property bool NewLine = {read=FNewLine, nodefault};
public:
	/* TObject.Destroy */ inline __fastcall virtual ~TXLSFormattedTextItem(void) { }
	
};

#pragma pack(pop)

class DELPHICLASS TXLSFormattedText;
#pragma pack(push,4)
class PASCALIMPLEMENTATION TXLSFormattedText : public System::Contnrs::TObjectList
{
	typedef System::Contnrs::TObjectList inherited;
	
public:
	TXLSFormattedTextItem* operator[](int Index) { return Items[Index]; }
	
protected:
	Xc12datastylesheet5::TXc12Font* FFirstFont;
	bool FSplitAtCR;
	TXLSFormattedTextItem* __fastcall GetItems(int Index);
	
public:
	__fastcall TXLSFormattedText(void);
	HIDESBASE void __fastcall Assign(TXLSFormattedText* AText);
	HIDESBASE void __fastcall Add(const System::UnicodeString AText, Xc12datastylesheet5::TXc12Font* AFont)/* overload */;
	HIDESBASE void __fastcall Add(const System::UnicodeString AText, Xc12datastylesheet5::TXc12Font* AFirstFont, Xc12datastylesheet5::PXc12FontRunArray AFontRuns, int AFontRunsCount)/* overload */;
	System::UnicodeString __fastcall AsHTML(const bool AIncludeFirstFont = false);
	__property bool SplitAtCR = {read=FSplitAtCR, write=FSplitAtCR, nodefault};
	__property TXLSFormattedTextItem* Items[int Index] = {read=GetItems/*, default*/};
public:
	/* TList.Destroy */ inline __fastcall virtual ~TXLSFormattedText(void) { }
	
};

#pragma pack(pop)

//-- var, const, procedure ---------------------------------------------------
static const System::WideChar XLS_LT_PLACEHOLDER = (System::WideChar)(0x1);
}	/* namespace Xlstools5 */
#if !defined(DELPHIHEADER_NO_IMPLICIT_NAMESPACE_USE) && !defined(NO_USING_NAMESPACE_XLSTOOLS5)
using namespace Xlstools5;
#endif
#pragma pack(pop)
#pragma option pop

#pragma delphiheader end.
//-- end unit ----------------------------------------------------------------
#endif	// Xlstools5HPP
