summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/scripts/lua-physical
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2020-09-09 21:00:13 +0000
committerKarl Berry <karl@freefriends.org>2020-09-09 21:00:13 +0000
commit8101eb6ec78d7b89a8678a82f5916c31964d822a (patch)
treeb67e105d12ced283e146979bf49b338b435d0434 /Master/texmf-dist/scripts/lua-physical
parent4a264bf091040319f9bc0a0564729de3a3bfdb11 (diff)
lua-physical (9sep20)
git-svn-id: svn://tug.org/texlive/trunk@56306 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/scripts/lua-physical')
-rw-r--r--Master/texmf-dist/scripts/lua-physical/physical-quantity.lua14
-rwxr-xr-xMaster/texmf-dist/scripts/lua-physical/physical.lua4
2 files changed, 9 insertions, 9 deletions
diff --git a/Master/texmf-dist/scripts/lua-physical/physical-quantity.lua b/Master/texmf-dist/scripts/lua-physical/physical-quantity.lua
index 47a02063c5d..d89fdd2836b 100644
--- a/Master/texmf-dist/scripts/lua-physical/physical-quantity.lua
+++ b/Master/texmf-dist/scripts/lua-physical/physical-quantity.lua
@@ -46,9 +46,9 @@ Quantity._base = {}
Quantity._prefixes = {}
-- modes for the function tosiunitx()
-Quantity.siunitx_SI = 0
-Quantity.siunitx_num = 1
-Quantity.siunitx_si = 2
+Quantity.SIUNITX_SI = 0
+Quantity.SIUNITX_num = 1
+Quantity.SIUNITX_si = 2
-- constructor
@@ -416,20 +416,20 @@ end
-- convert quantity to an siunitx expression
function Quantity:tosiunitx(param,mode)
- mode = mode or self.siunitx_SI
+ mode = mode or self.SIUNITX_SI
param = param or ""
if param ~= "" then
param = "["..param.."]"
end
- if mode == Quantity.siunitx_SI then
+ if mode == Quantity.SIUNITX_SI then
return "\\SI"..param.."{"..tostring(self.value).."}".."{"..self.unit:tosiunitx().."}"
- elseif mode == Quantity.siunitx_num then
+ elseif mode == Quantity.SIUNITX_num then
return "\\num"..param.."{"..tostring(self.value).."}"
- elseif mode == Quantity.siunitx_si then
+ elseif mode == Quantity.SIUNITX_si then
return "\\si"..param.."{"..self.unit:tosiunitx().."}"
else
diff --git a/Master/texmf-dist/scripts/lua-physical/physical.lua b/Master/texmf-dist/scripts/lua-physical/physical.lua
index 2af9d7677a3..8c8d30171b8 100755
--- a/Master/texmf-dist/scripts/lua-physical/physical.lua
+++ b/Master/texmf-dist/scripts/lua-physical/physical.lua
@@ -3,8 +3,8 @@
lua-physical
Author: Thomas Jenni
-Version: 1.0.2
-Date: 2020-09-07
+Version: 1.0.3
+Date: 2020-09-09
License: MIT