Participant text overflows from the right of its box

0 votes
asked Jun 16, 2019 in Bug by Slyver (160 points)

Here's an example:

@startuml

autonumber

actor User
participant Server

box "Filter Chain"
    participant "Delegating Filter Proxy" as F1
    participant "Filter 1" as F2
    participant "Filter ..." as F3
    participant "Filter n" as F4
end box

participant DispatcherServlet as DS
participant Controller

User -> Server : request
Server -> F1 : request
F1 -> F2
F2 -> F3
F3 -> F4
F4 -> DS
DS -> Controller

autonumber stop

Controller -->> DS
DS -->> F4
F4 -->> F3
F3 -->> F2
F2 -->> F1
F1 -->> Server
Server -->> User

@enduml

It is rendered like this: https://imgur.com/a/T3CQ065 (see Delegating Filter Proxy and DispatcherServlet participants).

name overflows box

Using skinparam padding is not an option here, as it will deform the box (too much whitespace on the left, top, and bottom and very little on the right).

Dot version:  

$ dot -V
dot - graphviz version 2.40.1 (20161225.0304)

commented Jun 16, 2019 by albert (3,520 points)
edited Jun 17, 2019 by albert
I tried it with the plantuml web service and got the result (though with graphviz 2.38.0):

http://www.plantuml.com/plantuml/uml/TP71QiCm38RlUWgHUmjfSjgX51fy7eGzW9EArk3QcQsCxErdLO6cZEQIBz8NYzywPRQ9vxi7i3F7CDy7IeL7ZWc_Sk6fzDte9XiOUqe_qXxYWfLndYdX-MPTg03BirMhZZnTBRjmnTNyJ77vhT1cDFL_VvLg5GvlXVr-hqhpLWagj43XWaDSu2L4v_9aURnHaZYUMEIkVt7ECN2AtajOkGNS7TVm-869lcVA35BGbgatvV8XfGEOmmCQCCq3MZ1j0PdLzGBFATlRnynn0dWsSRSxhdyfwac2UhgYJbIimTIAwyhqfIK9172YS2bx_mC0

Locally I also tried it with PlantUML version 1.2019.07beta15 and dot - graphviz version 2.40.1 (20161225.0304) and got the same result.

Which version of plantuml are you using?
commented Mar 31, 2020 by Ansgar

Well, not the best solution but adding some white spaces after quoting the name solves it for me, for example:

participant "DispatcherServlet   " as DS

I had to do something similar using a dot in an ER Diagram, like:

* dept_name : VARCHAR(40)     .

It somehow sucks but solves the problem for me.

1 Answer

0 votes
answered Jun 17, 2019 by plantuml (294,960 points)
Note that GraphViz is not used for Sequence Diagram.

A wild guess : did you use SVG export ?
...