diff --git a/source/frontend/StarChat.cpp b/source/frontend/StarChat.cpp index 236d207..4af8930 100644 --- a/source/frontend/StarChat.cpp +++ b/source/frontend/StarChat.cpp @@ -274,13 +274,13 @@ void Chat::renderImpl() { m_chatLog->drawImage(m_portraitBackground, Vec2F(imagePosition), 1.0f, fade); m_chatLog->drawImage(message.portrait, Vec2F(imagePosition + m_portraitImageOffset), m_portraitScale, fade); tp.pos += Vec2F(0, floor(messageHeight / 2)); - m_chatLog->drawText(messageString, tp, m_fontSize, fade, FontMode::Normal, m_chatLineHeight, m_fontDirectives); + m_chatLog->drawText(messageString, tp, m_fontSize, fade, FontMode::Normal, m_chatLineHeight, m_font, m_fontDirectives); } else { TextPositioning tp = {Vec2F(chatMin), HorizontalAnchor::LeftAnchor, VerticalAnchor::BottomAnchor, wrapWidth}; messageHeight = guiContext.determineInterfaceTextSize(messageString, tp).size()[1] + lineHeightMargin; - m_chatLog->drawText(messageString, tp, m_fontSize, fade, FontMode::Normal, m_chatLineHeight, m_fontDirectives); + m_chatLog->drawText(messageString, tp, m_fontSize, fade, FontMode::Normal, m_chatLineHeight, m_font, m_fontDirectives); } chatMin[1] += ceil(messageHeight); diff --git a/source/frontend/StarChatBubbleManager.cpp b/source/frontend/StarChatBubbleManager.cpp index c72b1a6..ab45faf 100644 --- a/source/frontend/StarChatBubbleManager.cpp +++ b/source/frontend/StarChatBubbleManager.cpp @@ -197,6 +197,7 @@ void ChatBubbleManager::addChatActions(List chatActions, bool silent // yea I agree m_guiContext->setFontSize(m_fontSize, m_zoom); + m_guiContext->setFontProcessingDirectives(""); m_guiContext->setDefaultFont(); auto result = m_guiContext->determineTextSize(sayAction.text, m_textTemplate); float textWidth = result.width() / m_zoom + m_textPadding[0]; @@ -334,6 +335,8 @@ void ChatBubbleManager::drawBubbleText(Vec2F screenPos, BubbleText const& bubble // use the alpha as a blend value for the text colour as pulled from data. Vec4B const& displayColor = Vec4B(baseColor[0], baseColor[1], baseColor[2], (baseColor[3] * alpha) / 255); + m_guiContext->setDefaultFont(); + m_guiContext->setFontProcessingDirectives(""); m_guiContext->setFontColor(displayColor); m_guiContext->setFontSize(get<1>(bubbleText), m_zoom); diff --git a/source/frontend/StarNameplatePainter.cpp b/source/frontend/StarNameplatePainter.cpp index ef472d4..d7e589a 100644 --- a/source/frontend/StarNameplatePainter.cpp +++ b/source/frontend/StarNameplatePainter.cpp @@ -102,6 +102,9 @@ void NameplatePainter::render() { context.renderText(*nametag.statusText, statusPosition(bubble.currentPosition)); } + + context.setDefaultFont(); + context.setFontProcessingDirectives(""); }); }