Add FORCE_PIXELS option to force pixels vs. display pixels
diff --git a/templates/base.html b/templates/base.html
index 0278677..10cce88 100644
--- a/templates/base.html
+++ b/templates/base.html
@@ -10,7 +10,7 @@
<link href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.min.css" rel="stylesheet">
<meta charset="utf-8" />
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
+ <meta name="viewport" id="viewport" content="width=device-width, initial-scale=1.0">
<meta name="author" content="{{ AUTHOR }}">
<meta name="description" content="Posts and writings by {{ AUTHOR }}">
@@ -102,5 +102,15 @@
}
</script>
{% endif %}
+
+ {% if FORCE_PIXELS %}
+ <script type="text/javascript">
+ var ratio = 1/window.devicePixelRatio;
+ var tag = document.getElementById("viewport")
+ if (ratio != 1 && tag != null){
+ tag.content = "width=device-width, initial-scale=" + ratio;
+ }
+ </script>
+ {% endif %}
</body>
</html>