nsdiag group description can intersect with ip address

0 votes
asked Aug 20 in Bug by RM (140 points)
When grouping nodes and using descriptions for the group, there seems to be no means to keep group descriptions and ip address from being written overtop of each other, making it hard to read.

@startuml
title Bug Demo

nwdiag {
    group Group_1 {
        description = "Group 1";

        Node1;
        Node2;
    }

    group Group_2 {
        description = "Group 2\nMultiline\nDescription";

        Node3;
        Node4;
    }

    group Group_3 {
        description = "Group 3";

        Node5;
        Node6;
    }

    network NetWork_A {
        address = "10.10.1.0/24";

        Node1 [ address = "10.10.1.1" ];
        Node2 [ address = "10.10.1.2" ];
        Node3 [ address = "10.10.1.3" ];
        Node4 [ address = "10.10.1.4" ];
        Node5 [ address = "10.10.1.5, 10.10.1.6, 10.10.1.7, 10.10.1.8" ];
        Node6 [ address = "10.10.1.9, 10.10.1.10, 10.10.1.11, 10.10.1.12" ];
    }

    network NetWork_B {
        address = "10.10.2.0/24";

        Node1 [ address = "10.10.2.1" ];
        Node2 [ address = "10.10.2.2" ];
        Node3 [ address = "10.10.2.3" ];
        Node4 [ address = "10.10.2.4" ];
        Node5 [ address = "10.10.2.5" ];
        Node6 [ address = "10.10.2.6" ];
    }

}
@enduml
commented Aug 20 by The-Lu (31,620 points)

Hello R.,

Awaiting correction about overlapping, a possible workaround is to add some newline '\n':

    network NetWork_A {
        address = "10.10.1.0/24";

        Node1 [ address = "10.10.1.1" ];
        Node2 [ address = "10.10.1.2" ];
        Node3 [ address = "10.10.1.3\n\n\n" ];
        Node4 [ address = "10.10.1.4\n\n\n" ];
        Node5 [ address = "10.10.1.5, 10.10.1.6, 10.10.1.7, 10.10.1.8\n" ];
        Node6 [ address = "10.10.1.9, 10.10.1.10, 10.10.1.11, 10.10.1.12\n" ];
    }

See also other tests here:

If that can help,
Regards,
Th.

1 Answer

0 votes
answered Aug 25 by plantuml (257,940 points)
...