tikz\latex: Scaling

0 votes
asked May 27 in Bug by JLo (120 points)
edited May 27 by JLo

If I reduce the size of the created figure, I need to increase the text size of PlantUML.
The following statement inside @startuml leads to smaller text but increases the rectangles. 

skinparam defaultFontSize 25

Using a size like 5 does the opposite. It changes the font size to a bigger font than normal  but the rectangles are decreasing and the text doesn't fit anymore to the boxes.

\begin{figure}[H]
  \centering
  \begin{subfigure}[b]{0.20\linewidth}
    \catcode`\#12
    \begin{plantuml}
      @startuml
      skinparam defaultFontSize 5
      start
      if (Number) is ( < 5 ) then
        :Number++;
      endif
      stop
      @enduml
    \end{plantuml}
    \catcode`\#13
  \end{subfigure}
\end{figure}

Thanx in advance

commented May 27 by albert (3,120 points)

In the presented example there are 2 components

- TIKZ / LaTeX

- plantuml

Here we should concentrate us on the plantuml part:

      @startuml
      skinparam defaultFontSize 5
      start
      if (Number) is ( < 5 ) then
        :Number++;
      endif
      stop
      @enduml

When running this on http://www.plantuml.com/plantuml/uml/Km03X-AInAAIqjmSBWY_E3ipho2nA35N8IKrBR4qfyGjFwyaEBCgLS4KgWAi0ShEJ5FGy2lDJKejqbJ8B5RGKB1HC5NGL2Z9ICtZKe02AuW2RMrhg51gNafc6jom_08eqm4e3dG70000

The size of the box looks like to be decreased (maybe not as much as expected though). When changing the fontsize  to 25 is looks all larger (and correct size, as it does when the complete skinparameter is removed.

So this all looks OK in my opinion when using version 1.2021.7.

Which version do you use:

@startuml

version

@enduml
commented May 27 by The-Lu (36,540 points)
edited May 27 by The-Lu

Hello all,

Here are all the combinations:

defaultFontSize 5defaultFontSize 25normal size
no scale
scale .5

Then perhaps the better small image is with:

scale .5
skinparam defaultFontSize 25

If that can help,
Regards,
Th.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:

[Antispam2 Feature: please please wait 1 or 2 minutes (this message will disappear) before pressing the button otherwise it will fail](--------)
To avoid this verification in future, please log in or register.
...