Skip to content

Commit

Permalink
Be clearer about showStartAttributes.
Browse files Browse the repository at this point in the history
  • Loading branch information
HansOlsson committed Nov 6, 2024
1 parent 2c2df56 commit 70d40a5
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion chapters/annotations.tex
Original file line number Diff line number Diff line change
Expand Up @@ -1450,7 +1450,7 @@ \section{Graphical User Interface}\label{annotations-for-the-graphical-user-inte
/*literal*/ constant String tab = "General";
/*literal*/ constant String group = "";
/*evaluable*/ parameter Boolean enable = true;
/*literal*/ constant Boolean showStartAttribute = false;
/*literal*/ constant Boolean showStartAttribute;
/*literal*/ constant Boolean colorSelector = false;
/*literal*/ constant Selector loadSelector;
/*literal*/ constant Selector saveSelector;
Expand All @@ -1465,6 +1465,7 @@ \section{Graphical User Interface}\label{annotations-for-the-graphical-user-inte
end Selector;
\end{lstlisting}%
\annotationindex{Dialog}
Modifiable parameters (except for \lstinline!connectorSizing = true!), non-connector inputs, and short replace class definitions should normally be shown even in the parameter dialog even without this annotation.

For a short replaceable class definition only the fields \lstinline!tab!, \lstinline!group!, \lstinline!enable! and \lstinline!groupImage! are allowed.

Expand All @@ -1486,6 +1487,8 @@ \section{Graphical User Interface}\label{annotations-for-the-graphical-user-inte
The \lstinline!showStartAttribute = true! is primarily intended for non-parameter values and avoids introducing a separate parameter for the \lstinline!start!-attribute of the variable.
\end{nonnormative}

If the declaration has a modifier for the \lstinline!start!-attribute and does not have \lstinline!showStartAttribute = false! the \lstinline!start!- and \lstinline!fixed!-attributes shall also be shown.

If \lstinline!colorSelector = true!, it suggests the use of a color selector to pick an \textsc{rgb} color as a vector of three values in the range 0..255 (the color selector should be useable both for vectors of \lstinline!Integer! and \lstinline!Real!).

The presence of \lstinline!loadSelector! or \lstinline!saveSelector! specifying \fmtannotationindex{Selector} suggests the use of a file dialog to select a file.
Expand All @@ -1504,6 +1507,7 @@ \section{Graphical User Interface}\label{annotations-for-the-graphical-user-inte
The background of the \lstinline!groupImage! and any image used in HTML-documentation is recommended to be transparent (intended to be a light color) or white.

The \lstinline!connectorSizing! is described separately in \cref{connector-sizing}.
A dialog annotation only containing \lstinline!showStartAttribute = false! and/or \lstinline!connectorSizing = true! does not indicate that the variable shall be shown.

\begin{example}
\begin{lstlisting}[language=modelica]
Expand Down

0 comments on commit 70d40a5

Please sign in to comment.