Inconsistent paddigns

+1 vote
asked Oct 26, 2024 in Bug by index (120 points)

Hi! There are several issues I observed and want to address:

1. No horizontal paddings in a mainframe heading

2. Different left and right paddings for a group heading

3. Wrong alignment of icons (they should be higher, with less top padding)

Thank you for you work, I really appreciate it and I can’t imagine building diagrams without PlantUML!

commented Oct 27, 2024 by kirchsth (7,600 points)
HI @index,

a) can you add the source?
b) do you have the problems with png or svg output?

Thank you
Helmut
commented Oct 27, 2024 by index (120 points)
edited Oct 27, 2024 by index

Hi kirchsth,

I am sorry, some styles were left in the diagram I shared, but still the paddings were not changed after removing the styles.

a)

@startuml

mainframe Mainframe heading

participant "<&person> Customer" as cust #SeaShell

participant "<&task> Dashboard" as dash #Azure

opt

note over cust

Test

end note

end opt

break

note over cust

Test

end note

end break

@enduml

b) Both. Updated PNG:


SVG (screenshot):

Here the vertical alignment of icons is also wrong, but now icons are higher than the text mean line (it was vice versa in the first example with custom styles)

1 Answer

0 votes
answered Oct 27, 2024 by kirchsth (7,600 points)

Hi @index,

my first idea was that it could be a (missing) font problem, but this doesn't seem to be the problem (If this would be the case then the png is typically correct and the svg is wrong based on a font mismatch with the e.g. browser).

I have no real fix for the mainframe (I assume it has a complete different implementation) but there is a workaround:  You could use a bold text with additional spaces `**<U+0020>  Mainframe heading     **` and with the spaces you  can make the padding (the image has a link with the source; I need the bold marker that the additional spaces are considered).

https://www.plantuml.com/plantuml/uml/ZO-zYiD038HxFOMmuGfVOwusniTTcyh90yXU9Lxi_K6xJf6dZxA45AcYGimCtmWqf4oITxU18-lFGewnQRhJTzl-j3tYuPKkJCRw2-ee0H2rPsSRoMUikg_8aeBlyMzFEJYM2YdXh0RhaMbSUDlUAvdIskC_fMKA9AOqZ3giVs-xC4286S27p1YkBEKQ75aNUuEF78egs2HCwoVq4nnKwzjt
BR Helmut

PS.: with following `mainframe <U+0020>   Mainframe heading     <U+0020>` you can avoid the bold layout too

commented Oct 27, 2024 by index (120 points)
Hi kirchsth,

Thank you for your effort, it really helps as a temporary solution, and I will use it! However, I want this issue to be fixed on the app side, if possible.
...