about summary refs log tree commit diff stats
path: root/source_edit.lua
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2022-09-07 10:20:19 -0700
committerKartik K. Agaram <vc@akkartik.com>2022-09-07 10:20:19 -0700
commit81b0646ec1c3f9deae5e4b2c0b538102aa973a6e (patch)
tree2a933c4945f3d27a97f65c31ffcfa3b15fcd2f20 /source_edit.lua
parent326eca796dbe42af8e3a2a3d623a052c4669fb9a (diff)
parent901dd1fd945588c3c8334ca86d57726911c3a908 (diff)
downloadview.love-81b0646ec1c3f9deae5e4b2c0b538102aa973a6e.tar.gz
Merge text.love
Diffstat (limited to 'source_edit.lua')
-rw-r--r--source_edit.lua5
1 files changed, 4 insertions, 1 deletions
diff --git a/source_edit.lua b/source_edit.lua
index a65537d..bcb1297 100644
--- a/source_edit.lua
+++ b/source_edit.lua
@@ -515,14 +515,17 @@ end
 
 --== some methods for tests
 
+-- Insulate tests from some key globals so I don't have to change the vast
+-- majority of tests when they're modified for the real app.
 Test_margin_left = 25
+Test_margin_right = 0
 
 function edit.initialize_test_state()
   -- if you change these values, tests will start failing
   return edit.initialize_state(
       15,  -- top margin
       Test_margin_left,
-      App.screen.width,  -- right margin = 0
+      App.screen.width - Test_margin_right,
       14,  -- font height assuming default LÖVE font
       15)  -- line height
 end