Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 352324
Collapse All | Expand All

(-)kwin/clients/aurorae/src/aurorae.cpp (-1 / +21 lines)
Lines 203-208 Link Here
203
    m_scene->setShade(isShade());
203
    m_scene->setShade(isShade());
204
    m_scene->setKeepAbove(keepAbove());
204
    m_scene->setKeepAbove(keepAbove());
205
    m_scene->setKeepBelow(keepBelow());
205
    m_scene->setKeepBelow(keepBelow());
206
    m_scene->setFont(KDecoration::options()->font(true), true);
207
    m_scene->setFont(KDecoration::options()->font(false), false);
206
    AuroraeFactory::instance()->theme()->setCompositingActive(compositingActive());
208
    AuroraeFactory::instance()->theme()->setCompositingActive(compositingActive());
207
}
209
}
208
210
Lines 321-326 Link Here
321
        m_scene->setButtons(options()->customButtonPositions() ? options()->titleButtonsLeft() : AuroraeFactory::instance()->theme()->defaultButtonsLeft(),
323
        m_scene->setButtons(options()->customButtonPositions() ? options()->titleButtonsLeft() : AuroraeFactory::instance()->theme()->defaultButtonsLeft(),
322
                            options()->customButtonPositions() ? options()->titleButtonsRight() : AuroraeFactory::instance()->theme()->defaultButtonsRight());
324
                            options()->customButtonPositions() ? options()->titleButtonsRight() : AuroraeFactory::instance()->theme()->defaultButtonsRight());
323
    }
325
    }
326
    if (changed & SettingFont) {
327
        m_scene->setFont(KDecoration::options()->font(true), true);
328
        m_scene->setFont(KDecoration::options()->font(false), false);
329
    }
324
    KDecoration::reset(changed);
330
    KDecoration::reset(changed);
325
}
331
}
326
332
327
-- kwin/clients/aurorae/src/lib/auroraescene.cpp    2010-09-30 23:20:20.000000000 +0200
333
++ kwin/clients/aurorae/src/lib/auroraescene.cpp    2011-01-21 10:16:17.043000064 +0100
Lines 1055-1058 Link Here
1055
    return m_rightButtonOrder;
1055
    return m_rightButtonOrder;
1056
}
1056
}
1057
1057
1058
const QFont &AuroraeScene::font(bool active) const
1059
{
1060
    return active ? m_activeFont : m_inactiveFont;
1061
}
1062
1063
void AuroraeScene::setFont(const QFont &font, bool active)
1064
{
1065
    if (active) {
1066
        m_activeFont = font;
1067
    } else {
1068
        m_inactiveFont = font;
1069
    }
1070
}
1071
1058
} // namespace
1072
} // namespace
(-)kwin/clients/aurorae/src/lib/auroraescene.h (+15 lines)
Lines 148-153 Link Here
148
    void setUniqueTabDragId(int index, long int id);
148
    void setUniqueTabDragId(int index, long int id);
149
    const QString &leftButtons() const;
149
    const QString &leftButtons() const;
150
    const QString &rightButtons() const;
150
    const QString &rightButtons() const;
151
    /**
152
     * @param active Whether the active or inactive title font should be returned
153
     * @return the (in)active title font.
154
     * @since 4.6
155
     **/ 
156
    const QFont &font(bool active) const;
157
    /**
158
     * Sets a new title font.
159
     * @param font The new font
160
     * @param active Whether the active or inactive title font should be set
161
     * @since 4.6
162
     **/
163
    void setFont(const QFont &font, bool active);
151
164
152
Q_SIGNALS:
165
Q_SIGNALS:
153
    void menuClicked();
166
    void menuClicked();
Lines 211-216 Link Here
211
    bool m_contextHelp;
224
    bool m_contextHelp;
212
    int m_tabCount;
225
    int m_tabCount;
213
    int m_focusedTab;
226
    int m_focusedTab;
227
    QFont m_activeFont;
228
    QFont m_inactiveFont;
214
};
229
};
215
230
216
} // namespace
231
} // namespace
(-)kwin/clients/aurorae/src/lib/auroraetab.cpp (+2 lines)
Lines 113-118 Link Here
113
    const bool focused = s->isFocusedTab(m_index);
113
    const bool focused = s->isFocusedTab(m_index);
114
    const ThemeConfig &conf = m_theme->themeConfig();
114
    const ThemeConfig &conf = m_theme->themeConfig();
115
    const DecorationPosition decoPos = s->isShade() ? DecorationTop : m_theme->decorationPosition();
115
    const DecorationPosition decoPos = s->isShade() ? DecorationTop : m_theme->decorationPosition();
116
    painter->setFont(s->font(active));
116
    if (useTabs) {
117
    if (useTabs) {
117
        painter->save();
118
        painter->save();
118
        Plasma::FrameSvg *decoration = m_theme->decoration();
119
        Plasma::FrameSvg *decoration = m_theme->decoration();
Lines 202-207 Link Here
202
        }
203
        }
203
    }
204
    }
204
    p.setPen(color);
205
    p.setPen(color);
206
    p.setFont(s->font(active));
205
    p.drawText(pix.rect(), align | conf.verticalAlignment() | Qt::TextSingleLine, m_caption);
207
    p.drawText(pix.rect(), align | conf.verticalAlignment() | Qt::TextSingleLine, m_caption);
206
    if (textRect.width() > w) {
208
    if (textRect.width() > w) {
207
        // Fade out effect
209
        // Fade out effect

Return to bug 352324