-rw-r--r-- | libopie/ocolorbutton.cpp | 5 | ||||
-rw-r--r-- | libopie/ofontselector.cpp | 5 | ||||
-rw-r--r-- | libopie/ofontselector.h | 1 |
3 files changed, 10 insertions, 1 deletions
diff --git a/libopie/ocolorbutton.cpp b/libopie/ocolorbutton.cpp index 96e5612..4734c0c 100644 --- a/libopie/ocolorbutton.cpp +++ b/libopie/ocolorbutton.cpp | |||
@@ -51,7 +51,10 @@ OColorButton::OColorButton ( QWidget *parent, const char *name ) | |||
51 | connect ( d-> m_menu, SIGNAL( colorSelected ( const QColor & )), this, SLOT( updateColor ( const QColor & ))); | 51 | connect ( d-> m_menu, SIGNAL( colorSelected ( const QColor & )), this, SLOT( updateColor ( const QColor & ))); |
52 | 52 | ||
53 | updateColor ( black ); | 53 | updateColor ( black ); |
54 | setMinimumSize ( sizeHint ( ) + QSize ( 8, 0 )); | 54 | |
55 | QSize s = sizeHint ( ) + QSize ( 12, 0 ); | ||
56 | setMinimumSize ( s ); | ||
57 | setMaximumSize ( s. width ( ) * 2, s. height ( )); | ||
55 | } | 58 | } |
56 | 59 | ||
57 | OColorButton::~OColorButton ( ) | 60 | OColorButton::~OColorButton ( ) |
diff --git a/libopie/ofontselector.cpp b/libopie/ofontselector.cpp index d32aeb4..39440af 100644 --- a/libopie/ofontselector.cpp +++ b/libopie/ofontselector.cpp | |||
@@ -112,6 +112,11 @@ OFontSelector::~OFontSelector ( ) | |||
112 | { | 112 | { |
113 | } | 113 | } |
114 | 114 | ||
115 | bool OFontSelector::setSelectedFont ( const QFont &f ) | ||
116 | { | ||
117 | return setSelectedFont ( f. family ( ), m_fdb. styleString ( f ), f. pointSize ( ), QFont::encodingName ( f. charSet ( ))); | ||
118 | } | ||
119 | |||
115 | bool OFontSelector::setSelectedFont ( const QString &familyStr, const QString &styleStr, int sizeVal, const QString & /*charset*/ ) | 120 | bool OFontSelector::setSelectedFont ( const QString &familyStr, const QString &styleStr, int sizeVal, const QString & /*charset*/ ) |
116 | { | 121 | { |
117 | QString sizeStr = QString::number ( sizeVal ); | 122 | QString sizeStr = QString::number ( sizeVal ); |
diff --git a/libopie/ofontselector.h b/libopie/ofontselector.h index 2011e43..b3aa862 100644 --- a/libopie/ofontselector.h +++ b/libopie/ofontselector.h | |||
@@ -49,6 +49,7 @@ public: | |||
49 | 49 | ||
50 | QFont selectedFont ( ); | 50 | QFont selectedFont ( ); |
51 | 51 | ||
52 | bool setSelectedFont ( const QFont & ); | ||
52 | bool setSelectedFont ( const QString &family, const QString &style, int size, const QString &charset = 0 ); | 53 | bool setSelectedFont ( const QString &family, const QString &style, int size, const QString &charset = 0 ); |
53 | 54 | ||
54 | QString fontFamily ( ) const; | 55 | QString fontFamily ( ) const; |