add textScale global to CanvasAdapter - should replace 'dpi'

This commit is contained in:
Hannes Janetzek 2013-08-10 11:05:31 +02:00
parent a86abf2921
commit 4ce228bdf2
2 changed files with 2 additions and 1 deletions

View File

@ -26,6 +26,7 @@ public abstract class CanvasAdapter {
public static CanvasAdapter g;
public static float dpi = 240;
public static float textScale = 1;
public enum Color {
BLACK, CYAN, TRANSPARENT, WHITE;

View File

@ -54,7 +54,7 @@ public class ThemeLoader {
try {
inputStream = theme.getRenderThemeAsStream();
IRenderTheme t = RenderThemeHandler.getRenderTheme(inputStream);
t.scaleTextSize(1 + (CanvasAdapter.dpi / 240 - 1) * 0.5f);
t.scaleTextSize(CanvasAdapter.textScale + (CanvasAdapter.dpi / 240 - 1) * 0.5f);
return t;
} catch (IOException e) {