mirror of
https://github.com/octoleo/plantuml.git
synced 2024-11-17 02:35:09 +00:00
fix: fix bad note shape in sequence diagram
https://github.com/plantuml/plantuml/issues/1609
This commit is contained in:
parent
422c74eba4
commit
b48ea95112
@ -44,21 +44,22 @@ public enum NoteStyle {
|
||||
NORMAL, HEXAGONAL, BOX;
|
||||
|
||||
public static NoteStyle getNoteStyle(String s) {
|
||||
if (s.equalsIgnoreCase("hnote")) {
|
||||
if (s.equalsIgnoreCase("hnote"))
|
||||
return NoteStyle.HEXAGONAL;
|
||||
} else if (s.equalsIgnoreCase("rnote")) {
|
||||
|
||||
if (s.equalsIgnoreCase("rnote"))
|
||||
return NoteStyle.BOX;
|
||||
}
|
||||
|
||||
return NoteStyle.NORMAL;
|
||||
}
|
||||
|
||||
public ComponentType getNoteComponentType() {
|
||||
if (this == NoteStyle.HEXAGONAL) {
|
||||
if (this == NoteStyle.HEXAGONAL)
|
||||
return ComponentType.NOTE_HEXAGONAL;
|
||||
}
|
||||
if (this == NoteStyle.BOX) {
|
||||
|
||||
if (this == NoteStyle.BOX)
|
||||
return ComponentType.NOTE_BOX;
|
||||
}
|
||||
|
||||
return ComponentType.NOTE;
|
||||
}
|
||||
|
||||
|
@ -46,7 +46,6 @@ import net.sourceforge.plantuml.sequencediagram.Note;
|
||||
import net.sourceforge.plantuml.skin.ArrowComponent;
|
||||
import net.sourceforge.plantuml.skin.ArrowConfiguration;
|
||||
import net.sourceforge.plantuml.skin.Component;
|
||||
import net.sourceforge.plantuml.skin.ComponentType;
|
||||
import net.sourceforge.plantuml.style.ISkinParam;
|
||||
|
||||
class Step1MessageExo extends Step1Abstract {
|
||||
@ -69,7 +68,8 @@ class Step1MessageExo extends Step1Abstract {
|
||||
for (Note noteOnMessage : noteOnMessages) {
|
||||
final ISkinParam skinParam = noteOnMessage.getSkinParamBackcolored(drawingSet.getSkinParam());
|
||||
final Component note = drawingSet.getSkin().createComponentNote(noteOnMessage.getUsedStyles(),
|
||||
ComponentType.NOTE, skinParam, noteOnMessage.getDisplay(), noteOnMessage.getColors());
|
||||
noteOnMessage.getNoteStyle().getNoteComponentType(), skinParam, noteOnMessage.getDisplay(),
|
||||
noteOnMessage.getColors());
|
||||
addNote(note);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user