Skip to content

Commit 59d768b

Browse files
authored
Merge pull request #2567 from modelica/cleanup/font-markup
Clean up use of non-semantical macros for font selection
2 parents bd3fbc7 + 601c5fd commit 59d768b

26 files changed

+1408
-1617
lines changed

chapters/annotations.tex

Lines changed: 24 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,6 @@ \section{Annotations for Code Generation}\doublelabel{annotations-for-code-gener
222222
the output should generate an event when it changes.
223223
\end{nonnormative}
224224
\\ \hline
225-
226225
\end{longtable}
227226
\begin{lstlisting}[language=grammar]
228227
smoothOrder-annotation:
@@ -240,7 +239,7 @@ \section{Annotations for Code Generation}\doublelabel{annotations-for-code-gener
240239
\begin{nonnormative}
241240
This means that the function is at least C\textsuperscript{smoothOrder}. \lstinline!smoothOrder = 1! means that
242241
the function can be differentiated at least once in order that all output arguments are still continuous, provided
243-
the input arguments are continuous. If a tool needs the derivative of a function, e.g. for index reduction or to
242+
the input arguments are continuous. If a tool needs the derivative of a function, e.g.\ for index reduction or to
244243
compute an analytic Jacobian, the function can be differentiated analytically at least \lstinline!smoothOrder! times.
245244
\end{nonnormative}
246245

@@ -341,7 +340,7 @@ \section{Annotations for Graphical Objects}\doublelabel{annotations-for-graphica
341340
\end{nonnormative}
342341

343342
These Icon, Diagram, and Documentation annotations are only allowed
344-
directly in classes (e.g. not on components or connections). The allowed
343+
directly in classes (e.g.\ not on components or connections). The allowed
345344
annotations for a short class definition is the union of the allowed
346345
annotations in classes and on extends-clauses.
347346

@@ -395,7 +394,7 @@ \subsubsection{Coordinate Systems}\doublelabel{coordinate-systems}
395394
application may use a different default value of \lstinline!initialScale!.
396395

397396
The attribute \lstinline!grid! specifies the spacing between grid points which can
398-
be used by tools for alignment of points in the coordinate system, e.g. ``snap-to-grid''.
397+
be used by tools for alignment of points in the coordinate system, e.g.\ ``snap-to-grid''.
399398
Its use and default value is tool-dependent.
400399

401400
\begin{lstlisting}[language=modelica]
@@ -412,7 +411,7 @@ \subsubsection{Coordinate Systems}\doublelabel{coordinate-systems}
412411
\begin{lstlisting}[language=modelica]
413412
CoordinateSystem(extent = {{-10, -10}, {10, 10}});
414413
\end{lstlisting}
415-
i.e. a coordinate system with width 20 units and height 20 units.
414+
i.e.\ a coordinate system with width 20 units and height 20 units.
416415
\end{example}
417416

418417
The coordinate systems for the icon and diagram layers are by default
@@ -666,7 +665,7 @@ \subsection{Connections}\doublelabel{connections1}
666665
connection line. It has the following definition (\emph{it is not equal
667666
to the Text-primitive as part of graphics -- the differences are marked as bold lines}):
668667
% NOTE: Technically just the names - not the entire lines are marked in bold
669-
\begin{lstlisting}[language=modelica,escapechar=!,emph={horizontalAlignment,string,index}, emphstyle=\textbf]
668+
\begin{lstlisting}[language=modelica]
670669
record Text
671670
extends GraphicItem;
672671
extends FilledShape;
@@ -862,7 +861,7 @@ \subsubsection{Text}\doublelabel{text}
862861
\item
863862
\%\% replaced by \%
864863
\item
865-
\%name replaced by the name of the component (i.e. the identifier for
864+
\%name replaced by the name of the component (i.e.\ the identifier for
866865
it in in the enclosing class).
867866
\item
868867
\%class replaced by the name of the class (only the last part of the hierarchical name).
@@ -1129,7 +1128,7 @@ \section{Annotations for the Graphical User Interface}\doublelabel{annotations-f
11291128
definition of "structurally inconsistent" see the article:
11301129
\href{http://epubs.siam.org/doi/abs/10.1137/0909014}{Pantelides C.C.:
11311130
The Consistent Initialization of Differential-Algebraic Systems, SIAM
1132-
J. Sci. and Stat. Comput. Volume 9, Issue 2, pp. 213--231 (March
1131+
J.\ Sci.\ and Stat.\ Comput.\ Volume 9, Issue 2, pp. 213--231 (March
11331132
1988)}}. A "default connection" is constructed by instantiating the
11341133
respective \lstinline!model! or \lstinline!block! and for every input \lstinline!u! providing an equation
11351134
\lstinline!0=f(u)!, and for every (potential,flow) pair of the form \lstinline!(v,i)!, providing
@@ -1539,7 +1538,7 @@ \subsubsection{Conversion rules}\doublelabel{conversion-rules}
15391538
corresponding to the old version.
15401539

15411540
\begin{nonnormative}
1542-
Whenever possible tools should preserve the original style of the model, e.g. use of imports.
1541+
Whenever possible tools should preserve the original style of the model, e.g.\ use of imports.
15431542
\end{nonnormative}
15441543

15451544
These functions can be called with literal strings or array of strings
@@ -1550,7 +1549,7 @@ \subsubsection{Conversion rules}\doublelabel{conversion-rules}
15501549
conversions of base-classes will require multiple conversion-calls; this
15511550
ensures that the conversion is independent of the new library structure.
15521551
The class-name used as argument to \lstinline!convertElement! and \lstinline!convertModifiers!
1553-
is similarly the old name of the class, i.e. the name before it is
1552+
is similarly the old name of the class, i.e.\ the name before it is
15541553
possibly converted by \lstinline!convertClass!.
15551554

15561555
\begin{nonnormative}
@@ -1588,7 +1587,7 @@ \subsubsection{Conversion rules}\doublelabel{conversion-rules}
15881587

15891588
The old element should be of a \lstinline!Boolean!, \lstinline!Integer!, \lstinline!String!, or enumeration
15901589
type and the match is based on the literal value of the modifier.
1591-
For string elements the value argument to \lstinline!convertClassIf! shall be up-quoted, e.g. \lstinline!"\"My String\""!,
1590+
For string elements the value argument to \lstinline!convertClassIf! shall be up-quoted, e.g.\ \lstinline!"\"My String\""!,
15921591
and for enumeration literals only the enumeration literal part of the old value matters, e.g., \lstinline!red!
15931592
for \lstinline!"Colors.red"!.
15941593

@@ -1689,7 +1688,7 @@ \subsubsection{Conversion rules}\doublelabel{conversion-rules}
16891688
connector \lstinline!B! is connected, there will be a parameter for enabling connector \lstinline!B!, and the conversion ensures that
16901689
each component of model \lstinline!A! will have this parameter set accordingly.
16911690

1692-
In case a parameter is simply renamed it is preferable to use \lstinline!convertElement!, since that also handles e.g. binding equations
1691+
In case a parameter is simply renamed it is preferable to use \lstinline!convertElement!, since that also handles e.g.\ binding equations
16931692
using the parameter.
16941693
\end{nonnormative}
16951694

@@ -1852,7 +1851,7 @@ \subsection{Version Date and Build Information}\doublelabel{version-date-and-bui
18521851
\end{nonnormative}
18531852
\item
18541853
\lstinline!revisionId! is a tool specific revision identifier
1855-
possibly generated by a source code management system (e.g. Subversion
1854+
possibly generated by a source code management system (e.g.\ Subversion
18561855
or CVS). This information allows to exactly identify the library
18571856
source code in the source code management system.
18581857
\end{itemize}
@@ -1892,32 +1891,29 @@ \section{Annotations for Access Control to Protect Intellectual Property}\double
18921891
different encryption formats.
18931892
\end{nonnormative}
18941893

1895-
\textbf{Definitions:}
1894+
Definitions:
18961895
\begin{longtable}[]{|p{2.5cm}|p{12cm}|}
18971896
\hline
18981897
\tablehead{Term} & \tablehead{Description}\\ \hline
18991898
\endhead
1900-
\textbf{Protection} & Define what parts of a class are visible.\\
1899+
\firstuse{Protection} & Define what parts of a class are visible.\\
19011900
\hline
1902-
\textbf{Obfuscation} & Changing a Modelica class or generated code so that it is difficult to inspect by a user
1903-
(e.g. by automatically renaming variables to non-meaningful names).\\
1901+
\firstuse{Obfuscation} & Changing a Modelica class or generated code so that it is difficult to inspect by a user
1902+
(e.g.\ by automatically renaming variables to non-meaningful names).\\
19041903
\hline
1905-
\textbf{Encryption} & Encoding of a model or a package in a form so that
1904+
\firstuse{Encryption} & Encoding of a model or a package in a form so that
19061905
the modeler cannot inspect any content of a class without an appropriate
19071906
key. An encrypted package that has the \lstinline!Protection! annotation is
19081907
read-only; the way to modify it is to generate a new encrypted version.\\
19091908
\hline
1910-
\textbf{Licensing} & Restrict the use of an encrypted package for particular users for a specified period of time.\\
1909+
\firstuse{Licensing} & Restrict the use of an encrypted package for particular users for a specified period of time.\\
19111910
\hline
1912-
19131911
\end{longtable}
19141912

1915-
In this section annotations are defined for protection and
1916-
licensing. Obfuscation and encryption are not standardized.
1917-
protection and licensing are both defined inside the
1918-
\lstinline!Protection! annotation:
1919-
\begin{lstlisting}[language=modelica]
1920-
annotation(Protection(...));
1913+
In this section annotations are defined for protection and licensing. Obfuscation and encryption are not standardized.
1914+
Protection and licensing are both defined inside the \lstinline!Protection! annotation:
1915+
\begin{lstlisting}[language=modelica,mathescape=true]
1916+
annotation(Protection($\ldots$));
19211917
\end{lstlisting}
19221918

19231919
\subsection{Protection of Classes}\doublelabel{protection-of-classes}
@@ -1969,7 +1965,7 @@ \subsection{Protection of Classes}\doublelabel{protection-of-classes}
19691965
the class, or part of the class, can be copied.
19701966
\item
19711967
\lstinline!Access.packageText!\\
1972-
Same as \lstinline!Access.diagram! (note: \textbf{not} including all rights of
1968+
Same as \lstinline!Access.diagram! (note: \emph{not} including all rights of
19731969
\lstinline!Access.nonPackageDuplicate!) and additionally the whole class
19741970
definition can be accessed (but that text cannot be copied, i.e., you can see but not copy the source code).
19751971
\item
@@ -2090,7 +2086,7 @@ \subsection{Licensing}\doublelabel{licensing}
20902086

20912087
record License
20922088
String licensee ="" "Optional string to show information about the licensee";
2093-
String id[:] "Unique machine identifications, e.g. MAC addresses";
2089+
String id[:] "Unique machine identifications, e.g.\ MAC addresses";
20942090
String features[:] =fill("", 0) "Activated library license features";
20952091
String startDate ="" "Optional start date in UTCformat YYYY-MM-DD";
20962092
String expirationDate="" "Optional expiration date in UTCformat YYYY-MM-DD";

0 commit comments

Comments
 (0)