Diffstat (limited to 'core/settings/launcher/tabssettings.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/settings/launcher/tabssettings.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/core/settings/launcher/tabssettings.cpp b/core/settings/launcher/tabssettings.cpp index fc2d2c9..ae78733 100644 --- a/core/settings/launcher/tabssettings.cpp +++ b/core/settings/launcher/tabssettings.cpp | |||
@@ -111,27 +111,29 @@ void TabsSettings::readTabSettings ( ) | |||
111 | if ( bgType == "SolidColor" ) | 111 | if ( bgType == "SolidColor" ) |
112 | tc. m_bg_type = TabConfig::SolidColor; | 112 | tc. m_bg_type = TabConfig::SolidColor; |
113 | else if ( bgType == "Image" ) // No tr | 113 | else if ( bgType == "Image" ) // No tr |
114 | tc. m_bg_type = TabConfig::Image; | 114 | tc. m_bg_type = TabConfig::Image; |
115 | 115 | ||
116 | tc. m_bg_image = cfg. readEntry ( "BackgroundImage", "wallpaper/opie" ); | 116 | tc. m_bg_image = cfg. readEntry ( "BackgroundImage", "wallpaper/opie" ); |
117 | tc. m_bg_color = cfg. readEntry ( "BackgroundColor" ); | 117 | tc. m_bg_color = cfg. readEntry ( "BackgroundColor" ); |
118 | tc. m_text_color = cfg. readEntry ( "TextColor" ); | 118 | tc. m_text_color = cfg. readEntry ( "TextColor" ); |
119 | QStringList f = cfg. readListEntry ( "Font", ',' ); | 119 | QStringList f = cfg. readListEntry ( "Font", ',' ); |
120 | if ( f. count ( ) == 4 ) { | 120 | if ( f. count ( ) == 4 ) { |
121 | tc. m_font_family = f [0]; | 121 | tc. m_font_family = f [0]; |
122 | tc. m_font_size = f [1]. toInt ( ); | 122 | tc. m_font_size = f [1]. toInt ( ); |
123 | tc. m_font_style = f [2]; | ||
123 | } else { | 124 | } else { |
124 | tc. m_font_family = font ( ). family ( ); | 125 | tc. m_font_family = font ( ). family ( ); |
125 | tc. m_font_size = font ( ). pointSize ( ); | 126 | tc. m_font_size = font ( ). pointSize ( ); |
127 | tc. m_font_style = "Regular"; | ||
126 | } | 128 | } |
127 | m_tabs [*it] = tc; | 129 | m_tabs [*it] = tc; |
128 | } | 130 | } |
129 | } | 131 | } |
130 | 132 | ||
131 | 133 | ||
132 | void TabsSettings::accept ( ) | 134 | void TabsSettings::accept ( ) |
133 | { | 135 | { |
134 | Config cfg ( "Launcher" ); | 136 | Config cfg ( "Launcher" ); |
135 | 137 | ||
136 | // Launcher Tab | 138 | // Launcher Tab |
137 | QString grp ( "Tab %1" ); // No tr | 139 | QString grp ( "Tab %1" ); // No tr |
@@ -149,25 +151,25 @@ void TabsSettings::accept ( ) | |||
149 | case TabConfig::List: | 151 | case TabConfig::List: |
150 | cfg.writeEntry ( "View", "List" ); | 152 | cfg.writeEntry ( "View", "List" ); |
151 | break; | 153 | break; |
152 | } | 154 | } |
153 | 155 | ||
154 | QCopEnvelope e ( "QPE/Launcher", "setTabView(QString,int)" ); | 156 | QCopEnvelope e ( "QPE/Launcher", "setTabView(QString,int)" ); |
155 | e << *it << tc. m_view; | 157 | e << *it << tc. m_view; |
156 | 158 | ||
157 | cfg. writeEntry ( "BackgroundImage", tc. m_bg_image ); | 159 | cfg. writeEntry ( "BackgroundImage", tc. m_bg_image ); |
158 | cfg. writeEntry ( "BackgroundColor", tc. m_bg_color ); | 160 | cfg. writeEntry ( "BackgroundColor", tc. m_bg_color ); |
159 | cfg. writeEntry ( "TextColor", tc. m_text_color ); | 161 | cfg. writeEntry ( "TextColor", tc. m_text_color ); |
160 | 162 | ||
161 | QString f = tc. m_font_family + "," + QString::number ( tc. m_font_size ) + ",50,0"; | 163 | QString f = tc. m_font_family + "," + QString::number ( tc. m_font_size ) + "," + tc. m_font_style + ",0"; |
162 | cfg. writeEntry ( "Font", f ); | 164 | cfg. writeEntry ( "Font", f ); |
163 | QCopEnvelope be ( "QPE/Launcher", "setTabBackground(QString,int,QString)" ); | 165 | QCopEnvelope be ( "QPE/Launcher", "setTabBackground(QString,int,QString)" ); |
164 | 166 | ||
165 | switch ( tc. m_bg_type ) { | 167 | switch ( tc. m_bg_type ) { |
166 | case TabConfig::Ruled: | 168 | case TabConfig::Ruled: |
167 | cfg.writeEntry( "BackgroundType", "Ruled" ); | 169 | cfg.writeEntry( "BackgroundType", "Ruled" ); |
168 | be << *it << tc. m_bg_type << QString(""); | 170 | be << *it << tc. m_bg_type << QString(""); |
169 | break; | 171 | break; |
170 | case TabConfig::SolidColor: | 172 | case TabConfig::SolidColor: |
171 | cfg.writeEntry( "BackgroundType", "SolidColor" ); | 173 | cfg.writeEntry( "BackgroundType", "SolidColor" ); |
172 | be << *it << tc. m_bg_type << tc. m_bg_color; | 174 | be << *it << tc. m_bg_type << tc. m_bg_color; |
173 | break; | 175 | break; |