diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-05-01 21:46:34 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-05-01 21:46:34 +0300 |
commit | f466978d005e3a0e3148f304b075c6a9d9a2760b (patch) | |
tree | 00638e7409909197ffecabff9972f01ca5bee5d0 /src/defaults.cpp | |
parent | 1fc47e1877e156fa101ac80edc701d3a90059916 (diff) | |
download | ManaVerse-f466978d005e3a0e3148f304b075c6a9d9a2760b.tar.gz ManaVerse-f466978d005e3a0e3148f304b075c6a9d9a2760b.tar.bz2 ManaVerse-f466978d005e3a0e3148f304b075c6a9d9a2760b.tar.xz ManaVerse-f466978d005e3a0e3148f304b075c6a9d9a2760b.zip |
use different default font sizes depend on screen density.
Diffstat (limited to 'src/defaults.cpp')
-rw-r--r-- | src/defaults.cpp | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/src/defaults.cpp b/src/defaults.cpp index 1995d1ee6..6105e81d2 100644 --- a/src/defaults.cpp +++ b/src/defaults.cpp @@ -157,7 +157,6 @@ DefaultsData* getConfigDefaults() AddDEF("showownname", true); AddDEF("showpickupparticle", true); AddDEF("showpickupchat", true); - AddDEF("fontSize", 12); AddDEF("ReturnToggles", false); AddDEF("ScrollLaziness", 16); AddDEF("ScrollRadius", 0); @@ -282,7 +281,6 @@ DefaultsData* getConfigDefaults() AddDEF("hideErased", false); AddDEF("enableDelayedAnimations", true); AddDEF("enableCompoundSpriteDelay", true); - AddDEF("npcfontSize", 13); AddDEF("useAtlases", true); AddDEF("useTextureSampler", false); AddDEF("ministatussaved", 0); @@ -333,6 +331,24 @@ void getConfigDefaults2(DefaultsData *const configData) AddDEF("screenButtonsSize", 1); AddDEF("screenJoystickSize", 1); } + const int density = graphicsManager.getDensity(); + int size = 12; + switch (density) + { + case DENSITY_HIGH: + size = 13; + break; + case DENSITY_XHIGH: + size = 15; + break; + case DENSITY_XXHIGH: + size = 17; + break; + default: + break; + } + AddDEF("fontSize", size); + AddDEF("npcfontSize", size + 1); } DefaultsData* getBrandingDefaults() |