38 #ifndef MWAW_FONT_CONVERTER
39 # define MWAW_FONT_CONVERTER
46 namespace MWAWFontConverterInternal
74 int getId(std::string
const &name, std::string family=
"")
const;
76 std::string
getName(
int macId)
const;
78 void setCorrespondance(
int macId, std::string
const &name, std::string family=
"");
86 void getOdtInfo(
int macId, std::string &name,
int &deltaSize)
const;
90 int unicode(
int macId,
unsigned char c)
const;
98 int unicode(
int macId,
unsigned char c,
unsigned char const *(&str),
int len)
const;
101 static std::string
getValidName(std::string
const &name);
104 mutable shared_ptr<MWAWFontConverterInternal::State>
m_manager;
Definition: MWAWFontConverter.hxx:66
Definition: MWAWFontConverter.hxx:66
MWAWFontConverter()
the constructor
Definition: MWAWFontConverter.cxx:913
Encoding
the character encoding type
Definition: MWAWFontConverter.hxx:66
int getId(std::string const &name, std::string family="") const
returns an unique id > 255, if unknown
Definition: MWAWFontConverter.cxx:941
~MWAWFontConverter()
the destructor
Definition: MWAWFontConverter.cxx:914
static std::string getValidName(std::string const &name)
check if a string is valid, if not, convert it to a valid string
Definition: MWAWFontConverter.cxx:917
void getOdtInfo(int macId, std::string &name, int &deltaSize) const
final font name and a delta which can be used to change the size if no name is found, return "Times New Roman"
Definition: MWAWFontConverter.cxx:951
void setCorrespondance(int macId, std::string const &name, std::string family="")
fixes the name corresponding to an id
Definition: MWAWFontConverter.cxx:936
shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:496
a namespace used to convert Mac font characters in unicode
Definition: MWAWFontConverter.hxx:62
std::string getName(int macId) const
returns empty string if unknown
Definition: MWAWFontConverter.cxx:946
shared_ptr< MWAWFontConverterInternal::State > m_manager
the main manager
Definition: MWAWFontConverter.hxx:104
int unicode(int macId, unsigned char c) const
converts a character in unicode
Definition: MWAWFontConverter.cxx:956