refactor: Font index cleanup

This commit is contained in:
Michael Carlberg 2016-12-20 15:09:11 +01:00
parent 8ef8900ca2
commit c14c46b998
8 changed files with 40 additions and 49 deletions
src/components

View file

@ -566,13 +566,13 @@ bool renderer::on(const change_overline& evt) {
}
bool renderer::on(const change_font& evt) {
int8_t font{*evt()};
uint8_t font{*evt()};
if (m_fontindex == font) {
m_log.trace_x("renderer: ignoring unchanged font index(%i)", static_cast<int8_t>(font));
m_log.trace_x("renderer: ignoring unchanged font index(%i)", static_cast<uint8_t>(font));
} else {
m_log.trace_x("renderer: set_fontindex(%i)", static_cast<int8_t>(font));
m_fontmanager->set_preferred_font(font);
m_log.trace_x("renderer: fontindex(%i)", static_cast<uint8_t>(font));
m_fontmanager->fontindex(font);
m_fontindex = font;
}