aboutsummaryrefslogtreecommitdiff
path: root/plugins/scale.lua
diff options
context:
space:
mode:
authorrxi <rxi@users.noreply.github.com>2020-06-03 14:38:02 +0100
committerrxi <rxi@users.noreply.github.com>2020-06-03 14:38:02 +0100
commit2a8e8fa228e0dda6d993a8dfe7be4ad16911227b (patch)
tree35347a2ee446df2d50de8eb4ff4c92e5c84f90cb /plugins/scale.lua
parent18cee87818658c49167123677c978c16c9d7318c (diff)
downloadlite-xl-plugins-2a8e8fa228e0dda6d993a8dfe7be4ad16911227b.tar.gz
lite-xl-plugins-2a8e8fa228e0dda6d993a8dfe7be4ad16911227b.zip
Fixed `scale` plugin for non-default initial SCALE
Diffstat (limited to 'plugins/scale.lua')
-rw-r--r--plugins/scale.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/scale.lua b/plugins/scale.lua
index 52ac73b..4fd82cc 100644
--- a/plugins/scale.lua
+++ b/plugins/scale.lua
@@ -47,8 +47,10 @@ local function set_scale(scale)
end
+local default = SCALE
+
command.add(nil, {
- ["scale:reset" ] = function() set_scale(1) end,
+ ["scale:reset" ] = function() set_scale(default) end,
["scale:decrease"] = function() set_scale(SCALE * 0.9) end,
["scale:increase"] = function() set_scale(SCALE * 1.1) end,
})