mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-04 02:42:49 -04:00
text-default-underscore-height
This commit is contained in:
parent
f2102c5912
commit
1ccecd7231
@ -168,6 +168,11 @@ ConfigVariableInt text_max_never_break
|
||||
"characters in a row, do not treat any of them as special and "
|
||||
"instead break the line wherever we can."));
|
||||
|
||||
ConfigVariableDouble text_default_underscore_height
|
||||
("text-default-underscore-height", -0.2,
|
||||
PRC_DESC("Specifies the default height of the underscore line, relative "
|
||||
"to the text baseline, when underscoring is enabled."));
|
||||
|
||||
ConfigVariableEnum<Texture::FilterType> text_minfilter
|
||||
("text-minfilter", Texture::FT_linear_mipmap_linear,
|
||||
PRC_DESC("The default texture minfilter type for dynamic text fonts"));
|
||||
|
@ -47,6 +47,7 @@ extern wstring get_text_soft_hyphen_output();
|
||||
extern ConfigVariableDouble text_hyphen_ratio;
|
||||
extern wstring get_text_never_break_before();
|
||||
extern ConfigVariableInt text_max_never_break;
|
||||
extern ConfigVariableDouble text_default_underscore_height;
|
||||
|
||||
extern ConfigVariableEnum<Texture::FilterType> text_minfilter;
|
||||
extern ConfigVariableEnum<Texture::FilterType> text_magfilter;
|
||||
|
@ -346,7 +346,7 @@ has_underscore_height() const {
|
||||
////////////////////////////////////////////////////////////////////
|
||||
INLINE float TextProperties::
|
||||
get_underscore_height() const {
|
||||
return _underscore_height;
|
||||
return has_underscore_height() ? _underscore_height : text_default_underscore_height;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
Loading…
x
Reference in New Issue
Block a user