summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/bxcalc/bxcalc.sty
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/bxcalc/bxcalc.sty')
-rw-r--r--macros/latex/contrib/bxcalc/bxcalc.sty51
1 files changed, 51 insertions, 0 deletions
diff --git a/macros/latex/contrib/bxcalc/bxcalc.sty b/macros/latex/contrib/bxcalc/bxcalc.sty
new file mode 100644
index 0000000000..3336088f5b
--- /dev/null
+++ b/macros/latex/contrib/bxcalc/bxcalc.sty
@@ -0,0 +1,51 @@
+%%
+%% This is file 'bxcalc.sty'.
+%%
+%% Copyright (c) 2018-2020 Takayuki YATO (aka. "ZR")
+%% GitHub: https://github.com/zr-tex8r
+%% Twitter: @zr_tex8r
+%%
+%% This package is distributed under the MIT License.
+%%
+
+%% package declaration
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{bxcalc}[2020/09/25 v1.1]
+\def\bxqcz@pkgname{bxcalc}
+
+%--------------------------------------- main
+
+%% packages
+\RequirePackage{calc}[]
+\@ifl@t@r\fmtversion{2020/10/01}{}{%else
+ \RequirePackage{bxcalcize}[2017/05/21]% v1.0
+}
+\RequirePackage{bxcalcux}[2017/05/21]% v1.0
+
+%--------------------------------------- \usepTeXunits
+
+\ifundef{\kanjiskip}{%
+ \newrobustcmd*{\usepTeXunits}{%
+ \DeclareCalcUnit{Q}{\dimexpr0.25mm\relax}%
+ \DeclareCalcUnit{H}{\dimexpr0.25mm\relax}%
+ \DeclareCalcUnit{trueQ}{\dimexpr0.25truemm\relax}%
+ \DeclareCalcUnit{trueH}{\dimexpr0.25truemm\relax}%
+ \ifdef{\zw}{%
+ \DeclareCalcUnit{zw}{\zw}%%
+ \DeclareCalcUnit{zh}{\zw}%
+ }{\ifdef{\jsZw}{%
+ \DeclareCalcUnit{zw}{\jsZw}%%
+ \DeclareCalcUnit{zh}{\jsZw}%
+ }{}}%
+ \ifdef{\zh}{%
+ \DeclareCalcUnit{zh}{\zh}%
+ }{}%
+ \let\usepTeXunits\relax
+ }%
+}{%else
+ \newrobustcmd*{\usepTeXunits}{}%
+}
+
+%--------------------------------------- all done
+\endinput
+%% EOF