mirror of
https://github.com/octoleo/plantuml.git
synced 2024-12-22 02:49:06 +00:00
parent
26874fe610
commit
475f814b65
@ -61,7 +61,7 @@ public class CommandActivity3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
|
||||
public static final String endingGroup() {
|
||||
return "(" //
|
||||
+ ";(?:[%s]*\\<\\<\\w+\\>\\>)?" //
|
||||
+ ";(?:[%s]*(\\<\\<\\w+\\>\\>))?" //
|
||||
+ "|" //
|
||||
+ Matcher.quoteReplacement("\\\\") // that is simply \ character
|
||||
+ "|" //
|
||||
@ -77,7 +77,7 @@ public class CommandActivity3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
|
||||
private static final String endingGroupShort() {
|
||||
return "(" //
|
||||
+ ";(?:[%s]*\\<\\<\\w+\\>\\>)?" //
|
||||
+ ";(?:[%s]*(\\<\\<\\w+\\>\\>))?" //
|
||||
+ "|" //
|
||||
+ Matcher.quoteReplacement("\\\\") // that is simply \ character
|
||||
+ "|" //
|
||||
@ -130,13 +130,19 @@ public class CommandActivity3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
}
|
||||
|
||||
Colors colors = color().getColor(arg, diagram.getSkinParam().getIHtmlColorSet());
|
||||
final String stereo = arg.get("STEREO", 0);
|
||||
String stereo = arg.get("STEREO", 0);
|
||||
if (stereo == null)
|
||||
stereo = arg.get("STYLE", 1);
|
||||
|
||||
Stereotype stereotype = null;
|
||||
if (stereo != null) {
|
||||
stereotype = Stereotype.build(stereo);
|
||||
colors = colors.applyStereotype(stereotype, diagram.getSkinParam(), ColorParam.activityBackground);
|
||||
}
|
||||
final BoxStyle style = BoxStyle.fromString(arg.get("STYLE", 0));
|
||||
BoxStyle style = BoxStyle.fromString(arg.get("STEREO", 0));
|
||||
if (style == BoxStyle.PLAIN)
|
||||
style = BoxStyle.fromString(arg.get("STYLE", 0));
|
||||
|
||||
final Display display = Display.getWithNewlines2(arg.get("LABEL", 0));
|
||||
return diagram.addActivity(display, style, url, colors, stereotype);
|
||||
}
|
||||
|
@ -154,17 +154,18 @@ public enum BoxStyle {
|
||||
}
|
||||
|
||||
public static BoxStyle fromString(String style) {
|
||||
if (style.length() == 1)
|
||||
if (style != null) {
|
||||
if (style.length() == 1)
|
||||
for (BoxStyle bs : BoxStyle.values())
|
||||
if (bs.style == style.charAt(0))
|
||||
return bs;
|
||||
|
||||
style = style.replaceAll("\\W", "");
|
||||
|
||||
for (BoxStyle bs : BoxStyle.values())
|
||||
if (bs.style == style.charAt(0))
|
||||
if (style.equalsIgnoreCase(bs.stereotype))
|
||||
return bs;
|
||||
|
||||
style = style.replaceAll("\\W", "");
|
||||
|
||||
for (BoxStyle bs : BoxStyle.values())
|
||||
if (style.equalsIgnoreCase(bs.stereotype))
|
||||
return bs;
|
||||
|
||||
}
|
||||
return PLAIN;
|
||||
}
|
||||
|
||||
|
@ -82,7 +82,7 @@ public class Version {
|
||||
}
|
||||
|
||||
public static int beta() {
|
||||
final int beta = 2;
|
||||
final int beta = 3;
|
||||
return beta;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user