summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/isphysicalmath/isphysicalmath.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/isphysicalmath/isphysicalmath.sty')
-rw-r--r--Master/texmf-dist/tex/latex/isphysicalmath/isphysicalmath.sty66
1 files changed, 66 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/isphysicalmath/isphysicalmath.sty b/Master/texmf-dist/tex/latex/isphysicalmath/isphysicalmath.sty
new file mode 100644
index 00000000000..8de492a4f9d
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/isphysicalmath/isphysicalmath.sty
@@ -0,0 +1,66 @@
+%%
+%% This is file `isphysicalmath.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% isphysicalmath.dtx (with options: `package')
+%%
+%% This is a generated file.
+%%
+%% Copyright (C) 2023 by Mario Fantini <marfant7@gmail.com>
+%%
+%% This file may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.3 of this license
+%% or (at your option) any later version. The latest version of this
+%% license is in:
+%%
+%% http://www.latex-project.org/lppl.txt
+%%
+%% and version 1.3 or later is part of all distributions of LaTeX version
+%% 2005/12/01 or later.
+%%
+\NeedsTeXFormat{LaTeX2e}[2005/12/01]
+\ProvidesPackage{isphysicalmath}
+[2023/09/18 v1.0.0 .dtx isphysicalmath file]
+% option [dc]: changes dots in commas.
+\DeclareOption{dc}{
+\def\ispmdc#1.#2{{#1,#2}}
+}
+% option [comma]: scientific international notation for thousands.
+\DeclareOption{comma}{
+ \def\ispmnovem#1#2#3#4#5#6#7#8#9{#1#2#3,#4#5#6,#7#8#9}
+ \def\ispmocto#1#2#3#4#5#6#7#8{#1#2,#3#4#5,#6#7#8}
+ \def\ispmseptem#1#2#3#4#5#6#7{#1,#2#3#4,#5#6#7}
+ \def\ispmsex#1#2#3#4#5#6{#1#2#3,#4#5#6}
+ \def\ispmquinque#1#2#3#4#5{#1#2,#3#4#5}
+ \def\ispmquattuor#1#2#3#4{#1,#2#3#4}
+}
+\ExecuteOptions{dc}
+\ExecuteOptions{comma}
+\ProcessOptions\relax
+% space between value and measurement unit
+\newcommand{\ispms}{\hspace{0.5mm}}
+% normal text rendering for first measurement unit
+\newcommand{\ispmntone}[1]{\textnormal{#1}}
+% jolly: the default setting is --- normal text rendering for a generic 'entity'.
+% If you are a developer, you can modify it when and how you want.
+\newcommand{\ispm}[1]{\textnormal{#1}}
+% normal text rendering for first and second measurement units
+\newcommand{\ispmnttwo}[2]{\textnormal{#1}\textnormal{#2}}
+% space between first and second measurement units
+\newcommand{\ispmss}{\hspace{0.15mm}}
+% \ispm if you have only a measurement unit
+% e.g. $F = 20 \ispmone{N}$
+\newcommand{\ispmone}{\ispms\ispmntone}
+% \ispm if you have two measurement units
+% e.g. $L = 20 \ispmtwo{N}{m}$
+\newcommand{\ispmtwo}[2]{\ispms\ispmnttwo\ispmss{#1}\ispmnttwo\ispmss{#2}}
+% normal text rendering for third measurement unit
+\newcommand{\ispmntr}[1]{\textnormal{#1}}
+% ispm if you have three measurement units
+% e.g. $V = 8 \ispmtwo{m}{m}\ispmthird{m}$
+\newcommand{\ispmthird}[1]{\ispmss\ispmntr{#1}}
+\endinput
+%%
+%% End of file `isphysicalmath.sty'.