Navigation Menu

Skip to content

Commit

Permalink
Fixed|UI|Client: Applying text styles before widget initialized
Browse files Browse the repository at this point in the history
  • Loading branch information
skyjake committed Sep 19, 2013
1 parent 8b85191 commit 805c99a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion doomsday/client/src/ui/framework/textdrawable.cpp
Expand Up @@ -151,9 +151,12 @@ void TextDrawable::init(Atlas &atlas, Font const &font, Font::RichFormat::IStyle

setAtlas(atlas);
if(style)
{
{
d->frontWrap->format.setStyle(*style);
d->backWrap->format.setStyle(*style);

// Previously defined text should be restyled, now.
d->backWrap->plainText = d->backWrap->format.initFromStyledText(d->backWrap->text);
}
GLTextComposer::setText(d->backWrap->plainText, d->backWrap->format);
setFont(font);
Expand Down
2 changes: 1 addition & 1 deletion doomsday/libdeng2/include/de/libdeng2.h
Expand Up @@ -78,6 +78,7 @@
#ifdef DENG2_USE_QT
# include <QtCore/qglobal.h>
# include <QScopedPointer>
# include <QDebug>

// Qt versioning helper. Qt 4.7 is the oldest we support.
# if (QT_VERSION <= QT_VERSION_CHECK(4, 6, 0))
Expand Down Expand Up @@ -136,7 +137,6 @@
# define DENG2_DEBUG
# ifdef DENG2_USE_QT
# define DENG2_ASSERT(x) Q_ASSERT(x)
# include <QDebug>
# else
# define DENG2_ASSERT(x) assert(x)
# endif
Expand Down

0 comments on commit 805c99a

Please sign in to comment.