author | groucho <groucho> | 2003-05-07 09:01:39 (UTC) |
---|---|---|
committer | groucho <groucho> | 2003-05-07 09:01:39 (UTC) |
commit | 118d03d815a7615b9c53363218a7ac45b3f4c514 (patch) (side-by-side diff) | |
tree | 356953e2413cddcec0f35bd47bb6439767da7051 /noncore/apps/opie-reader/StyleConsts.h | |
parent | 00894537decf01c5a5cdc565b2740b5e67a2e90f (diff) | |
download | opie-118d03d815a7615b9c53363218a7ac45b3f4c514.zip opie-118d03d815a7615b9c53363218a7ac45b3f4c514.tar.gz opie-118d03d815a7615b9c53363218a7ac45b3f4c514.tar.bz2 |
Incorporated TimWs current source tree and make it compile
Diffstat (limited to 'noncore/apps/opie-reader/StyleConsts.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/opie-reader/StyleConsts.h | 32 |
1 files changed, 22 insertions, 10 deletions
diff --git a/noncore/apps/opie-reader/StyleConsts.h b/noncore/apps/opie-reader/StyleConsts.h index 9701d19..29d7501 100644 --- a/noncore/apps/opie-reader/StyleConsts.h +++ b/noncore/apps/opie-reader/StyleConsts.h @@ -5,6 +5,8 @@ typedef unsigned short StyleType; -#include <stdlib.h> +#ifdef _WINDOWS #include <string.h> +#endif +#include <stdlib.h> #include <qglobal.h> -class QPixmap; +class QImage; @@ -12,6 +14,6 @@ struct GraphicLink { - QPixmap* graphic; + QImage* graphic; bool isLink; unsigned long link; - GraphicLink(QPixmap* p, bool isLnk, unsigned long tgt) : + GraphicLink(QImage* p, bool isLnk, unsigned long tgt) : graphic(p), isLink(isLnk), link(tgt) {} @@ -23,4 +25,5 @@ struct pmstore unsigned int count; + bool m_isScaleable; GraphicLink* graphic; - pmstore(QPixmap* p, bool isLnk, unsigned long tgt) : count(1) + pmstore(bool _canScale, QImage* p, bool isLnk, unsigned long tgt) : count(1), m_isScaleable(_canScale) { @@ -53,2 +56,4 @@ class CBasicStyle unsigned char m_leftmargin, m_rightmargin; + signed char m_extraspace; + signed char m_voffset; CBasicStyle() @@ -75,2 +80,4 @@ class CBasicStyle m_monospaced = false; + m_extraspace = 0; + m_voffset = 0; } @@ -83,2 +90,6 @@ class CStyle public: + signed char getVOffset() { return sty.m_voffset; } + void setVOffset(signed char sp) { sty.m_voffset = sp; } + signed char getExtraSpace() { return sty.m_extraspace; } + void setExtraSpace(signed char sp) { sty.m_extraspace = sp; } bool getPictureLink() @@ -106,3 +117,3 @@ class CStyle ~CStyle(); - CStyle(CStyle&); +// CStyle(CStyle&); CStyle(const CStyle&); @@ -111,7 +122,8 @@ class CStyle bool isPicture() { return (graphic != NULL); } + bool canScale() { return graphic->m_isScaleable; } void clearPicture(); - void setPicture(QPixmap* _g, bool il=false, unsigned long tgt=0); - QPixmap* getPicture() + void setPicture(bool canScale, QImage* _g, bool il=false, unsigned long tgt=0); + QImage* getPicture() { - QPixmap* pm = ((graphic != NULL) ? graphic->graphic->graphic : NULL); + QImage* pm = ((graphic != NULL) ? graphic->graphic->graphic : NULL); return pm; @@ -159,3 +171,3 @@ class CStyle } - int getFontSize() + int getFontSize() const { |