GuiCharacter: Consider default settings for underline, strikeout and language

This commit is contained in:
Juergen Spitzmueller 2018-12-17 10:12:02 +01:00
parent f87218bbb5
commit bf2bf2eaed

View File

@ -348,6 +348,9 @@ FontState getBar(FontInfo const & fi)
if (fi.underbar() == FONT_IGNORE)
return IGNORE;
if (fi.underbar() == FONT_INHERIT)
return INHERIT;
return NONE;
}
@ -363,6 +366,9 @@ FontState getStrike(FontInfo const & fi)
if (fi.strikeout() == FONT_IGNORE)
return IGNORE;
if (fi.strikeout() == FONT_INHERIT)
return INHERIT;
return NONE;
}
@ -447,6 +453,10 @@ void GuiCharacter::updateContents()
} else
font_ = bufferview()->cursor().current_font;
// If we use the buffer language, display "Default"
if (font_.language() == buffer().params().language)
font_.setLanguage(reset_language);
paramsToDialog(font_);
}