summaryrefslogtreecommitdiff
path: root/src/rtfformatting.h
diff options
context:
space:
mode:
authorStef Walter <stef@memberwebs.com>2005-06-07 23:19:51 +0000
committerStef Walter <stef@memberwebs.com>2005-06-07 23:19:51 +0000
commit651b7adf13ebc575b4685254c675cc7d35b7fbed (patch)
treeb0f635a5d8b78a78fa8b1d0f6fa7c246b5578ecb /src/rtfformatting.h
parent56f7f66eb13eefb3ea86e9280e321751d8df2761 (diff)
Add 'align' attribute to <para> tag for paragraph alignment.
Diffstat (limited to 'src/rtfformatting.h')
-rw-r--r--src/rtfformatting.h22
1 files changed, 19 insertions, 3 deletions
diff --git a/src/rtfformatting.h b/src/rtfformatting.h
index db687eb..cab1e4f 100644
--- a/src/rtfformatting.h
+++ b/src/rtfformatting.h
@@ -79,7 +79,8 @@ public:
{
return m_style == format.m_style &&
m_list == format.m_list &&
- m_inTbl == format.m_inTbl;
+ m_inTbl == format.m_inTbl &&
+ m_align == format.m_align;
}
void copy(const RtfFormatting& format)
@@ -99,12 +100,13 @@ public:
m_style = format.m_style;
m_list = format.m_list;
m_inTbl = format.m_inTbl;
+ m_align = format.m_align;
}
void resetText()
{
m_bold = m_italic = m_strike =
- m_underline = m_hidden = false;
+ m_underline = m_hidden = false;
m_color = -1;
m_highlight = -1;
m_suscript = 0;
@@ -117,6 +119,7 @@ public:
{
m_style = m_list = -1;
m_inTbl = false;
+ m_align = LEFT;
}
bool textIsBold() const
@@ -147,6 +150,8 @@ public:
{ return m_list; }
bool paraInTable() const
{ return m_inTbl; }
+ int paraAlign() const
+ { return m_align; }
void textSetBold(bool bold)
{ m_bold = bold; }
@@ -176,6 +181,8 @@ public:
{ m_list = list; }
void paraSetTable(bool inTable)
{ m_inTbl = inTable; }
+ void paraSetAlign(int align)
+ { m_align = align; }
enum
{
@@ -183,13 +190,21 @@ public:
SUBSCRIPT
};
+ enum
+ {
+ LEFT = 0,
+ CENTER,
+ RIGHT,
+ JUSTIFY
+ };
+
protected:
bool m_bold;
bool m_italic;
bool m_strike;
bool m_underline;
bool m_hidden;
- int m_suscript;
+ int m_suscript;
int m_color;
int m_highlight;
int m_font;
@@ -199,6 +214,7 @@ protected:
int m_style;
int m_list;
bool m_inTbl;
+ int m_align;
};
#endif // __RTFFORMATTING_H__