diff options
Diffstat (limited to 'linden/indra')
-rw-r--r-- | linden/indra/llrender/llfontregistry.cpp | 10 | ||||
-rw-r--r-- | linden/indra/newview/app_settings/settings.xml | 22 |
2 files changed, 31 insertions, 1 deletions
diff --git a/linden/indra/llrender/llfontregistry.cpp b/linden/indra/llrender/llfontregistry.cpp index 9792a91..c5923cd 100644 --- a/linden/indra/llrender/llfontregistry.cpp +++ b/linden/indra/llrender/llfontregistry.cpp | |||
@@ -442,7 +442,15 @@ LLFontGL *LLFontRegistry::createFont(const LLFontDescriptor& desc) | |||
442 | std::string font_path = local_path + *file_name_it; | 442 | std::string font_path = local_path + *file_name_it; |
443 | BOOL is_fallback = !is_first_found; | 443 | BOOL is_fallback = !is_first_found; |
444 | F32 size_mult = (is_fallback ? 1 : match_desc->getSizeMult()); | 444 | F32 size_mult = (is_fallback ? 1 : match_desc->getSizeMult()); |
445 | F32 size = (F32)llround(point_size * size_mult); | 445 | if (gSavedSettings.getF32("FontSizeMultiplier") > 0) |
446 | { | ||
447 | size_mult *= gSavedSettings.getF32("FontSizeMultiplier"); | ||
448 | } | ||
449 | F32 size = (F32)(point_size * size_mult); | ||
450 | if (gSavedSettings.getBOOL("FontSizeRounding")) | ||
451 | { | ||
452 | size = (F32)llround(size); | ||
453 | } | ||
446 | if (!fontp->loadFace(font_path, size, | 454 | if (!fontp->loadFace(font_path, size, |
447 | LLFontGL::sVertDPI, LLFontGL::sHorizDPI, 2, is_fallback)) | 455 | LLFontGL::sVertDPI, LLFontGL::sHorizDPI, 2, is_fallback)) |
448 | { | 456 | { |
diff --git a/linden/indra/newview/app_settings/settings.xml b/linden/indra/newview/app_settings/settings.xml index 8c280d4..7b37bb6 100644 --- a/linden/indra/newview/app_settings/settings.xml +++ b/linden/indra/newview/app_settings/settings.xml | |||
@@ -396,6 +396,28 @@ | |||
396 | <key>Value</key> | 396 | <key>Value</key> |
397 | <string>DroidSans</string> | 397 | <string>DroidSans</string> |
398 | </map> | 398 | </map> |
399 | <key>FontSizeMultiplier</key> | ||
400 | <map> | ||
401 | <key>Comment</key> | ||
402 | <string>Multiply all font sizes by this amount. Requires viewer restart.</string> | ||
403 | <key>Persist</key> | ||
404 | <integer>1</integer> | ||
405 | <key>Type</key> | ||
406 | <string>F32</string> | ||
407 | <key>Value</key> | ||
408 | <string>1.0</string> | ||
409 | </map> | ||
410 | <key>FontSizeRounding</key> | ||
411 | <map> | ||
412 | <key>Comment</key> | ||
413 | <string>Round all font sizes to integer values, to potentially reduce font blurriness. The rounding occurs after FontSizeMultiplier is applied. Requires viewer restart.</string> | ||
414 | <key>Persist</key> | ||
415 | <integer>1</integer> | ||
416 | <key>Type</key> | ||
417 | <string>Boolean</string> | ||
418 | <key>Value</key> | ||
419 | <integer>0</integer> | ||
420 | </map> | ||
399 | <key>GoAction</key> | 421 | <key>GoAction</key> |
400 | <map> | 422 | <map> |
401 | <key>Comment</key> | 423 | <key>Comment</key> |