mirror of
https://github.com/octoleo/plantuml.git
synced 2024-12-22 02:49:06 +00:00
wip
This commit is contained in:
parent
74ce471d71
commit
648b02f8c8
@ -240,7 +240,7 @@ delay {
|
||||
|
||||
|
||||
swimlane {
|
||||
BackGroundColor none
|
||||
BackGroundColor transparent
|
||||
LineColor black
|
||||
LineThickness 1.5
|
||||
FontSize 18
|
||||
@ -293,9 +293,9 @@ activityDiagram {
|
||||
FontSize 12
|
||||
RoundCorner 25
|
||||
}
|
||||
partition {
|
||||
composite {
|
||||
LineColor black
|
||||
BackgroundColor none
|
||||
BackgroundColor transparent
|
||||
LineThickness 1.5
|
||||
}
|
||||
diamond {
|
||||
|
@ -310,7 +310,7 @@ collections {
|
||||
}
|
||||
|
||||
swimlane {
|
||||
BackGroundColor none
|
||||
BackGroundColor transparent
|
||||
LineColor black
|
||||
LineThickness 2
|
||||
FontSize 18
|
||||
@ -370,9 +370,9 @@ activityDiagram {
|
||||
FontSize 12
|
||||
RoundCorner 25
|
||||
}
|
||||
partition {
|
||||
composite {
|
||||
LineColor black
|
||||
BackgroundColor none
|
||||
BackgroundColor transparent
|
||||
}
|
||||
diamond {
|
||||
FontSize 11
|
||||
|
@ -21,8 +21,7 @@ package jcckit.util;
|
||||
import java.awt.Color;
|
||||
import java.util.StringTokenizer;
|
||||
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapperIdentity;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapper;
|
||||
import net.sourceforge.plantuml.ugraphic.color.HColorSet;
|
||||
import net.sourceforge.plantuml.ugraphic.color.NoSuchColorException;
|
||||
|
||||
@ -306,7 +305,7 @@ static private HColorSet colors = HColorSet.instance();
|
||||
private Color decodeInternal(String value) {
|
||||
if (value!=null) {
|
||||
try {
|
||||
return colors.getColor(ThemeStyle.LIGHT_REGULAR, value).toColor(new ColorMapperIdentity());
|
||||
return colors.getColor(value).toColor(ColorMapper.IDENTITY);
|
||||
} catch (NoSuchColorException e) {
|
||||
return Color.WHITE;
|
||||
}
|
||||
|
@ -101,8 +101,7 @@ public class AnnotatedWorker {
|
||||
final double deltaShadow = style.value(PName.Shadowing).asDouble();
|
||||
final FontConfiguration fontConfiguration = FontConfiguration.create(getSkinParam(), style);
|
||||
final UStroke stroke = style.getStroke();
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getIHtmlColorSet());
|
||||
|
||||
final SymbolContext symbolContext = new SymbolContext(getBackgroundColor(), borderColor).withShadow(deltaShadow)
|
||||
.withStroke(stroke);
|
||||
|
@ -48,7 +48,6 @@ import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.code.AsciiEncoder;
|
||||
import net.sourceforge.plantuml.code.Transcoder;
|
||||
import net.sourceforge.plantuml.code.TranscoderUtil;
|
||||
@ -72,15 +71,14 @@ public class BlockUml {
|
||||
private final Defines localDefines;
|
||||
private final ISkinSimple skinParam;
|
||||
private final Set<FileWithSuffix> included = new HashSet<>();
|
||||
private final ThemeStyle style;
|
||||
|
||||
public Set<FileWithSuffix> getIncluded() {
|
||||
return Collections.unmodifiableSet(included);
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
BlockUml(ThemeStyle style, String... strings) {
|
||||
this(style, convert(strings), Defines.createEmpty(), null, null, null);
|
||||
BlockUml(String... strings) {
|
||||
this(convert(strings), Defines.createEmpty(), null, null, null);
|
||||
}
|
||||
|
||||
public String getEncodedUrl() throws IOException {
|
||||
@ -122,12 +120,11 @@ public class BlockUml {
|
||||
*/
|
||||
@Deprecated
|
||||
public BlockUml(List<StringLocated> strings, Defines defines, ISkinSimple skinParam, PreprocessorModeSet mode) {
|
||||
this(ThemeStyle.LIGHT_REGULAR, strings, defines, skinParam, mode, charsetOrDefault(mode.getCharset()));
|
||||
this(strings, defines, skinParam, mode, charsetOrDefault(mode.getCharset()));
|
||||
}
|
||||
|
||||
public BlockUml(ThemeStyle style, List<StringLocated> strings, Defines defines, ISkinSimple skinParam,
|
||||
PreprocessorModeSet mode, Charset charset) {
|
||||
this.style = style;
|
||||
public BlockUml(List<StringLocated> strings, Defines defines, ISkinSimple skinParam, PreprocessorModeSet mode,
|
||||
Charset charset) {
|
||||
this.rawSource = new ArrayList<>(strings);
|
||||
this.localDefines = defines;
|
||||
this.skinParam = skinParam;
|
||||
@ -179,7 +176,7 @@ public class BlockUml {
|
||||
if (preprocessorError)
|
||||
system = new PSystemErrorPreprocessor(data, debug);
|
||||
else
|
||||
system = new PSystemBuilder().createPSystem(style, skinParam, data, rawSource);
|
||||
system = new PSystemBuilder().createPSystem(skinParam, data, rawSource);
|
||||
}
|
||||
return system;
|
||||
}
|
||||
|
@ -47,7 +47,6 @@ import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.preproc.Defines;
|
||||
import net.sourceforge.plantuml.preproc.FileWithSuffix;
|
||||
import net.sourceforge.plantuml.preproc.ImportedFiles;
|
||||
@ -66,7 +65,6 @@ public final class BlockUmlBuilder implements DefinitionsContainer {
|
||||
private final Defines defines;
|
||||
private final ImportedFiles importedFiles;
|
||||
private final Charset charset;
|
||||
private final ThemeStyle style;
|
||||
|
||||
/**
|
||||
* @deprecated being kept for backwards compatibility, perhaps other projects
|
||||
@ -75,7 +73,7 @@ public final class BlockUmlBuilder implements DefinitionsContainer {
|
||||
@Deprecated
|
||||
public BlockUmlBuilder(List<String> config, String charset, Defines defines, Reader readerInit, SFile newCurrentDir,
|
||||
String desc) throws IOException {
|
||||
this(ThemeStyle.LIGHT_REGULAR, config, charsetOrDefault(charset), defines, readerInit, newCurrentDir, desc);
|
||||
this(config, charsetOrDefault(charset), defines, readerInit, newCurrentDir, desc);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -87,10 +85,9 @@ public final class BlockUmlBuilder implements DefinitionsContainer {
|
||||
this(config, charset, defines, reader, null, null);
|
||||
}
|
||||
|
||||
public BlockUmlBuilder(ThemeStyle style, List<String> config, Charset charset, Defines defines, Reader readerInit,
|
||||
SFile newCurrentDir, String desc) throws IOException {
|
||||
public BlockUmlBuilder(List<String> config, Charset charset, Defines defines, Reader readerInit, SFile newCurrentDir,
|
||||
String desc) throws IOException {
|
||||
|
||||
this.style = style;
|
||||
this.defines = defines;
|
||||
this.charset = requireNonNull(charset);
|
||||
this.reader = new UncommentReadLine(ReadLineReader.create(readerInit, desc));
|
||||
@ -138,7 +135,7 @@ public final class BlockUmlBuilder implements DefinitionsContainer {
|
||||
if (paused)
|
||||
current.add(s);
|
||||
|
||||
final BlockUml uml = new BlockUml(style, current, defines.cloneMe(), null, this, charset);
|
||||
final BlockUml uml = new BlockUml(current, defines.cloneMe(), null, this, charset);
|
||||
usedFiles.addAll(uml.getIncluded());
|
||||
blocks.add(uml);
|
||||
current = null;
|
||||
|
@ -137,8 +137,7 @@ class EmbeddedDiagramDraw extends AbstractTextBlock implements Line, Atom {
|
||||
}
|
||||
|
||||
private Diagram getSystem() throws IOException, InterruptedException {
|
||||
final BlockUml blockUml = new BlockUml(skinParam.getThemeStyle(), as2, Defines.createEmpty(), skinParam, null,
|
||||
null);
|
||||
final BlockUml blockUml = new BlockUml(as2, Defines.createEmpty(), skinParam, null, null);
|
||||
return blockUml.getDiagram();
|
||||
|
||||
}
|
||||
|
@ -48,7 +48,7 @@ import java.util.List;
|
||||
import net.sourceforge.plantuml.cucadiagram.dot.GraphvizUtils;
|
||||
import net.sourceforge.plantuml.graphic.StringBounder;
|
||||
import net.sourceforge.plantuml.ugraphic.UAntiAliasing;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapperIdentity;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapper;
|
||||
import net.sourceforge.plantuml.ugraphic.color.HColor;
|
||||
import net.sourceforge.plantuml.ugraphic.color.HColors;
|
||||
import net.sourceforge.plantuml.ugraphic.g2d.UGraphicG2d;
|
||||
@ -170,7 +170,7 @@ public class EmptyImageBuilder {
|
||||
|
||||
public UGraphicG2d getUGraphicG2d() {
|
||||
final HColor back = HColors.simple(background);
|
||||
final UGraphicG2d result = new UGraphicG2d(back, new ColorMapperIdentity(), stringBounder, g2d, 1.0);
|
||||
final UGraphicG2d result = new UGraphicG2d(back, ColorMapper.IDENTITY, stringBounder, g2d, 1.0);
|
||||
result.setBufferedImage(im);
|
||||
return result;
|
||||
}
|
||||
|
@ -40,8 +40,8 @@ import java.io.Serializable;
|
||||
import java.util.Objects;
|
||||
|
||||
import net.sourceforge.plantuml.annotation.HaxeIgnored;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.graphic.StringBounder;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapper;
|
||||
|
||||
/**
|
||||
* A FileFormat with some parameters.
|
||||
@ -61,7 +61,7 @@ public final class FileFormatOption implements Serializable {
|
||||
private final double scale;
|
||||
private final String preserveAspectRatio;
|
||||
private final String watermark;
|
||||
private final ThemeStyle style;
|
||||
private final ColorMapper colorMapper;
|
||||
|
||||
public double getScaleCoef() {
|
||||
return scale;
|
||||
@ -69,17 +69,19 @@ public final class FileFormatOption implements Serializable {
|
||||
|
||||
@HaxeIgnored
|
||||
public FileFormatOption(FileFormat fileFormat) {
|
||||
this(fileFormat, true, false, null, false, null, TikzFontDistortion.getDefault(), 1.0, null, null, ThemeStyle.LIGHT_REGULAR);
|
||||
this(fileFormat, true, false, null, false, null, TikzFontDistortion.getDefault(), 1.0, null, null,
|
||||
ColorMapper.IDENTITY);
|
||||
}
|
||||
|
||||
@HaxeIgnored
|
||||
public FileFormatOption(FileFormat fileFormat, boolean withMetadata) {
|
||||
this(fileFormat, withMetadata, false, null, false, null, TikzFontDistortion.getDefault(), 1.0, null, null, ThemeStyle.LIGHT_REGULAR);
|
||||
this(fileFormat, withMetadata, false, null, false, null, TikzFontDistortion.getDefault(), 1.0, null, null,
|
||||
ColorMapper.IDENTITY);
|
||||
}
|
||||
|
||||
private FileFormatOption(FileFormat fileFormat, boolean withMetadata, boolean useRedForError, String svgLinkTarget,
|
||||
boolean debugsvek, String hoverColor, TikzFontDistortion tikzFontDistortion, double scale,
|
||||
String preserveAspectRatio, String watermark, ThemeStyle style) {
|
||||
String preserveAspectRatio, String watermark, ColorMapper colorMapper) {
|
||||
this.hoverColor = hoverColor;
|
||||
this.watermark = watermark;
|
||||
this.fileFormat = fileFormat;
|
||||
@ -90,7 +92,7 @@ public final class FileFormatOption implements Serializable {
|
||||
this.tikzFontDistortion = Objects.requireNonNull(tikzFontDistortion);
|
||||
this.scale = scale;
|
||||
this.preserveAspectRatio = preserveAspectRatio;
|
||||
this.style = style;
|
||||
this.colorMapper = colorMapper;
|
||||
}
|
||||
|
||||
public StringBounder getDefaultStringBounder(SvgCharSizeHack charSizeHack) {
|
||||
@ -111,42 +113,42 @@ public final class FileFormatOption implements Serializable {
|
||||
|
||||
public FileFormatOption withUseRedForError() {
|
||||
return new FileFormatOption(fileFormat, withMetadata, true, svgLinkTarget, debugsvek, hoverColor,
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, style);
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, colorMapper);
|
||||
}
|
||||
|
||||
public FileFormatOption withTikzFontDistortion(TikzFontDistortion tikzFontDistortion) {
|
||||
return new FileFormatOption(fileFormat, withMetadata, true, svgLinkTarget, debugsvek, hoverColor,
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, style);
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, colorMapper);
|
||||
}
|
||||
|
||||
public FileFormatOption withSvgLinkTarget(String svgLinkTarget) {
|
||||
return new FileFormatOption(fileFormat, withMetadata, useRedForError, svgLinkTarget, debugsvek, hoverColor,
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, style);
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, colorMapper);
|
||||
}
|
||||
|
||||
public FileFormatOption withPreserveAspectRatio(String preserveAspectRatio) {
|
||||
return new FileFormatOption(fileFormat, withMetadata, useRedForError, svgLinkTarget, debugsvek, hoverColor,
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, style);
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, colorMapper);
|
||||
}
|
||||
|
||||
public FileFormatOption withHoverColor(String hoverColor) {
|
||||
return new FileFormatOption(fileFormat, withMetadata, useRedForError, svgLinkTarget, debugsvek, hoverColor,
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, style);
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, colorMapper);
|
||||
}
|
||||
|
||||
public FileFormatOption withScale(double scale) {
|
||||
return new FileFormatOption(fileFormat, withMetadata, useRedForError, svgLinkTarget, debugsvek, hoverColor,
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, style);
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, colorMapper);
|
||||
}
|
||||
|
||||
public FileFormatOption withWartermark(String watermark) {
|
||||
return new FileFormatOption(fileFormat, withMetadata, useRedForError, svgLinkTarget, debugsvek, hoverColor,
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, style);
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, colorMapper);
|
||||
}
|
||||
|
||||
public FileFormatOption withStyle(ThemeStyle style) {
|
||||
public FileFormatOption withColorMapper(ColorMapper colorMapper) {
|
||||
return new FileFormatOption(fileFormat, withMetadata, useRedForError, svgLinkTarget, debugsvek, hoverColor,
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, style);
|
||||
tikzFontDistortion, scale, preserveAspectRatio, watermark, colorMapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -193,8 +195,8 @@ public final class FileFormatOption implements Serializable {
|
||||
return watermark;
|
||||
}
|
||||
|
||||
public ThemeStyle getStyle() {
|
||||
return style;
|
||||
public ColorMapper getColorMapper() {
|
||||
return colorMapper;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -190,7 +190,4 @@ public interface ISkinParam extends ISkinSimple {
|
||||
public void setSvgSize(String origin, String sizeToUse);
|
||||
|
||||
public LengthAdjust getlengthAdjust();
|
||||
|
||||
// public void assumeTransparent(ThemeStyle style);
|
||||
|
||||
}
|
||||
|
@ -37,7 +37,6 @@ package net.sourceforge.plantuml;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.ugraphic.color.HColorSet;
|
||||
|
||||
public interface ISkinSimple extends SpriteContainer {
|
||||
@ -61,7 +60,5 @@ public interface ISkinSimple extends SpriteContainer {
|
||||
public void copyAllFrom(ISkinSimple other);
|
||||
|
||||
public double minClassWidth();
|
||||
|
||||
public ThemeStyle getThemeStyle();
|
||||
|
||||
}
|
@ -43,7 +43,6 @@ import net.sourceforge.plantuml.acearth.PSystemXearthFactory;
|
||||
import net.sourceforge.plantuml.activitydiagram.ActivityDiagramFactory;
|
||||
import net.sourceforge.plantuml.activitydiagram3.ActivityDiagramFactory3;
|
||||
import net.sourceforge.plantuml.api.PSystemFactory;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.board.BoardDiagramFactory;
|
||||
import net.sourceforge.plantuml.bpm.BpmDiagramFactory;
|
||||
import net.sourceforge.plantuml.classdiagram.ClassDiagramFactory;
|
||||
@ -106,8 +105,7 @@ public class PSystemBuilder {
|
||||
|
||||
public static final long startTime = System.currentTimeMillis();
|
||||
|
||||
final public Diagram createPSystem(ThemeStyle style, ISkinSimple skinParam, List<StringLocated> source,
|
||||
List<StringLocated> rawSource) {
|
||||
final public Diagram createPSystem(ISkinSimple skinParam, List<StringLocated> source, List<StringLocated> rawSource) {
|
||||
|
||||
final long now = System.currentTimeMillis();
|
||||
|
||||
@ -133,7 +131,7 @@ public class PSystemBuilder {
|
||||
if (diagramType != systemFactory.getDiagramType())
|
||||
continue;
|
||||
|
||||
final Diagram sys = systemFactory.createSystem(style, umlSource, skinParam);
|
||||
final Diagram sys = systemFactory.createSystem(umlSource, skinParam);
|
||||
if (isOk(sys)) {
|
||||
result = sys;
|
||||
return sys;
|
||||
|
@ -52,7 +52,6 @@ import java.util.Set;
|
||||
import java.util.TreeSet;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.command.BlocLines;
|
||||
import net.sourceforge.plantuml.command.regex.Matcher2;
|
||||
import net.sourceforge.plantuml.command.regex.MyPattern;
|
||||
@ -81,11 +80,6 @@ import net.sourceforge.plantuml.svg.LengthAdjust;
|
||||
import net.sourceforge.plantuml.ugraphic.UFont;
|
||||
import net.sourceforge.plantuml.ugraphic.UStroke;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapper;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapperForceDark;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapperIdentity;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapperLightnessInverse;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapperMonochrome;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapperReverse;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorOrder;
|
||||
import net.sourceforge.plantuml.ugraphic.color.HColor;
|
||||
import net.sourceforge.plantuml.ugraphic.color.HColorSet;
|
||||
@ -100,11 +94,8 @@ public class SkinParam implements ISkinParam {
|
||||
// private String skin = "debug.skin";
|
||||
private String skin = "plantuml.skin";
|
||||
private StyleBuilder styleBuilder;
|
||||
// private ThemeStyle themeStyle = ThemeStyle.LIGHT_REGULAR;
|
||||
private final ThemeStyle themeStyle;
|
||||
|
||||
private SkinParam(UmlDiagramType type, ThemeStyle style) {
|
||||
this.themeStyle = style;
|
||||
private SkinParam(UmlDiagramType type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
@ -195,12 +186,12 @@ public class SkinParam implements ISkinParam {
|
||||
paramsPendingForStyleMigration.clear();
|
||||
}
|
||||
|
||||
public static SkinParam create(UmlDiagramType type, ThemeStyle style) {
|
||||
return new SkinParam(type, style);
|
||||
public static SkinParam create(UmlDiagramType type) {
|
||||
return new SkinParam(type);
|
||||
}
|
||||
|
||||
public static SkinParam noShadowing(UmlDiagramType type, ThemeStyle style) {
|
||||
final SkinParam result = new SkinParam(type, style);
|
||||
public static SkinParam noShadowing(UmlDiagramType type) {
|
||||
final SkinParam result = new SkinParam(type);
|
||||
result.setParam("shadowing", "false");
|
||||
return result;
|
||||
}
|
||||
@ -218,7 +209,8 @@ public class SkinParam implements ISkinParam {
|
||||
|
||||
private static final Pattern patternCleanUnderscoreDot = Pattern.compile("_|\\.");
|
||||
private static final Pattern patternCleanSequence = Pattern.compile("sequence(participant|actor)");
|
||||
private static final Pattern patternCleanArrow = Pattern.compile("(activity|class|component|object|sequence|state|usecase)arrow");
|
||||
private static final Pattern patternCleanArrow = Pattern
|
||||
.compile("(activity|class|component|object|sequence|state|usecase)arrow");
|
||||
private static final Pattern patternCleanAlign = Pattern.compile("align$");
|
||||
|
||||
List<String> cleanForKeySlow(String key) {
|
||||
@ -297,8 +289,8 @@ public class SkinParam implements ISkinParam {
|
||||
checkStereotype(stereotype);
|
||||
for (String s : stereotype.getMultipleLabels()) {
|
||||
final String value2 = getValue(param.name() + "color" + "<<" + s + ">>");
|
||||
if (value2 != null && getIHtmlColorSet().getColorOrWhite(themeStyle, value2) != null)
|
||||
return getIHtmlColorSet().getColorOrWhite(themeStyle, value2);
|
||||
if (value2 != null && getIHtmlColorSet().getColorOrWhite(value2) != null)
|
||||
return getIHtmlColorSet().getColorOrWhite(value2);
|
||||
|
||||
}
|
||||
}
|
||||
@ -311,11 +303,11 @@ public class SkinParam implements ISkinParam {
|
||||
return HColors.transparent();
|
||||
|
||||
if (param == ColorParam.background)
|
||||
return getIHtmlColorSet().getColorOrWhite(themeStyle, value);
|
||||
return getIHtmlColorSet().getColorOrWhite(value);
|
||||
|
||||
assert param != ColorParam.background;
|
||||
|
||||
return getIHtmlColorSet().getColorOrWhite(themeStyle, value);
|
||||
return getIHtmlColorSet().getColorOrWhite(value);
|
||||
}
|
||||
|
||||
public char getCircledCharacter(Stereotype stereotype) {
|
||||
@ -332,14 +324,14 @@ public class SkinParam implements ISkinParam {
|
||||
checkStereotype(stereotype);
|
||||
final String value2 = getValue(param.name() + "color" + stereotype.getLabel(Guillemet.DOUBLE_COMPARATOR));
|
||||
if (value2 != null)
|
||||
return new Colors(themeStyle, value2, getIHtmlColorSet(), param.getColorType());
|
||||
return new Colors(value2, getIHtmlColorSet(), param.getColorType());
|
||||
|
||||
}
|
||||
final String value = getValue(getParamName(param, false));
|
||||
if (value == null)
|
||||
return Colors.empty();
|
||||
|
||||
return new Colors(themeStyle, value, getIHtmlColorSet(), param.getColorType());
|
||||
return new Colors(value, getIHtmlColorSet(), param.getColorType());
|
||||
}
|
||||
|
||||
private String getParamName(ColorParam param, boolean clickable) {
|
||||
@ -421,7 +413,7 @@ public class SkinParam implements ISkinParam {
|
||||
if (value == null)
|
||||
return null;
|
||||
|
||||
return getIHtmlColorSet().getColorOrWhite(themeStyle, value);
|
||||
return getIHtmlColorSet().getColorOrWhite(value);
|
||||
}
|
||||
|
||||
private String getFirstValueNonNullWithSuffix(String suffix, FontParam... param) {
|
||||
@ -669,28 +661,28 @@ public class SkinParam implements ISkinParam {
|
||||
}
|
||||
|
||||
public ColorMapper getColorMapper() {
|
||||
if (themeStyle == ThemeStyle.DARK)
|
||||
return new ColorMapperForceDark();
|
||||
if ("dark".equalsIgnoreCase(getValue("mode")))
|
||||
return ColorMapper.FORCE_DARK;
|
||||
|
||||
final String monochrome = getValue("monochrome");
|
||||
if ("true".equals(monochrome))
|
||||
return new ColorMapperMonochrome(false);
|
||||
return ColorMapper.MONOCHROME;
|
||||
|
||||
if ("reverse".equals(monochrome))
|
||||
return new ColorMapperMonochrome(true);
|
||||
return ColorMapper.MONOCHROME_REVERSE;
|
||||
|
||||
final String value = getValue("reversecolor");
|
||||
if (value == null)
|
||||
return new ColorMapperIdentity();
|
||||
return ColorMapper.IDENTITY;
|
||||
|
||||
if ("dark".equalsIgnoreCase(value))
|
||||
return new ColorMapperLightnessInverse();
|
||||
return ColorMapper.LIGTHNESS_INVERSE;
|
||||
|
||||
final ColorOrder order = ColorOrder.fromString(value);
|
||||
if (order == null)
|
||||
return new ColorMapperIdentity();
|
||||
return ColorMapper.IDENTITY;
|
||||
|
||||
return new ColorMapperReverse(order);
|
||||
return ColorMapper.reverse(order);
|
||||
}
|
||||
|
||||
public boolean shadowing(Stereotype stereotype) {
|
||||
@ -1005,8 +997,8 @@ public class SkinParam implements ISkinParam {
|
||||
public SplitParam getSplitParam() {
|
||||
final String border = getValue("pageBorderColor");
|
||||
final String external = getValue("pageExternalColor");
|
||||
final HColor borderColor = border == null ? null : getIHtmlColorSet().getColorOrWhite(themeStyle, border);
|
||||
final HColor externalColor = external == null ? null : getIHtmlColorSet().getColorOrWhite(themeStyle, external);
|
||||
final HColor borderColor = border == null ? null : getIHtmlColorSet().getColorOrWhite(border);
|
||||
final HColor externalColor = external == null ? null : getIHtmlColorSet().getColorOrWhite(external);
|
||||
int margin = getAsInt("pageMargin", 0);
|
||||
return new SplitParam(borderColor, externalColor, margin);
|
||||
}
|
||||
@ -1031,7 +1023,7 @@ public class SkinParam implements ISkinParam {
|
||||
if (value == null)
|
||||
return null;
|
||||
|
||||
return getIHtmlColorSet().getColorOrWhite(themeStyle, value);
|
||||
return getIHtmlColorSet().getColorOrWhite(value);
|
||||
}
|
||||
|
||||
public double getPadding() {
|
||||
@ -1101,9 +1093,8 @@ public class SkinParam implements ISkinParam {
|
||||
if (padding == 0 && margin == 0 && borderColor == null && backgroundColor == null)
|
||||
return Padder.NONE;
|
||||
|
||||
final HColor border = borderColor == null ? null : getIHtmlColorSet().getColorOrWhite(themeStyle, borderColor);
|
||||
final HColor background = backgroundColor == null ? null
|
||||
: getIHtmlColorSet().getColorOrWhite(themeStyle, backgroundColor);
|
||||
final HColor border = borderColor == null ? null : getIHtmlColorSet().getColorOrWhite(borderColor);
|
||||
final HColor background = backgroundColor == null ? null : getIHtmlColorSet().getColorOrWhite(backgroundColor);
|
||||
final double roundCorner = getRoundCorner(CornerParam.DEFAULT, null);
|
||||
return Padder.NONE.withMargin(margin).withPadding(padding).withBackgroundColor(background)
|
||||
.withBorderColor(border).withRoundCorner(roundCorner);
|
||||
@ -1146,12 +1137,4 @@ public class SkinParam implements ISkinParam {
|
||||
return LengthAdjust.defaultValue();
|
||||
}
|
||||
|
||||
// public void assumeTransparent(ThemeStyle style) {
|
||||
// this.themeStyle = style;
|
||||
// }
|
||||
|
||||
public ThemeStyle getThemeStyle() {
|
||||
return themeStyle;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -38,7 +38,6 @@ package net.sourceforge.plantuml;
|
||||
import java.util.Collection;
|
||||
import java.util.Map;
|
||||
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.cucadiagram.Rankdir;
|
||||
import net.sourceforge.plantuml.cucadiagram.Stereotype;
|
||||
import net.sourceforge.plantuml.cucadiagram.dot.DotSplines;
|
||||
@ -450,14 +449,4 @@ public class SkinParamDelegator implements ISkinParam {
|
||||
return skinParam.getlengthAdjust();
|
||||
}
|
||||
|
||||
// @Override
|
||||
// public void assumeTransparent(ThemeStyle style) {
|
||||
// skinParam.assumeTransparent(style);
|
||||
// }
|
||||
|
||||
@Override
|
||||
public ThemeStyle getThemeStyle() {
|
||||
return skinParam.getThemeStyle();
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -85,8 +85,8 @@ public abstract class SourceFileReaderAbstract implements ISourceFileReader {
|
||||
|
||||
this.file = file;
|
||||
this.fileFormatOption = fileFormatOption;
|
||||
this.builder = new BlockUmlBuilder(fileFormatOption.getStyle(), config, charset, defines, getReader(charset),
|
||||
SFile.fromFile(file.getAbsoluteFile().getParentFile()), FileWithSuffix.getFileName(file));
|
||||
this.builder = new BlockUmlBuilder(config, charset, defines, getReader(charset), SFile.fromFile(file.getAbsoluteFile().getParentFile()),
|
||||
FileWithSuffix.getFileName(file));
|
||||
}
|
||||
|
||||
public void setCheckMetadata(boolean checkMetadata) {
|
||||
|
@ -48,7 +48,6 @@ import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
import net.sourceforge.plantuml.annotation.HaxeIgnored;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.core.Diagram;
|
||||
import net.sourceforge.plantuml.core.DiagramDescription;
|
||||
import net.sourceforge.plantuml.core.ImageData;
|
||||
@ -61,7 +60,6 @@ import net.sourceforge.plantuml.svek.TextBlockBackcolored;
|
||||
public class SourceStringReader {
|
||||
|
||||
final private List<BlockUml> blocks;
|
||||
final private ThemeStyle style;
|
||||
|
||||
public SourceStringReader(String source) {
|
||||
this(Defines.createEmpty(), source, Collections.<String>emptyList());
|
||||
@ -98,15 +96,9 @@ public class SourceStringReader {
|
||||
|
||||
public SourceStringReader(Defines defines, String source, Charset charset, List<String> config,
|
||||
SFile newCurrentDir) {
|
||||
this(defines, source, charset, config, newCurrentDir, ThemeStyle.LIGHT_REGULAR);
|
||||
}
|
||||
|
||||
public SourceStringReader(Defines defines, String source, Charset charset, List<String> config, SFile newCurrentDir,
|
||||
ThemeStyle style) {
|
||||
this.style = style;
|
||||
try {
|
||||
final BlockUmlBuilder builder = new BlockUmlBuilder(style, config, charset, defines,
|
||||
new StringReader(source), newCurrentDir, "string");
|
||||
final BlockUmlBuilder builder = new BlockUmlBuilder(config, charset, defines, new StringReader(source),
|
||||
newCurrentDir, "string");
|
||||
this.blocks = builder.getBlockUmls();
|
||||
} catch (IOException e) {
|
||||
Log.error("error " + e);
|
||||
@ -136,11 +128,11 @@ public class SourceStringReader {
|
||||
|
||||
@Deprecated
|
||||
public String generateImage(OutputStream os, FileFormatOption fileFormatOption) throws IOException {
|
||||
return outputImage(os, fileFormatOption.withStyle(style)).getDescription();
|
||||
return outputImage(os, fileFormatOption).getDescription();
|
||||
}
|
||||
|
||||
public DiagramDescription outputImage(OutputStream os, FileFormatOption fileFormatOption) throws IOException {
|
||||
return outputImage(os, 0, fileFormatOption.withStyle(style));
|
||||
return outputImage(os, 0, fileFormatOption);
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
@ -154,12 +146,12 @@ public class SourceStringReader {
|
||||
|
||||
@Deprecated
|
||||
public String generateImage(OutputStream os, int numImage, FileFormatOption fileFormatOption) throws IOException {
|
||||
return outputImage(os, numImage, fileFormatOption.withStyle(style)).getDescription();
|
||||
return outputImage(os, numImage, fileFormatOption).getDescription();
|
||||
}
|
||||
|
||||
public DiagramDescription outputImage(OutputStream os, int numImage, FileFormatOption fileFormatOption)
|
||||
throws IOException {
|
||||
fileFormatOption = fileFormatOption.withStyle(style);
|
||||
fileFormatOption = fileFormatOption;
|
||||
if (blocks.size() == 0) {
|
||||
noStartumlFound(os, fileFormatOption);
|
||||
return null;
|
||||
@ -184,7 +176,7 @@ public class SourceStringReader {
|
||||
}
|
||||
|
||||
public DiagramDescription generateDiagramDescription(int numImage, FileFormatOption fileFormatOption) {
|
||||
fileFormatOption = fileFormatOption.withStyle(style);
|
||||
fileFormatOption = fileFormatOption;
|
||||
if (blocks.size() == 0) {
|
||||
return null;
|
||||
}
|
||||
@ -211,15 +203,15 @@ public class SourceStringReader {
|
||||
}
|
||||
|
||||
public DiagramDescription generateDiagramDescription(FileFormatOption fileFormatOption) {
|
||||
return generateDiagramDescription(0, fileFormatOption.withStyle(style));
|
||||
return generateDiagramDescription(0, fileFormatOption);
|
||||
}
|
||||
|
||||
public DiagramDescription generateDiagramDescription(int numImage) {
|
||||
return generateDiagramDescription(numImage, new FileFormatOption(FileFormat.PNG).withStyle(style));
|
||||
return generateDiagramDescription(numImage, new FileFormatOption(FileFormat.PNG));
|
||||
}
|
||||
|
||||
public String getCMapData(int numImage, FileFormatOption fileFormatOption) throws IOException {
|
||||
fileFormatOption = fileFormatOption.withStyle(style);
|
||||
fileFormatOption = fileFormatOption;
|
||||
if (blocks.size() == 0) {
|
||||
return null;
|
||||
}
|
||||
@ -240,7 +232,7 @@ public class SourceStringReader {
|
||||
}
|
||||
|
||||
public ImageData noStartumlFound(OutputStream os, FileFormatOption fileFormatOption) throws IOException {
|
||||
fileFormatOption = fileFormatOption.withStyle(style);
|
||||
fileFormatOption = fileFormatOption;
|
||||
final TextBlockBackcolored error = GraphicStrings.createForError(Arrays.asList("No @startuml/@enduml found"),
|
||||
fileFormatOption.isUseRedForError());
|
||||
|
||||
|
@ -71,14 +71,14 @@ public class SplitParam {
|
||||
if (borderColor == null)
|
||||
return null;
|
||||
|
||||
return ((HColorSimple) borderColor).getColor999();
|
||||
return ((HColorSimple) borderColor).getAwtColor();
|
||||
}
|
||||
|
||||
public Color getExternalColor() {
|
||||
if (externalColor == null)
|
||||
return null;
|
||||
|
||||
return ((HColorSimple) externalColor).getColor999();
|
||||
return ((HColorSimple) externalColor).getAwtColor();
|
||||
}
|
||||
|
||||
}
|
@ -35,7 +35,6 @@
|
||||
*/
|
||||
package net.sourceforge.plantuml;
|
||||
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.sprite.Sprite;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapper;
|
||||
|
||||
@ -45,8 +44,6 @@ public interface SpriteContainer extends SvgCharSizeHack {
|
||||
|
||||
public Guillemet guillemet();
|
||||
|
||||
public ThemeStyle getThemeStyle();
|
||||
|
||||
public ColorMapper getColorMapper();
|
||||
|
||||
}
|
@ -37,12 +37,10 @@ package net.sourceforge.plantuml;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.creole.Parser;
|
||||
import net.sourceforge.plantuml.sprite.Sprite;
|
||||
import net.sourceforge.plantuml.sprite.SpriteImage;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapper;
|
||||
import net.sourceforge.plantuml.ugraphic.color.ColorMapperIdentity;
|
||||
import net.sourceforge.plantuml.ugraphic.color.HColorSet;
|
||||
|
||||
public class SpriteContainerEmpty implements SpriteContainer, ISkinSimple {
|
||||
@ -84,7 +82,7 @@ public class SpriteContainerEmpty implements SpriteContainer, ISkinSimple {
|
||||
}
|
||||
|
||||
public ColorMapper getColorMapper() {
|
||||
return new ColorMapperIdentity();
|
||||
return ColorMapper.IDENTITY;
|
||||
}
|
||||
|
||||
public void copyAllFrom(ISkinSimple other) {
|
||||
@ -103,8 +101,4 @@ public class SpriteContainerEmpty implements SpriteContainer, ISkinSimple {
|
||||
return s;
|
||||
}
|
||||
|
||||
public ThemeStyle getThemeStyle() {
|
||||
return ThemeStyle.LIGHT_REGULAR;
|
||||
}
|
||||
|
||||
}
|
@ -41,7 +41,6 @@ import java.io.InputStream;
|
||||
import net.sourceforge.plantuml.anim.Animation;
|
||||
import net.sourceforge.plantuml.anim.AnimationDecoder;
|
||||
import net.sourceforge.plantuml.api.ApiStable;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.command.CommandExecutionResult;
|
||||
import net.sourceforge.plantuml.core.Diagram;
|
||||
import net.sourceforge.plantuml.core.UmlSource;
|
||||
@ -87,10 +86,10 @@ public abstract class TitledDiagram extends AbstractPSystem implements Diagram,
|
||||
return pragma;
|
||||
}
|
||||
|
||||
public TitledDiagram(ThemeStyle style, UmlSource source, UmlDiagramType type, ISkinSimple orig) {
|
||||
public TitledDiagram(UmlSource source, UmlDiagramType type, ISkinSimple orig) {
|
||||
super(source);
|
||||
this.type = type;
|
||||
this.skinParam = SkinParam.create(type, style);
|
||||
this.skinParam = SkinParam.create(type);
|
||||
if (orig != null)
|
||||
this.skinParam.copyAllFrom(orig);
|
||||
|
||||
@ -272,8 +271,7 @@ public abstract class TitledDiagram extends AbstractPSystem implements Diagram,
|
||||
final Style style = StyleSignatureBasic.of(SName.root, SName.document, this.getUmlDiagramType().getStyleName())
|
||||
.getMergedStyle(this.getSkinParam().getCurrentStyleBuilder());
|
||||
|
||||
HColor backgroundColor = style.value(PName.BackGroundColor).asColor(this.getSkinParam().getThemeStyle(),
|
||||
this.getSkinParam().getIHtmlColorSet());
|
||||
HColor backgroundColor = style.value(PName.BackGroundColor).asColor(this.getSkinParam().getIHtmlColorSet());
|
||||
if (backgroundColor == null)
|
||||
backgroundColor = HColors.transparent();
|
||||
|
||||
|
@ -51,7 +51,6 @@ import java.io.PrintWriter;
|
||||
import java.util.List;
|
||||
|
||||
import net.sourceforge.plantuml.api.ImageDataSimple;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.awt.geom.XDimension2D;
|
||||
import net.sourceforge.plantuml.command.CommandExecutionResult;
|
||||
import net.sourceforge.plantuml.core.Diagram;
|
||||
@ -92,8 +91,8 @@ public abstract class UmlDiagram extends TitledDiagram implements Diagram, Annot
|
||||
// super(style, source, type);
|
||||
// }
|
||||
|
||||
public UmlDiagram(ThemeStyle style, UmlSource source, UmlDiagramType type, ISkinSimple orig) {
|
||||
super(style, source, type, orig);
|
||||
public UmlDiagram(UmlSource source, UmlDiagramType type, ISkinSimple orig) {
|
||||
super(source, type, orig);
|
||||
}
|
||||
|
||||
final public int getMinwidth() {
|
||||
|
@ -41,7 +41,6 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import ext.plantuml.com.ctreber.acearth.plugins.markers.Marker;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.command.PSystemBasicFactory;
|
||||
import net.sourceforge.plantuml.command.regex.Matcher2;
|
||||
import net.sourceforge.plantuml.command.regex.MyPattern;
|
||||
@ -57,7 +56,7 @@ public class PSystemXearthFactory extends PSystemBasicFactory<PSystemXearth> {
|
||||
private int height;
|
||||
|
||||
@Override
|
||||
public PSystemXearth initDiagram(ThemeStyle style, UmlSource source, String startLine) {
|
||||
public PSystemXearth initDiagram(UmlSource source, String startLine) {
|
||||
this.width = 512;
|
||||
this.height = 512;
|
||||
this.config.clear();
|
||||
@ -76,7 +75,7 @@ public class PSystemXearthFactory extends PSystemBasicFactory<PSystemXearth> {
|
||||
}
|
||||
|
||||
@Override
|
||||
public PSystemXearth executeLine(ThemeStyle style, UmlSource source, PSystemXearth system, String line) {
|
||||
public PSystemXearth executeLine(UmlSource source, PSystemXearth system, String line) {
|
||||
if (system == null && line.startsWith("xearth")) {
|
||||
extractDimension(line);
|
||||
system = new PSystemXearth(source, width, height, config, markers);
|
||||
|
@ -42,7 +42,6 @@ import java.util.Objects;
|
||||
import net.sourceforge.plantuml.Direction;
|
||||
import net.sourceforge.plantuml.ISkinSimple;
|
||||
import net.sourceforge.plantuml.UmlDiagramType;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.core.DiagramDescription;
|
||||
import net.sourceforge.plantuml.core.UmlSource;
|
||||
import net.sourceforge.plantuml.cucadiagram.Code;
|
||||
@ -62,8 +61,8 @@ public class ActivityDiagram extends CucaDiagram {
|
||||
private IEntity lastEntityBrancheConsulted;
|
||||
private ConditionalContext currentContext;
|
||||
|
||||
public ActivityDiagram(ThemeStyle style, UmlSource source, ISkinSimple skinParam) {
|
||||
super(style, source, UmlDiagramType.ACTIVITY, skinParam);
|
||||
public ActivityDiagram(UmlSource source, ISkinSimple skinParam) {
|
||||
super(source, UmlDiagramType.ACTIVITY, skinParam);
|
||||
setNamespaceSeparator(null);
|
||||
}
|
||||
|
||||
|
@ -46,7 +46,6 @@ import net.sourceforge.plantuml.activitydiagram.command.CommandIf;
|
||||
import net.sourceforge.plantuml.activitydiagram.command.CommandLinkActivity;
|
||||
import net.sourceforge.plantuml.activitydiagram.command.CommandLinkLongActivity;
|
||||
import net.sourceforge.plantuml.activitydiagram.command.CommandPartition;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.classdiagram.command.CommandHideShow2;
|
||||
import net.sourceforge.plantuml.command.Command;
|
||||
import net.sourceforge.plantuml.command.CommandFootboxIgnored;
|
||||
@ -60,8 +59,8 @@ import net.sourceforge.plantuml.core.UmlSource;
|
||||
public class ActivityDiagramFactory extends PSystemCommandFactory {
|
||||
|
||||
@Override
|
||||
public ActivityDiagram createEmptyDiagram(ThemeStyle style, UmlSource source, ISkinSimple skinParam) {
|
||||
return new ActivityDiagram(style, source, skinParam);
|
||||
public ActivityDiagram createEmptyDiagram(UmlSource source, ISkinSimple skinParam) {
|
||||
return new ActivityDiagram(source, skinParam);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -135,7 +135,7 @@ public class CommandIf extends SingleLineCommand2<ActivityDiagram> {
|
||||
|
||||
}
|
||||
|
||||
link.applyStyle(diagram.getSkinParam().getThemeStyle(), arg.getLazzy("ARROW_STYLE", 0));
|
||||
link.applyStyle(arg.getLazzy("ARROW_STYLE", 0));
|
||||
diagram.addLink(link);
|
||||
|
||||
return CommandExecutionResult.ok();
|
||||
|
@ -135,7 +135,7 @@ public class CommandLinkActivity extends SingleLineCommand2<ActivityDiagram> {
|
||||
if (arg.get("BACKCOLOR", 0) != null) {
|
||||
String s = arg.get("BACKCOLOR", 0);
|
||||
entity1.setSpecificColorTOBEREMOVED(ColorType.BACK,
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s));
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(s));
|
||||
}
|
||||
|
||||
final IEntity entity2 = getEntity(diagram, arg, false);
|
||||
@ -145,7 +145,7 @@ public class CommandLinkActivity extends SingleLineCommand2<ActivityDiagram> {
|
||||
if (arg.get("BACKCOLOR2", 0) != null) {
|
||||
String s = arg.get("BACKCOLOR2", 0);
|
||||
entity2.setSpecificColorTOBEREMOVED(ColorType.BACK,
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s));
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(s));
|
||||
}
|
||||
if (arg.get("STEREOTYPE2", 0) != null)
|
||||
entity2.setStereotype(Stereotype.build(arg.get("STEREOTYPE2", 0)));
|
||||
@ -180,7 +180,7 @@ public class CommandLinkActivity extends SingleLineCommand2<ActivityDiagram> {
|
||||
link.setUrl(urlLink);
|
||||
}
|
||||
|
||||
link.applyStyle(diagram.getSkinParam().getThemeStyle(), arg.getLazzy("ARROW_STYLE", 0));
|
||||
link.applyStyle(arg.getLazzy("ARROW_STYLE", 0));
|
||||
diagram.addLink(link);
|
||||
|
||||
return CommandExecutionResult.ok();
|
||||
|
@ -131,7 +131,7 @@ public class CommandLinkLongActivity extends CommandMultilines2<ActivityDiagram>
|
||||
final String stringColor = line0.get("BACKCOLOR", 0);
|
||||
if (stringColor != null) {
|
||||
entity1.setSpecificColorTOBEREMOVED(ColorType.BACK, diagram.getSkinParam().getIHtmlColorSet()
|
||||
.getColor(diagram.getSkinParam().getThemeStyle(), stringColor));
|
||||
.getColor(stringColor));
|
||||
}
|
||||
final StringBuilder sb = new StringBuilder();
|
||||
|
||||
@ -199,7 +199,7 @@ public class CommandLinkLongActivity extends CommandMultilines2<ActivityDiagram>
|
||||
if (lineLast.get(4) != null) {
|
||||
String s = lineLast.get(4);
|
||||
entity2.setSpecificColorTOBEREMOVED(ColorType.BACK,
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s));
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(s));
|
||||
}
|
||||
|
||||
final String arrowBody1 = CommandLinkClass.notNull(line0.get("ARROW_BODY1", 0));
|
||||
@ -228,7 +228,7 @@ public class CommandLinkLongActivity extends CommandMultilines2<ActivityDiagram>
|
||||
link.setUrl(urlLink);
|
||||
}
|
||||
|
||||
link.applyStyle(diagram.getSkinParam().getThemeStyle(), line0.getLazzy("ARROW_STYLE", 0));
|
||||
link.applyStyle(line0.getLazzy("ARROW_STYLE", 0));
|
||||
diagram.addLink(link);
|
||||
|
||||
return CommandExecutionResult.ok();
|
||||
|
@ -95,8 +95,7 @@ public class CommandPartition extends SingleLineCommand2<ActivityDiagram> {
|
||||
NamespaceStrategy.SINGLE);
|
||||
final IEntity p = diagram.getCurrentGroup();
|
||||
|
||||
final Colors colors = color().getColor(diagram.getSkinParam().getThemeStyle(), arg,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
final Colors colors = color().getColor(arg, diagram.getSkinParam().getIHtmlColorSet());
|
||||
if (colors.isEmpty() == false) {
|
||||
p.setColors(colors);
|
||||
}
|
||||
|
@ -46,7 +46,6 @@ import net.sourceforge.plantuml.UmlDiagramType;
|
||||
import net.sourceforge.plantuml.Url;
|
||||
import net.sourceforge.plantuml.activitydiagram3.ftile.BoxStyle;
|
||||
import net.sourceforge.plantuml.activitydiagram3.ftile.Swimlanes;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.command.CommandExecutionResult;
|
||||
import net.sourceforge.plantuml.core.DiagramDescription;
|
||||
import net.sourceforge.plantuml.core.ImageData;
|
||||
@ -75,8 +74,8 @@ public class ActivityDiagram3 extends UmlDiagram {
|
||||
|
||||
private final Swimlanes swinlanes = new Swimlanes(getSkinParam(), getPragma());
|
||||
|
||||
public ActivityDiagram3(ThemeStyle style, UmlSource source, ISkinSimple skinParam) {
|
||||
super(style, source, UmlDiagramType.ACTIVITY, skinParam);
|
||||
public ActivityDiagram3(UmlSource source, ISkinSimple skinParam) {
|
||||
super(source, UmlDiagramType.ACTIVITY, skinParam);
|
||||
}
|
||||
|
||||
private void manageSwimlaneStrategy() {
|
||||
|
@ -60,7 +60,6 @@ import net.sourceforge.plantuml.activitydiagram3.command.CommandFork3;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandForkAgain3;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandForkEnd3;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandGoto;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandGroup3;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandGroupEnd3;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandIf2;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandIf4;
|
||||
@ -84,7 +83,6 @@ import net.sourceforge.plantuml.activitydiagram3.command.CommandSwimlane2;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandSwitch;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandWhile3;
|
||||
import net.sourceforge.plantuml.activitydiagram3.command.CommandWhileEnd3;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.command.Command;
|
||||
import net.sourceforge.plantuml.command.CommandDecoratorMultine;
|
||||
import net.sourceforge.plantuml.command.CommandFootboxIgnored;
|
||||
@ -105,7 +103,7 @@ public class ActivityDiagramFactory3 extends PSystemCommandFactory {
|
||||
cmds.add(new CommandSwimlane2());
|
||||
cmds.add(new CommandPartition3());
|
||||
cmds.add(new CommandEndPartition3());
|
||||
cmds.add(new CommandGroup3());
|
||||
// cmds.add(new CommandGroup3());
|
||||
cmds.add(new CommandGroupEnd3());
|
||||
cmds.add(new CommandArrow3());
|
||||
cmds.add(new CommandArrowLong3());
|
||||
@ -162,8 +160,8 @@ public class ActivityDiagramFactory3 extends PSystemCommandFactory {
|
||||
}
|
||||
|
||||
@Override
|
||||
public ActivityDiagram3 createEmptyDiagram(ThemeStyle style, UmlSource source, ISkinSimple skinParam) {
|
||||
return new ActivityDiagram3(style, source, skinParam);
|
||||
public ActivityDiagram3 createEmptyDiagram(UmlSource source, ISkinSimple skinParam) {
|
||||
return new ActivityDiagram3(source, skinParam);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -100,7 +100,7 @@ public class Branch {
|
||||
|
||||
final Style style = getDefaultStyleDefinitionDiamond().getMergedStyle(styleBuilder);
|
||||
this.color = color == null ? style.value(PName.BackGroundColor).asColor(
|
||||
styleBuilder.getSkinParam().getThemeStyle(), styleBuilder.getSkinParam().getIHtmlColorSet()) : color;
|
||||
styleBuilder.getSkinParam().getIHtmlColorSet()) : color;
|
||||
|
||||
this.list = new InstructionList(swimlane);
|
||||
}
|
||||
@ -243,8 +243,7 @@ public class Branch {
|
||||
|
||||
final Style style = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final LineBreakStrategy lineBreak = style.wrapWidth();
|
||||
final FontConfiguration fcArrow = style.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcArrow = style.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
|
||||
return display.create0(fcArrow, HorizontalAlignment.LEFT, skinParam(), lineBreak, CreoleMode.SIMPLE_LINE, null,
|
||||
null);
|
||||
|
@ -113,8 +113,7 @@ public class CommandActivity3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
url = urlBuilder.getUrl(arg.get("URL", 0));
|
||||
}
|
||||
|
||||
Colors colors = color().getColor(diagram.getSkinParam().getThemeStyle(), arg,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
Colors colors = color().getColor(arg, diagram.getSkinParam().getIHtmlColorSet());
|
||||
final String stereo = arg.get("STEREO", 0);
|
||||
Stereotype stereotype = null;
|
||||
if (stereo != null) {
|
||||
|
@ -77,8 +77,7 @@ public class CommandActivityLong3 extends CommandMultilines2<ActivityDiagram3> {
|
||||
protected CommandExecutionResult executeNow(ActivityDiagram3 diagram, BlocLines lines) throws NoSuchColorException {
|
||||
lines = lines.removeEmptyColumns();
|
||||
final RegexResult line0 = getStartingPattern().matcher(lines.getFirst().getTrimmed().getString());
|
||||
final Colors colors = color().getColor(diagram.getSkinParam().getThemeStyle(), line0,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
final Colors colors = color().getColor(line0, diagram.getSkinParam().getIHtmlColorSet());
|
||||
|
||||
final BoxStyle style = BoxStyle.fromChar(lines.getLastChar());
|
||||
lines = lines.removeStartingAndEnding(line0.get("DATA", 0), 1);
|
||||
|
@ -66,7 +66,7 @@ public class CommandCircleSpot3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
diagram.addSpot(arg.get("SPOT", 0), color);
|
||||
return CommandExecutionResult.ok();
|
||||
}
|
||||
|
@ -100,7 +100,7 @@ public class CommandElseIf2 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
final String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
|
||||
String test = arg.get("TEST", 0);
|
||||
if (test.length() == 0) {
|
||||
|
@ -1,70 +0,0 @@
|
||||
/* ========================================================================
|
||||
* PlantUML : a free UML diagram generator
|
||||
* ========================================================================
|
||||
*
|
||||
* (C) Copyright 2009-2013, Arnaud Roques
|
||||
*
|
||||
* Project Info: http://plantuml.com
|
||||
*
|
||||
* If you like this project or if you find it useful, you can support us at:
|
||||
*
|
||||
* http://plantuml.com/patreon (only 1$ per month!)
|
||||
* http://plantuml.com/paypal
|
||||
*
|
||||
* This file is part of PlantUML.
|
||||
*
|
||||
* PlantUML is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* PlantUML distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
||||
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
|
||||
* License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
|
||||
* USA.
|
||||
*
|
||||
*
|
||||
* Original Author: Arnaud Roques
|
||||
*
|
||||
*
|
||||
*/
|
||||
package net.sourceforge.plantuml.activitydiagram3.command;
|
||||
|
||||
import net.sourceforge.plantuml.LineLocation;
|
||||
import net.sourceforge.plantuml.activitydiagram3.ActivityDiagram3;
|
||||
import net.sourceforge.plantuml.command.CommandExecutionResult;
|
||||
import net.sourceforge.plantuml.command.SingleLineCommand2;
|
||||
import net.sourceforge.plantuml.command.regex.IRegex;
|
||||
import net.sourceforge.plantuml.command.regex.RegexConcat;
|
||||
import net.sourceforge.plantuml.command.regex.RegexLeaf;
|
||||
import net.sourceforge.plantuml.command.regex.RegexResult;
|
||||
import net.sourceforge.plantuml.cucadiagram.Display;
|
||||
import net.sourceforge.plantuml.graphic.USymbols;
|
||||
|
||||
public class CommandGroup3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
|
||||
public CommandGroup3() {
|
||||
super(getRegexConcat());
|
||||
}
|
||||
|
||||
static IRegex getRegexConcat() {
|
||||
return RegexConcat.build(CommandGroup3.class.getName(), RegexLeaf.start(), //
|
||||
new RegexLeaf("group"), //
|
||||
RegexLeaf.spaceZeroOrMore(), //
|
||||
new RegexLeaf("NAME", "(.*)"), //
|
||||
new RegexLeaf(";?"), //
|
||||
RegexLeaf.end());
|
||||
}
|
||||
|
||||
@Override
|
||||
protected CommandExecutionResult executeArg(ActivityDiagram3 diagram, LineLocation location, RegexResult arg) {
|
||||
diagram.startGroup(Display.getWithNewlines(arg.get("NAME", 0)), null, null, null, USymbols.FRAME, 0);
|
||||
return CommandExecutionResult.ok();
|
||||
}
|
||||
|
||||
}
|
@ -83,7 +83,7 @@ public class CommandIf2 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
final String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
|
||||
String test = arg.get("TEST", 0);
|
||||
if (test.length() == 0) {
|
||||
|
@ -80,7 +80,7 @@ public class CommandIf4 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
final String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
|
||||
String test = arg.get("TEST", 0);
|
||||
if (test.length() == 0) {
|
||||
|
@ -67,7 +67,7 @@ public class CommandLink3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
final String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
if (color != null) {
|
||||
diagram.setColorNextArrow(Rainbow.fromColor(color, null));
|
||||
}
|
||||
|
@ -78,8 +78,7 @@ public class CommandNote3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
@Override
|
||||
protected CommandExecutionResult executeArg(ActivityDiagram3 diagram, LineLocation location, RegexResult arg)
|
||||
throws NoSuchColorException {
|
||||
final Colors colors = color().getColor(diagram.getSkinParam().getThemeStyle(), arg,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
final Colors colors = color().getColor(arg, diagram.getSkinParam().getIHtmlColorSet());
|
||||
final Display note = Display.getWithNewlines(arg.get("NOTE", 0));
|
||||
final NotePosition position = NotePosition.defaultLeft(arg.get("POSITION", 0));
|
||||
final NoteType type = NoteType.defaultType(arg.get("TYPE", 0));
|
||||
|
@ -78,8 +78,7 @@ public class CommandNoteLong3 extends CommandMultilines2<ActivityDiagram3> {
|
||||
final NotePosition position = NotePosition.defaultLeft(line0.get("POSITION", 0));
|
||||
final NoteType type = NoteType.defaultType(line0.get("TYPE", 0));
|
||||
final Display note = lines.toDisplay();
|
||||
final Colors colors = color().getColor(diagram.getSkinParam().getThemeStyle(), line0,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
final Colors colors = color().getColor(line0, diagram.getSkinParam().getIHtmlColorSet());
|
||||
return diagram.addNote(note, position, type, colors);
|
||||
}
|
||||
|
||||
|
@ -38,6 +38,7 @@ package net.sourceforge.plantuml.activitydiagram3.command;
|
||||
import net.sourceforge.plantuml.LineLocation;
|
||||
import net.sourceforge.plantuml.StringUtils;
|
||||
import net.sourceforge.plantuml.activitydiagram3.ActivityDiagram3;
|
||||
import net.sourceforge.plantuml.activitydiagram3.ftile.vcompact.FtileGroup;
|
||||
import net.sourceforge.plantuml.command.CommandExecutionResult;
|
||||
import net.sourceforge.plantuml.command.SingleLineCommand2;
|
||||
import net.sourceforge.plantuml.command.regex.IRegex;
|
||||
@ -68,13 +69,13 @@ public class CommandPartition3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
|
||||
static IRegex getRegexConcat() {
|
||||
return RegexConcat.build(CommandPartition3.class.getName(), RegexLeaf.start(), //
|
||||
new RegexLeaf("TYPE", "(partition|package|rectangle|card)"), //
|
||||
new RegexLeaf("TYPE", "(partition|package|rectangle|card|group)"), //
|
||||
RegexLeaf.spaceOneOrMore(), //
|
||||
new RegexOptional(//
|
||||
new RegexConcat( //
|
||||
color("BACK1").getRegex(), //
|
||||
RegexLeaf.spaceOneOrMore())), //
|
||||
new RegexLeaf("NAME", "([%g][^%g]+[%g]|\\S+)"), //
|
||||
new RegexLeaf("NAME", "([%g][^%g]+[%g]|.*?)"), //
|
||||
new RegexOptional(//
|
||||
new RegexConcat( //
|
||||
RegexLeaf.spaceOneOrMore(), //
|
||||
@ -87,8 +88,8 @@ public class CommandPartition3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
}
|
||||
|
||||
private USymbol getUSymbol(String type) {
|
||||
if ("card".equalsIgnoreCase(type))
|
||||
return USymbols.CARD;
|
||||
if ("partition".equalsIgnoreCase(type))
|
||||
return USymbols.PARTITION;
|
||||
|
||||
if ("package".equalsIgnoreCase(type))
|
||||
return USymbols.PACKAGE;
|
||||
@ -96,27 +97,27 @@ public class CommandPartition3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
if ("rectangle".equalsIgnoreCase(type))
|
||||
return USymbols.RECTANGLE;
|
||||
|
||||
return USymbols.FRAME;
|
||||
if ("card".equalsIgnoreCase(type))
|
||||
return USymbols.CARD;
|
||||
|
||||
if ("group".equalsIgnoreCase(type))
|
||||
return USymbols.GROUP;
|
||||
|
||||
throw new IllegalArgumentException();
|
||||
}
|
||||
|
||||
private static ColorParser color(String id) {
|
||||
return ColorParser.simpleColor(ColorType.BACK, id);
|
||||
}
|
||||
|
||||
private StyleSignatureBasic getDefaultStyleDefinitionPartition(USymbol symbol) {
|
||||
if (symbol == USymbols.RECTANGLE)
|
||||
return StyleSignatureBasic.of(SName.root, SName.element, SName.activityDiagram, SName.rectangle);
|
||||
return StyleSignatureBasic.of(SName.root, SName.element, SName.activityDiagram, SName.partition);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected CommandExecutionResult executeArg(ActivityDiagram3 diagram, LineLocation location, RegexResult arg)
|
||||
throws NoSuchColorException {
|
||||
final String partitionTitle = StringUtils.eventuallyRemoveStartingAndEndingDoubleQuote(arg.get("NAME", 0));
|
||||
|
||||
final String b1 = arg.get("BACK1", 0);
|
||||
final Colors colors = color(b1 == null ? "BACK2" : "BACK1").getColor(diagram.getSkinParam().getThemeStyle(),
|
||||
arg, diagram.getSkinParam().getIHtmlColorSet());
|
||||
final Colors colors = color(b1 == null ? "BACK2" : "BACK1").getColor(arg,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
|
||||
final USymbol symbol = getUSymbol(arg.get("TYPE", 0));
|
||||
final String stereo = arg.get("STEREO", 0);
|
||||
@ -124,14 +125,12 @@ public class CommandPartition3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
|
||||
// Warning : titleColor unused in FTileGroupW
|
||||
|
||||
final Style stylePartition = getDefaultStyleDefinitionPartition(symbol).withTOBECHANGED(stereotype)
|
||||
final Style stylePartition = FtileGroup.getStyleSignature(symbol).withTOBECHANGED(stereotype)
|
||||
.getMergedStyle(diagram.getSkinParam().getCurrentStyleBuilder());
|
||||
final HColor borderColor = stylePartition.value(PName.LineColor).asColor(diagram.getSkinParam().getThemeStyle(),
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
final HColor borderColor = stylePartition.value(PName.LineColor).asColor(diagram.getSkinParam().getIHtmlColorSet());
|
||||
HColor backColor = colors.getColor(ColorType.BACK);
|
||||
if (backColor == null)
|
||||
backColor = stylePartition.value(PName.BackGroundColor).asColor(diagram.getSkinParam().getThemeStyle(),
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
backColor = stylePartition.value(PName.BackGroundColor).asColor(diagram.getSkinParam().getIHtmlColorSet());
|
||||
|
||||
final HColor titleColor = HColors.BLUE;// stylePartition.value(PName.FontColor).asColor(diagram.getSkinParam().getIHtmlColorSet());
|
||||
final double roundCorner = stylePartition.value(PName.RoundCorner).asDouble();
|
||||
|
@ -81,7 +81,7 @@ public class CommandRepeat3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
final String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
final Display label = Display.getWithNewlines(arg.get("LABEL", 0));
|
||||
final BoxStyle boxStyle;
|
||||
final String styleString = arg.get("STYLE", 0);
|
||||
@ -90,8 +90,7 @@ public class CommandRepeat3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
} else {
|
||||
boxStyle = BoxStyle.fromChar(styleString.charAt(0));
|
||||
}
|
||||
Colors colors = color().getColor(diagram.getSkinParam().getThemeStyle(), arg,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
Colors colors = color().getColor(arg, diagram.getSkinParam().getIHtmlColorSet());
|
||||
final String stereo = arg.get("STEREO", 0);
|
||||
if (stereo != null) {
|
||||
final Stereotype stereotype = Stereotype.build(stereo);
|
||||
|
@ -69,7 +69,7 @@ public class CommandSwimlane extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
final String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
final String name = arg.get("SWIMLANE", 0);
|
||||
final Display label = Display.getWithNewlines(arg.get("LABEL", 0));
|
||||
return diagram.swimlane(name, color, label);
|
||||
|
@ -77,7 +77,7 @@ public class CommandSwimlane2 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
final String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
final String name = arg.get("SWIMLANE", 0);
|
||||
final Display label = Display.getWithNewlines(arg.get("LABEL", 0));
|
||||
return diagram.swimlane(name, color, label);
|
||||
|
@ -71,7 +71,7 @@ public class CommandSwitch extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
final String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
|
||||
String test = arg.get("TEST", 0);
|
||||
if (test.length() == 0)
|
||||
|
@ -77,7 +77,7 @@ public class CommandWhile3 extends SingleLineCommand2<ActivityDiagram3> {
|
||||
throws NoSuchColorException {
|
||||
final String s = arg.get("COLOR", 0);
|
||||
final HColor color = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
diagram.doWhile(Display.getWithNewlines(arg.get("TEST", 0)), Display.getWithNewlines(arg.get("YES", 0)), color);
|
||||
|
||||
return CommandExecutionResult.ok();
|
||||
|
@ -86,13 +86,13 @@ public class FtileFactoryDelegator implements FtileFactory {
|
||||
final LinkRendering linkRendering = tile.getInLinkRendering();
|
||||
if (linkRendering == null) {
|
||||
final Style style = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
return Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle());
|
||||
return Rainbow.build(style, skinParam().getIHtmlColorSet());
|
||||
} else {
|
||||
color = linkRendering.getRainbow();
|
||||
}
|
||||
if (color.size() == 0) {
|
||||
final Style style = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
return Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle());
|
||||
return Rainbow.build(style, skinParam().getIHtmlColorSet());
|
||||
}
|
||||
return color;
|
||||
}
|
||||
@ -103,8 +103,7 @@ public class FtileFactoryDelegator implements FtileFactory {
|
||||
return null;
|
||||
|
||||
final Style style = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final FontConfiguration fontConfiguration = style.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fontConfiguration = style.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
|
||||
return display.create7(fontConfiguration, HorizontalAlignment.LEFT, skinParam(), CreoleMode.SIMPLE_LINE);
|
||||
}
|
||||
|
@ -88,8 +88,7 @@ public class LaneDivider extends AbstractTextBlock {
|
||||
final UShape back = new UEmpty(x1 + x2, 1);
|
||||
ug.draw(back);
|
||||
|
||||
final HColor color = getStyle().value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor color = getStyle().value(PName.LineColor).asColor(skinParam.getIHtmlColorSet());
|
||||
final UStroke thickness = getStyle().getStroke();
|
||||
|
||||
ug.apply(UTranslate.dx(x1)).apply(thickness).apply(color).draw(ULine.vline(height));
|
||||
|
@ -255,8 +255,7 @@ public class Swimlanes extends AbstractTextBlock implements TextBlock, Styleable
|
||||
|
||||
private TextBlock getTitle(Swimlane swimlane) {
|
||||
final HorizontalAlignment horizontalAlignment = HorizontalAlignment.LEFT;
|
||||
final FontConfiguration fontConfiguration = getStyle().getFontConfiguration(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final FontConfiguration fontConfiguration = getStyle().getFontConfiguration(skinParam.getIHtmlColorSet());
|
||||
|
||||
LineBreakStrategy wrap = getWrap();
|
||||
if (wrap.isAuto())
|
||||
@ -327,8 +326,7 @@ public class Swimlanes extends AbstractTextBlock implements TextBlock, Styleable
|
||||
}
|
||||
|
||||
private void drawTitlesBackground(UGraphic ug) {
|
||||
final HColor color = getStyle().value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor color = getStyle().value(PName.BackGroundColor).asColor(skinParam.getIHtmlColorSet());
|
||||
|
||||
if (color != null) {
|
||||
final double titleHeight = getTitlesHeight(ug.getStringBounder());
|
||||
|
@ -133,8 +133,7 @@ public abstract class AbstractParallelFtilesBuilder {
|
||||
return null;
|
||||
|
||||
final Style style = getStyleSignatureArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final FontConfiguration fontConfiguration = style.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fontConfiguration = style.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
|
||||
return display.create7(fontConfiguration, HorizontalAlignment.LEFT, skinParam(), CreoleMode.SIMPLE_LINE);
|
||||
}
|
||||
|
@ -69,10 +69,8 @@ public class FloatingNote extends AbstractTextBlock implements Stencil, TextBloc
|
||||
.getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final LineBreakStrategy wrapWidth = style.wrapWidth();
|
||||
final FontConfiguration fc = FontConfiguration.create(skinParam, style);
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(skinParam.getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getIHtmlColorSet());
|
||||
final UStroke stroke = style.getStroke();
|
||||
final double shadowing = style.value(PName.Shadowing).asDouble();
|
||||
|
||||
|
@ -74,16 +74,12 @@ public class FtileFactoryDelegatorIf extends FtileFactoryDelegator {
|
||||
final Style styleArrow = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final Style styleDiamond = getDefaultStyleDefinitionDiamond()
|
||||
.getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final HColor borderColor = styleDiamond.value(PName.LineColor).asColor(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final HColor borderColor = styleDiamond.value(PName.LineColor).asColor(skinParam().getIHtmlColorSet());
|
||||
final HColor backColor = branch0.getColor() == null ? styleDiamond.value(PName.BackGroundColor)
|
||||
.asColor(skinParam().getThemeStyle(), skinParam().getIHtmlColorSet()) : branch0.getColor();
|
||||
final Rainbow arrowColor = Rainbow.build(styleArrow, skinParam().getIHtmlColorSet(),
|
||||
skinParam().getThemeStyle());
|
||||
final FontConfiguration fcTest = styleDiamond.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcArrow = styleArrow.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
.asColor(skinParam().getIHtmlColorSet()) : branch0.getColor();
|
||||
final Rainbow arrowColor = Rainbow.build(styleArrow, skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcTest = styleDiamond.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcArrow = styleArrow.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
|
||||
if (thens.size() > 1) {
|
||||
if (pragma.useVerticalIf()/* OptionFlags.USE_IF_VERTICAL */)
|
||||
|
@ -79,16 +79,11 @@ public class FtileFactoryDelegatorRepeat extends FtileFactoryDelegator {
|
||||
final Style styleArrow = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final Style styleDiamond = getDefaultStyleDefinitionDiamond()
|
||||
.getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final HColor borderColor = styleDiamond.value(PName.LineColor).asColor(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final HColor diamondColor = styleDiamond.value(PName.BackGroundColor).asColor(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final Rainbow arrowColor = Rainbow.build(styleArrow, skinParam().getIHtmlColorSet(),
|
||||
skinParam().getThemeStyle());
|
||||
final FontConfiguration fcDiamond = styleDiamond.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcArrow = styleArrow.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final HColor borderColor = styleDiamond.value(PName.LineColor).asColor(skinParam().getIHtmlColorSet());
|
||||
final HColor diamondColor = styleDiamond.value(PName.BackGroundColor).asColor(skinParam().getIHtmlColorSet());
|
||||
final Rainbow arrowColor = Rainbow.build(styleArrow, skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcDiamond = styleDiamond.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcArrow = styleArrow.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
|
||||
final LinkRendering endRepeatLinkRendering = repeat.getOutLinkRendering();
|
||||
final Rainbow endRepeatLinkColor = endRepeatLinkRendering == null ? null : endRepeatLinkRendering.getRainbow();
|
||||
|
@ -110,7 +110,7 @@ public class FtileFactoryDelegatorSwitch extends FtileFactoryDelegator {
|
||||
}
|
||||
|
||||
final Style style = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final Rainbow arrowColor = Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle());
|
||||
final Rainbow arrowColor = Rainbow.build(style, skinParam().getIHtmlColorSet());
|
||||
|
||||
if (ftiles.size() == 1) {
|
||||
final FtileSwitchWithOneLink result = new FtileSwitchWithOneLink(ftiles, branches, swimlane, diamond1,
|
||||
@ -129,12 +129,10 @@ public class FtileFactoryDelegatorSwitch extends FtileFactoryDelegator {
|
||||
|
||||
final Style style = getDefaultStyleDefinitionDiamond().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
lineBreak = style.wrapWidth();
|
||||
final FontConfiguration fcDiamond = style.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcDiamond = style.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam().getIHtmlColorSet());
|
||||
final HColor backColor = branch0.getColor() == null ? style.value(PName.BackGroundColor)
|
||||
.asColor(skinParam().getThemeStyle(), skinParam().getIHtmlColorSet()) : branch0.getColor();
|
||||
.asColor(skinParam().getIHtmlColorSet()) : branch0.getColor();
|
||||
|
||||
final TextBlock tbTest;
|
||||
if (Display.isNull(test) || test.isWhite())
|
||||
@ -149,10 +147,9 @@ public class FtileFactoryDelegatorSwitch extends FtileFactoryDelegator {
|
||||
private Ftile getDiamond2(Swimlane swimlane, Branch branch0) {
|
||||
|
||||
final Style style = getDefaultStyleDefinitionDiamond().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam().getIHtmlColorSet());
|
||||
final HColor backColor = branch0.getColor() == null ? style.value(PName.BackGroundColor)
|
||||
.asColor(skinParam().getThemeStyle(), skinParam().getIHtmlColorSet()) : branch0.getColor();
|
||||
.asColor(skinParam().getIHtmlColorSet()) : branch0.getColor();
|
||||
|
||||
return new FtileDiamondInside(TextBlockUtils.empty(0, 0), branch0.skinParam(), backColor, borderColor,
|
||||
swimlane);
|
||||
|
@ -76,16 +76,11 @@ public class FtileFactoryDelegatorWhile extends FtileFactoryDelegator {
|
||||
final Style styleArrow = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final Style styleDiamond = getDefaultStyleDefinitionDiamond()
|
||||
.getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final HColor borderColor = styleDiamond.value(PName.LineColor).asColor(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final HColor backColor = styleDiamond.value(PName.BackGroundColor).asColor(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final Rainbow arrowColor = Rainbow.build(styleArrow, skinParam().getIHtmlColorSet(),
|
||||
skinParam().getThemeStyle());
|
||||
final FontConfiguration fontArrow = styleArrow.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcTest = styleDiamond.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final HColor borderColor = styleDiamond.value(PName.LineColor).asColor(skinParam().getIHtmlColorSet());
|
||||
final HColor backColor = styleDiamond.value(PName.BackGroundColor).asColor(skinParam().getIHtmlColorSet());
|
||||
final Rainbow arrowColor = Rainbow.build(styleArrow, skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fontArrow = styleArrow.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fcTest = styleDiamond.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
|
||||
incoming1 = ensureColor(incoming1, arrowColor);
|
||||
incoming2 = ensureColor(incoming2, arrowColor);
|
||||
|
@ -83,7 +83,12 @@ public class FtileGroup extends AbstractFtile {
|
||||
private final double roundCorner;
|
||||
|
||||
final public StyleSignatureBasic getStyleSignature() {
|
||||
return StyleSignatureBasic.of(SName.root, SName.element, SName.activityDiagram, SName.partition);
|
||||
return getStyleSignature(type);
|
||||
}
|
||||
|
||||
final static public StyleSignatureBasic getStyleSignature(USymbol symbol) {
|
||||
return StyleSignatureBasic.of(SName.root, SName.element, SName.activityDiagram, symbol.getSName(),
|
||||
SName.composite);
|
||||
}
|
||||
|
||||
public FtileGroup(Ftile inner, Display title, HColor backColor, HColor titleColor, ISkinParam skinParam,
|
||||
@ -94,13 +99,13 @@ public class FtileGroup extends AbstractFtile {
|
||||
this.inner = FtileUtils.addHorizontalMargin(inner, 10);
|
||||
|
||||
final Style style = getStyleSignature().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(getIHtmlColorSet());
|
||||
this.shadowing = style.value(PName.Shadowing).asDouble();
|
||||
this.backColor = backColor == null
|
||||
? style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet())
|
||||
? style.value(PName.BackGroundColor).asColor(getIHtmlColorSet())
|
||||
: backColor;
|
||||
this.borderColor = borderColor == null
|
||||
? style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet())
|
||||
? style.value(PName.LineColor).asColor(getIHtmlColorSet())
|
||||
: borderColor;
|
||||
final UStroke thickness = style.getStroke();
|
||||
|
||||
|
@ -104,9 +104,8 @@ public class FtileNoteAlone extends AbstractFtile implements Stencil, Styleable
|
||||
this.withOutPoint = withOutPoint;
|
||||
|
||||
final Style style = getStyleSignature().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(),
|
||||
getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
final double shadowing = style.value(PName.Shadowing).asDouble();
|
||||
final LineBreakStrategy wrapWidth = style.wrapWidth();
|
||||
final UStroke stroke = style.getStroke();
|
||||
|
@ -137,10 +137,9 @@ public class FtileWithNoteOpale extends AbstractFtile implements Stencil, Stylea
|
||||
|
||||
final Style style = getStyleSignature().getMergedStyle(skinParam.getCurrentStyleBuilder())
|
||||
.eventuallyOverride(note.getColors());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(),
|
||||
getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(getIHtmlColorSet());
|
||||
final double shadowing = style.value(PName.Shadowing).asDouble();
|
||||
final LineBreakStrategy wrapWidth = style.wrapWidth();
|
||||
final UStroke stroke = style.getStroke();
|
||||
|
@ -109,11 +109,9 @@ public class FtileWithNotes extends AbstractFtile {
|
||||
|
||||
final Style style = getStyleSignature().getMergedStyle(skinParam.getCurrentStyleBuilder())
|
||||
.eventuallyOverride(note.getColors());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(),
|
||||
getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(getIHtmlColorSet());
|
||||
final double shadowing = style.value(PName.Shadowing).asDouble();
|
||||
final LineBreakStrategy wrapWidth = style.wrapWidth();
|
||||
final UStroke stroke = style.getStroke();
|
||||
|
@ -133,7 +133,7 @@ public class ParallelBuilderFork extends AbstractParallelFtilesBuilder {
|
||||
double x = 0;
|
||||
for (Ftile tmp : list99) {
|
||||
final XDimension2D dim = tmp.calculateDimension(getStringBounder());
|
||||
final Rainbow def = Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle());
|
||||
final Rainbow def = Rainbow.build(style, skinParam().getIHtmlColorSet());
|
||||
final Rainbow rainbow = tmp.getInLinkRendering().getRainbow(def);
|
||||
conns.add(new ConnectionIn(black, tmp, x, rainbow));
|
||||
x += dim.getWidth();
|
||||
@ -192,7 +192,7 @@ public class ParallelBuilderFork extends AbstractParallelFtilesBuilder {
|
||||
double x = 0;
|
||||
for (Ftile tmp : list99) {
|
||||
final XDimension2D dim = tmp.calculateDimension(getStringBounder());
|
||||
final Rainbow def = Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle());
|
||||
final Rainbow def = Rainbow.build(style, skinParam().getIHtmlColorSet());
|
||||
final Rainbow rainbow = tmp.getOutLinkRendering().getRainbow(def);
|
||||
if (tmp.calculateDimension(getStringBounder()).hasPointOut())
|
||||
conns.add(new ConnectionOut(tmp, out, x, rainbow, getJustBeforeBar2(middle, getStringBounder())));
|
||||
|
@ -78,7 +78,7 @@ public class ParallelBuilderMerge extends AbstractParallelFtilesBuilder {
|
||||
for (Ftile tmp : list99) {
|
||||
final XDimension2D dim = tmp.calculateDimension(getStringBounder());
|
||||
Style style = getStyleSignature().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final Rainbow def = Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle());
|
||||
final Rainbow def = Rainbow.build(style, skinParam().getIHtmlColorSet());
|
||||
final Rainbow rainbow = tmp.getInLinkRendering().getRainbow(def);
|
||||
conns.add(new ConnectionIn(black, tmp, x, rainbow));
|
||||
x += dim.getWidth();
|
||||
@ -95,10 +95,8 @@ public class ParallelBuilderMerge extends AbstractParallelFtilesBuilder {
|
||||
protected Ftile doStep2(Ftile inner, Ftile result) {
|
||||
final Style style = getStyleSignature().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final HColor backColor = style.value(PName.BackGroundColor).asColor(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam().getIHtmlColorSet());
|
||||
final HColor backColor = style.value(PName.BackGroundColor).asColor(skinParam().getIHtmlColorSet());
|
||||
|
||||
final Ftile out = new FtileDiamond(skinParam(), backColor, borderColor, swimlaneOutForStep2());
|
||||
result = new FtileAssemblySimple(result, out);
|
||||
@ -109,7 +107,7 @@ public class ParallelBuilderMerge extends AbstractParallelFtilesBuilder {
|
||||
for (Ftile tmp : list99) {
|
||||
final XDimension2D dim = tmp.calculateDimension(getStringBounder());
|
||||
final UTranslate translate0 = new UTranslate(x, barHeight);
|
||||
final Rainbow def = Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle());
|
||||
final Rainbow def = Rainbow.build(style, skinParam().getIHtmlColorSet());
|
||||
final Rainbow rainbow = tmp.getOutLinkRendering().getRainbow(def);
|
||||
if (tmp.calculateDimension(getStringBounder()).hasPointOut())
|
||||
conns.add(new ConnectionHorizontalThenVertical(tmp, out, rainbow, translate0, diamondTranslate));
|
||||
|
@ -78,7 +78,7 @@ public class ParallelBuilderSplit extends AbstractParallelFtilesBuilder {
|
||||
Ftile result = inner;
|
||||
final List<Connection> conns = new ArrayList<>();
|
||||
final Style style = getStyleSignature().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final Rainbow thinColor = Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle());
|
||||
final Rainbow thinColor = Rainbow.build(style, skinParam().getIHtmlColorSet());
|
||||
|
||||
final Ftile thin = new FtileThinSplit(skinParam(), getThin1Color(thinColor), list99.get(0).getSwimlaneIn());
|
||||
double x = 0;
|
||||
@ -93,7 +93,7 @@ public class ParallelBuilderSplit extends AbstractParallelFtilesBuilder {
|
||||
|
||||
final LinkRendering inLinkRendering = tmp.getInLinkRendering();
|
||||
final Rainbow rainbow = inLinkRendering
|
||||
.getRainbow(Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle()));
|
||||
.getRainbow(Rainbow.build(style, skinParam().getIHtmlColorSet()));
|
||||
|
||||
conns.add(new ConnectionIn(thin, tmp, x, rainbow));
|
||||
x += dim.getWidth();
|
||||
@ -117,7 +117,7 @@ public class ParallelBuilderSplit extends AbstractParallelFtilesBuilder {
|
||||
for (Ftile tmp : list99) {
|
||||
final LinkRendering inLinkRendering = tmp.getInLinkRendering();
|
||||
final Rainbow rainbow = inLinkRendering
|
||||
.getRainbow(Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle()));
|
||||
.getRainbow(Rainbow.build(style, skinParam().getIHtmlColorSet()));
|
||||
|
||||
if (rainbow.isInvisible() == false)
|
||||
return thinColor.getColor();
|
||||
@ -144,7 +144,7 @@ public class ParallelBuilderSplit extends AbstractParallelFtilesBuilder {
|
||||
final Style style = getStyleSignature().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final LinkRendering inLinkRendering = result.getInLinkRendering();
|
||||
final Rainbow thinColor = inLinkRendering
|
||||
.getRainbow(Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle()));
|
||||
.getRainbow(Rainbow.build(style, skinParam().getIHtmlColorSet()));
|
||||
|
||||
final Ftile out = new FtileThinSplit(skinParam(), thinColor.getColor(), swimlaneOutForStep2());
|
||||
result = new FtileAssemblySimple(result, out);
|
||||
@ -164,7 +164,7 @@ public class ParallelBuilderSplit extends AbstractParallelFtilesBuilder {
|
||||
|
||||
final LinkRendering outLinkRendering = tmp.getOutLinkRendering();
|
||||
final Rainbow rainbow = outLinkRendering
|
||||
.getRainbow(Rainbow.build(style, skinParam().getIHtmlColorSet(), skinParam().getThemeStyle()));
|
||||
.getRainbow(Rainbow.build(style, skinParam().getIHtmlColorSet()));
|
||||
|
||||
if (tmp.calculateDimension(getStringBounder()).hasPointOut())
|
||||
conns.add(new ConnectionOut(translate0, tmp, out, x, rainbow, getHeightOfMiddle(inner)));
|
||||
|
@ -111,16 +111,14 @@ public class VCompactFactory implements FtileFactory {
|
||||
|
||||
public Ftile start(Swimlane swimlane) {
|
||||
final Style style = getSignatureCircleStart().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final HColor color = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor color = style.value(PName.LineColor).asColor(skinParam.getIHtmlColorSet());
|
||||
|
||||
return new FtileCircleStart(skinParam(), color, swimlane, style);
|
||||
}
|
||||
|
||||
public Ftile stop(Swimlane swimlane) {
|
||||
final Style style = getSignatureCircleStop().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getIHtmlColorSet());
|
||||
final HColor backgroundColor = skinParam.getBackgroundColor();
|
||||
return new FtileCircleStop(skinParam(), backgroundColor, borderColor, swimlane, style);
|
||||
}
|
||||
@ -134,8 +132,7 @@ public class VCompactFactory implements FtileFactory {
|
||||
public Ftile end(Swimlane swimlane) {
|
||||
|
||||
final Style style = getSignatureCircleEnd().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getIHtmlColorSet());
|
||||
final HColor backgroundColor = skinParam.getBackgroundColor();
|
||||
|
||||
return new FtileCircleEnd(skinParam(), backgroundColor, borderColor, swimlane, style);
|
||||
|
@ -115,8 +115,8 @@ public class ConditionalBuilder {
|
||||
|
||||
final Style styleArrow = getStyleSignatureArrow().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final Style styleDiamond = getStyleSignatureDiamond().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
this.fontTest = styleDiamond.getFontConfiguration(skinParam.getThemeStyle(), skinParam.getIHtmlColorSet());
|
||||
this.fontArrow = styleArrow.getFontConfiguration(skinParam.getThemeStyle(), skinParam.getIHtmlColorSet());
|
||||
this.fontTest = styleDiamond.getFontConfiguration(skinParam.getIHtmlColorSet());
|
||||
this.fontArrow = styleArrow.getFontConfiguration(skinParam.getIHtmlColorSet());
|
||||
this.diamondLineBreak = styleDiamond.wrapWidth();
|
||||
this.labelLineBreak = styleArrow.wrapWidth();
|
||||
this.borderColor = borderColor;
|
||||
|
@ -101,8 +101,7 @@ public class FtileBlackBlock extends AbstractFtile {
|
||||
final Style style = getSignature().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final double shadowing = style.value(PName.Shadowing).asDouble();
|
||||
rect.setDeltaShadow(shadowing);
|
||||
final HColor colorBar = style.value(PName.BackGroundColor).asColor(skinParam().getThemeStyle(),
|
||||
getIHtmlColorSet());
|
||||
final HColor colorBar = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
|
||||
ug.apply(colorBar).apply(colorBar.bg()).draw(rect);
|
||||
final XDimension2D dimLabel = label.calculateDimension(ug.getStringBounder());
|
||||
|
@ -150,16 +150,16 @@ public class FtileBox extends AbstractFtile {
|
||||
this.swimlane = swimlane;
|
||||
|
||||
this.inRendering = LinkRendering
|
||||
.create(Rainbow.build(styleArrow, getIHtmlColorSet(), skinParam.getThemeStyle()));
|
||||
.create(Rainbow.build(styleArrow, getIHtmlColorSet()));
|
||||
Colors specBack = null;
|
||||
if (skinParam instanceof SkinParamColors)
|
||||
specBack = ((SkinParamColors) skinParam).getColors();
|
||||
|
||||
style = style.eventuallyOverride(specBack);
|
||||
this.borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(getIHtmlColorSet());
|
||||
|
||||
this.horizontalAlignment = style.getHorizontalAlignment();
|
||||
this.padding = style.getPadding();
|
||||
|
@ -156,11 +156,11 @@ public class FtileBox2 extends AbstractFtile {
|
||||
this.swimlane = swimlane;
|
||||
|
||||
this.inRendering = LinkRendering
|
||||
.create(Rainbow.build(styleArrow, getIHtmlColorSet(), skinParam.getThemeStyle()));
|
||||
this.borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
.create(Rainbow.build(styleArrow, getIHtmlColorSet()));
|
||||
this.borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(getIHtmlColorSet());
|
||||
|
||||
this.horizontalAlignment = style.getHorizontalAlignment();
|
||||
this.padding = style.getPadding();
|
||||
|
@ -155,10 +155,10 @@ public class FtileBoxOld extends AbstractFtile {
|
||||
this.swimlane = swimlane;
|
||||
|
||||
this.inRendering = LinkRendering
|
||||
.create(Rainbow.build(styleArrow, getIHtmlColorSet(), skinParam.getThemeStyle()));
|
||||
this.borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
.create(Rainbow.build(styleArrow, getIHtmlColorSet()));
|
||||
this.borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(getIHtmlColorSet());
|
||||
this.horizontalAlignment = style.getHorizontalAlignment();
|
||||
// this.padding = style.getPadding();
|
||||
this.roundCorner = style.value(PName.RoundCorner).asDouble();
|
||||
|
@ -74,8 +74,8 @@ public class FtileCircleEnd extends AbstractFtile {
|
||||
this.backColor = backColor;
|
||||
this.swimlane = swimlane;
|
||||
this.shadowing = style.value(PName.Shadowing).asDouble();
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
this.borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
|
||||
}
|
||||
|
||||
|
@ -100,10 +100,9 @@ public class FtileCircleSpot extends AbstractFtile {
|
||||
final UEllipse circle = new UEllipse(SIZE, SIZE);
|
||||
|
||||
final HColor backColor = this.backColor == null
|
||||
? style.value(PName.BackGroundColor).asColor(skinParam().getThemeStyle(), getIHtmlColorSet())
|
||||
? style.value(PName.BackGroundColor).asColor(getIHtmlColorSet())
|
||||
: this.backColor;
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam().getThemeStyle(),
|
||||
getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
final double shadow = style.value(PName.Shadowing).asDouble();
|
||||
|
||||
circle.setDeltaShadow(shadow);
|
||||
|
@ -67,8 +67,8 @@ public class FtileCircleStart extends AbstractFtile {
|
||||
this.backColor = backColor;
|
||||
this.borderColor = HColors.none();
|
||||
this.shadowing = style.value(PName.Shadowing).asDouble();
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
this.borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -73,8 +73,8 @@ public class FtileCircleStop extends AbstractFtile {
|
||||
this.backColor = backColor;
|
||||
this.swimlane = swimlane;
|
||||
this.shadowing = style.value(PName.Shadowing).asDouble();
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
this.borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
|
||||
}
|
||||
|
||||
|
@ -98,7 +98,7 @@ public abstract class GAbstractConnection implements GConnection {
|
||||
final protected Rainbow getInLinkRenderingColor() {
|
||||
final ISkinParam skinParam = gpoint1.getGtile().skinParam();
|
||||
final Style style = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final Rainbow color = Rainbow.build(style, skinParam.getIHtmlColorSet(), skinParam.getThemeStyle());
|
||||
final Rainbow color = Rainbow.build(style, skinParam.getIHtmlColorSet());
|
||||
// final LinkRendering linkRendering = tile.getInLinkRendering();
|
||||
// if (linkRendering == null) {
|
||||
// if (UseStyle.useBetaStyle()) {
|
||||
|
@ -86,8 +86,7 @@ public class GtileAssembly extends GtileTopDown {
|
||||
return TextBlockUtils.EMPTY_TEXT_BLOCK;
|
||||
|
||||
final Style style = getDefaultStyleDefinitionArrow().getMergedStyle(skinParam().getCurrentStyleBuilder());
|
||||
final FontConfiguration fontConfiguration = style.getFontConfiguration(skinParam().getThemeStyle(),
|
||||
skinParam().getIHtmlColorSet());
|
||||
final FontConfiguration fontConfiguration = style.getFontConfiguration(skinParam().getIHtmlColorSet());
|
||||
return display.create7(fontConfiguration, HorizontalAlignment.LEFT, skinParam(), CreoleMode.SIMPLE_LINE);
|
||||
}
|
||||
|
||||
|
@ -134,10 +134,10 @@ public class GtileBox extends AbstractGtile {
|
||||
this.boxStyle = boxStyle;
|
||||
|
||||
this.inRendering = LinkRendering
|
||||
.create(Rainbow.build(styleArrow, getIHtmlColorSet(), skinParam.getThemeStyle()));
|
||||
this.borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
.create(Rainbow.build(styleArrow, getIHtmlColorSet()));
|
||||
this.borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(getIHtmlColorSet());
|
||||
this.horizontalAlignment = style.getHorizontalAlignment();
|
||||
this.padding = style.getPadding();
|
||||
this.margin = style.getMargin();
|
||||
|
@ -44,6 +44,7 @@ import net.sourceforge.plantuml.ISkinParam;
|
||||
import net.sourceforge.plantuml.LineParam;
|
||||
import net.sourceforge.plantuml.activitydiagram3.ftile.Swimlane;
|
||||
import net.sourceforge.plantuml.activitydiagram3.ftile.vcompact.FloatingNote;
|
||||
import net.sourceforge.plantuml.activitydiagram3.ftile.vcompact.FtileGroup;
|
||||
import net.sourceforge.plantuml.awt.geom.XDimension2D;
|
||||
import net.sourceforge.plantuml.cucadiagram.Display;
|
||||
import net.sourceforge.plantuml.graphic.FontConfiguration;
|
||||
@ -54,7 +55,6 @@ import net.sourceforge.plantuml.graphic.TextBlock;
|
||||
import net.sourceforge.plantuml.graphic.TextBlockUtils;
|
||||
import net.sourceforge.plantuml.graphic.USymbol;
|
||||
import net.sourceforge.plantuml.style.PName;
|
||||
import net.sourceforge.plantuml.style.SName;
|
||||
import net.sourceforge.plantuml.style.Style;
|
||||
import net.sourceforge.plantuml.style.StyleSignatureBasic;
|
||||
import net.sourceforge.plantuml.ugraphic.UGraphic;
|
||||
@ -77,8 +77,8 @@ public class GtileGroup extends AbstractGtileRoot {
|
||||
private final USymbol type;
|
||||
private final double roundCorner;
|
||||
|
||||
final public StyleSignatureBasic getDefaultStyleDefinitionPartition() {
|
||||
return StyleSignatureBasic.of(SName.root, SName.element, SName.activityDiagram, SName.partition);
|
||||
final public StyleSignatureBasic getStyleSignature() {
|
||||
return FtileGroup.getStyleSignature(type);
|
||||
}
|
||||
|
||||
private double suppWidth(StringBounder stringBounder) {
|
||||
@ -99,9 +99,8 @@ public class GtileGroup extends AbstractGtileRoot {
|
||||
this.inner = inner;
|
||||
this.borderColor = borderColor == null ? HColors.BLACK : borderColor;
|
||||
|
||||
final Style style = getDefaultStyleDefinitionPartition().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final Style style = getStyleSignature().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getIHtmlColorSet());
|
||||
this.shadowing = style.value(PName.Shadowing).asDouble();
|
||||
|
||||
if (title == null)
|
||||
|
@ -86,8 +86,8 @@ public class GtileHexagonInside extends AbstractGtile {
|
||||
super(stringBounder, skinParam, swimlane);
|
||||
|
||||
final Style style = getDefaultStyleDefinition().getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
this.borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
this.borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
this.backColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
this.shadowing = style.value(PName.Shadowing).asDouble();
|
||||
|
||||
this.label = label;
|
||||
|
@ -108,10 +108,9 @@ public class GtileWithNoteOpale extends AbstractGtile implements Stencil, Stylea
|
||||
|
||||
final Style style = getStyleSignature().getMergedStyle(skinParam.getCurrentStyleBuilder())
|
||||
.eventuallyOverride(note.getColors());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(),
|
||||
getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(getIHtmlColorSet());
|
||||
final double shadowing = style.value(PName.Shadowing).asDouble();
|
||||
final LineBreakStrategy wrapWidth = style.wrapWidth();
|
||||
final UStroke stroke = style.getStroke();
|
||||
|
@ -109,11 +109,9 @@ public class GtileWithNotes extends AbstractGtile {
|
||||
|
||||
final Style style = getDefaultStyleDefinition().getMergedStyle(skinParam.getCurrentStyleBuilder())
|
||||
.eventuallyOverride(note.getColors());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(),
|
||||
getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(skinParam.getThemeStyle(), getIHtmlColorSet());
|
||||
final HColor noteBackgroundColor = style.value(PName.BackGroundColor).asColor(getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(getIHtmlColorSet());
|
||||
final FontConfiguration fc = style.getFontConfiguration(getIHtmlColorSet());
|
||||
final double shadowing = style.value(PName.Shadowing).asDouble();
|
||||
final LineBreakStrategy wrapWidth = style.wrapWidth();
|
||||
final UStroke stroke = style.getStroke();
|
||||
|
@ -62,13 +62,11 @@ public class Gtiles {
|
||||
StyleSignatureBasic styleSignature, HColor color, Display label) {
|
||||
|
||||
final Style style = styleSignature.getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getIHtmlColorSet());
|
||||
final HColor backColor = color == null
|
||||
? style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), skinParam.getIHtmlColorSet())
|
||||
? style.value(PName.BackGroundColor).asColor(skinParam.getIHtmlColorSet())
|
||||
: color;
|
||||
final FontConfiguration fcTest = style.getFontConfiguration(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final FontConfiguration fcTest = style.getFontConfiguration(skinParam.getIHtmlColorSet());
|
||||
|
||||
final Sheet sheet = Parser
|
||||
.build(fcTest, skinParam.getDefaultTextAlignment(HorizontalAlignment.LEFT), skinParam, CreoleMode.FULL)
|
||||
@ -83,10 +81,9 @@ public class Gtiles {
|
||||
StyleSignatureBasic styleSignature, HColor color) {
|
||||
|
||||
final Style style = styleSignature.getMergedStyle(skinParam.getCurrentStyleBuilder());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getThemeStyle(),
|
||||
skinParam.getIHtmlColorSet());
|
||||
final HColor borderColor = style.value(PName.LineColor).asColor(skinParam.getIHtmlColorSet());
|
||||
final HColor backColor = color == null
|
||||
? style.value(PName.BackGroundColor).asColor(skinParam.getThemeStyle(), skinParam.getIHtmlColorSet())
|
||||
? style.value(PName.BackGroundColor).asColor(skinParam.getIHtmlColorSet())
|
||||
: color;
|
||||
|
||||
return new GtileHexagonInside(stringBounder, TextBlockUtils.EMPTY_TEXT_BLOCK, skinParam, backColor, borderColor,
|
||||
|
@ -42,7 +42,7 @@ import net.sourceforge.plantuml.core.UmlSource;
|
||||
|
||||
public interface PSystemFactory {
|
||||
|
||||
Diagram createSystem(ThemeStyle style, UmlSource source, ISkinSimple skinParam);
|
||||
Diagram createSystem(UmlSource source, ISkinSimple skinParam);
|
||||
|
||||
DiagramType getDiagramType();
|
||||
|
||||
|
@ -1,42 +0,0 @@
|
||||
/* ========================================================================
|
||||
* PlantUML : a free UML diagram generator
|
||||
* ========================================================================
|
||||
*
|
||||
* (C) Copyright 2009-2023, Arnaud Roques
|
||||
*
|
||||
* Project Info: http://plantuml.com
|
||||
*
|
||||
* If you like this project or if you find it useful, you can support us at:
|
||||
*
|
||||
* http://plantuml.com/patreon (only 1$ per month!)
|
||||
* http://plantuml.com/paypal
|
||||
*
|
||||
* This file is part of PlantUML.
|
||||
*
|
||||
* PlantUML is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* PlantUML distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
||||
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
|
||||
* License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
|
||||
* USA.
|
||||
*
|
||||
*
|
||||
* Original Author: Arnaud Roques
|
||||
*
|
||||
*
|
||||
*/
|
||||
package net.sourceforge.plantuml.api;
|
||||
|
||||
public enum ThemeStyle {
|
||||
|
||||
LIGHT_REGULAR, DARK
|
||||
|
||||
}
|
@ -43,7 +43,6 @@ import java.util.List;
|
||||
import net.sourceforge.plantuml.FileFormatOption;
|
||||
import net.sourceforge.plantuml.UmlDiagram;
|
||||
import net.sourceforge.plantuml.UmlDiagramType;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.awt.geom.XDimension2D;
|
||||
import net.sourceforge.plantuml.awt.geom.XRectangle2D;
|
||||
import net.sourceforge.plantuml.command.CommandExecutionResult;
|
||||
@ -69,8 +68,8 @@ public class BoardDiagram extends UmlDiagram {
|
||||
return new DiagramDescription("Board");
|
||||
}
|
||||
|
||||
public BoardDiagram(ThemeStyle style, UmlSource source) {
|
||||
super(style, source, UmlDiagramType.BOARD, null);
|
||||
public BoardDiagram(UmlSource source) {
|
||||
super(source, UmlDiagramType.BOARD, null);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -39,7 +39,6 @@ import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import net.sourceforge.plantuml.ISkinSimple;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.command.Command;
|
||||
import net.sourceforge.plantuml.command.CommonCommands;
|
||||
import net.sourceforge.plantuml.command.PSystemCommandFactory;
|
||||
@ -69,8 +68,8 @@ public class BoardDiagramFactory extends PSystemCommandFactory {
|
||||
}
|
||||
|
||||
@Override
|
||||
public BoardDiagram createEmptyDiagram(ThemeStyle style, UmlSource source, ISkinSimple skinParam) {
|
||||
return new BoardDiagram(style, source);
|
||||
public BoardDiagram createEmptyDiagram(UmlSource source, ISkinSimple skinParam) {
|
||||
return new BoardDiagram(source);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -45,7 +45,6 @@ import net.sourceforge.plantuml.FileFormatOption;
|
||||
import net.sourceforge.plantuml.SkinParam;
|
||||
import net.sourceforge.plantuml.UmlDiagram;
|
||||
import net.sourceforge.plantuml.UmlDiagramType;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.command.CommandExecutionResult;
|
||||
import net.sourceforge.plantuml.core.DiagramDescription;
|
||||
import net.sourceforge.plantuml.core.ImageData;
|
||||
@ -75,8 +74,8 @@ public class BpmDiagram extends UmlDiagram {
|
||||
return new DiagramDescription("(Bpm Diagram)");
|
||||
}
|
||||
|
||||
public BpmDiagram(ThemeStyle style, UmlSource source) {
|
||||
super(style, source, UmlDiagramType.BPM, null);
|
||||
public BpmDiagram(UmlSource source) {
|
||||
super(source, UmlDiagramType.BPM, null);
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -94,7 +93,7 @@ public class BpmDiagram extends UmlDiagram {
|
||||
private UDrawable getUDrawable() {
|
||||
final Grid grid = createGrid();
|
||||
cleanGrid(grid);
|
||||
final GridArray gridArray = grid.toArray(SkinParam.create(getUmlDiagramType(), ThemeStyle.LIGHT_REGULAR));
|
||||
final GridArray gridArray = grid.toArray(SkinParam.create(getUmlDiagramType()));
|
||||
// gridArray.addEdges(edges);
|
||||
// System.err.println("gridArray=" + gridArray);
|
||||
return gridArray;
|
||||
|
@ -40,7 +40,6 @@ import java.util.List;
|
||||
|
||||
import net.sourceforge.plantuml.AbstractPSystem;
|
||||
import net.sourceforge.plantuml.ISkinSimple;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.command.Command;
|
||||
import net.sourceforge.plantuml.command.PSystemCommandFactory;
|
||||
import net.sourceforge.plantuml.core.DiagramType;
|
||||
@ -66,8 +65,8 @@ public class BpmDiagramFactory extends PSystemCommandFactory {
|
||||
}
|
||||
|
||||
@Override
|
||||
public AbstractPSystem createEmptyDiagram(ThemeStyle style, UmlSource source, ISkinSimple skinParam) {
|
||||
return new BpmDiagram(style, source);
|
||||
public AbstractPSystem createEmptyDiagram(UmlSource source, ISkinSimple skinParam) {
|
||||
return new BpmDiagram(source);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -35,7 +35,6 @@
|
||||
*/
|
||||
package net.sourceforge.plantuml.braille;
|
||||
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.graphic.UDrawable;
|
||||
import net.sourceforge.plantuml.ugraphic.UEllipse;
|
||||
import net.sourceforge.plantuml.ugraphic.UGraphic;
|
||||
@ -55,7 +54,7 @@ public class BrailleDrawer implements UDrawable {
|
||||
}
|
||||
|
||||
public void drawU(UGraphic ug) {
|
||||
ug = ug.apply(HColorSet.instance().getColorOrWhite(ThemeStyle.LIGHT_REGULAR, "#F0F0F0"));
|
||||
ug = ug.apply(HColorSet.instance().getColorOrWhite("#F0F0F0"));
|
||||
for (int x = grid.getMinX(); x <= grid.getMaxX(); x++) {
|
||||
ug.apply(UTranslate.dx(x * step + spotSize + 1))
|
||||
.draw(ULine.vline((grid.getMaxY() - grid.getMinY()) * step));
|
||||
|
@ -42,15 +42,14 @@ import java.util.List;
|
||||
|
||||
import net.sourceforge.plantuml.ISkinSimple;
|
||||
import net.sourceforge.plantuml.UmlDiagramType;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.core.DiagramDescription;
|
||||
import net.sourceforge.plantuml.core.UmlSource;
|
||||
import net.sourceforge.plantuml.cucadiagram.CucaDiagram;
|
||||
|
||||
public abstract class AbstractEntityDiagram extends CucaDiagram {
|
||||
|
||||
public AbstractEntityDiagram(ThemeStyle style, UmlSource source, UmlDiagramType type, ISkinSimple orig) {
|
||||
super(style, source, type, orig);
|
||||
public AbstractEntityDiagram(UmlSource source, UmlDiagramType type, ISkinSimple orig) {
|
||||
super(source, type, orig);
|
||||
}
|
||||
|
||||
final protected List<String> getDotStrings() {
|
||||
|
@ -42,7 +42,6 @@ import java.util.Objects;
|
||||
import net.sourceforge.plantuml.FileFormatOption;
|
||||
import net.sourceforge.plantuml.ISkinSimple;
|
||||
import net.sourceforge.plantuml.UmlDiagramType;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.core.ImageData;
|
||||
import net.sourceforge.plantuml.core.UmlSource;
|
||||
import net.sourceforge.plantuml.creole.CreoleMode;
|
||||
@ -62,8 +61,8 @@ import net.sourceforge.plantuml.svek.image.EntityImageClass;
|
||||
|
||||
public class ClassDiagram extends AbstractClassOrObjectDiagram {
|
||||
|
||||
public ClassDiagram(ThemeStyle style, UmlSource source, ISkinSimple skinParam) {
|
||||
super(style, source, UmlDiagramType.CLASS, skinParam);
|
||||
public ClassDiagram(UmlSource source, ISkinSimple skinParam) {
|
||||
super(source, UmlDiagramType.CLASS, skinParam);
|
||||
}
|
||||
|
||||
private Code getShortName1972(Code code) {
|
||||
|
@ -40,7 +40,6 @@ import java.util.List;
|
||||
|
||||
import net.sourceforge.plantuml.ISkinSimple;
|
||||
import net.sourceforge.plantuml.UmlDiagramType;
|
||||
import net.sourceforge.plantuml.api.ThemeStyle;
|
||||
import net.sourceforge.plantuml.classdiagram.command.CommandAddMethod;
|
||||
import net.sourceforge.plantuml.classdiagram.command.CommandAllowMixing;
|
||||
import net.sourceforge.plantuml.classdiagram.command.CommandCreateClass;
|
||||
@ -87,8 +86,8 @@ import net.sourceforge.plantuml.objectdiagram.command.CommandCreateMap;
|
||||
public class ClassDiagramFactory extends PSystemCommandFactory {
|
||||
|
||||
@Override
|
||||
public ClassDiagram createEmptyDiagram(ThemeStyle style, UmlSource source, ISkinSimple skinParam) {
|
||||
return new ClassDiagram(style, source, skinParam);
|
||||
public ClassDiagram createEmptyDiagram(UmlSource source, ISkinSimple skinParam) {
|
||||
return new ClassDiagram(source, skinParam);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -174,12 +174,11 @@ public class CommandCreateClass extends SingleLineCommand2<ClassDiagram> {
|
||||
}
|
||||
entity.setCodeLine(location);
|
||||
|
||||
Colors colors = color().getColor(diagram.getSkinParam().getThemeStyle(), arg,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
Colors colors = color().getColor(arg, diagram.getSkinParam().getIHtmlColorSet());
|
||||
final String s = arg.get("LINECOLOR", 1);
|
||||
|
||||
final HColor lineColor = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
if (lineColor != null)
|
||||
colors = colors.add(ColorType.LINE, lineColor);
|
||||
|
||||
|
@ -279,12 +279,11 @@ public class CommandCreateClassMultilines extends CommandMultilines2<ClassDiagra
|
||||
result.addUrl(url);
|
||||
}
|
||||
|
||||
Colors colors = color().getColor(diagram.getSkinParam().getThemeStyle(), line0,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
Colors colors = color().getColor(line0, diagram.getSkinParam().getIHtmlColorSet());
|
||||
final String s = line0.get("LINECOLOR", 1);
|
||||
|
||||
final HColor lineColor = s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s);
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s);
|
||||
if (lineColor != null)
|
||||
colors = colors.add(ColorType.LINE, lineColor);
|
||||
|
||||
|
@ -235,7 +235,7 @@ public class CommandCreateElementFull2 extends SingleLineCommand2<ClassDiagram>
|
||||
final String s = arg.get("COLOR", 0);
|
||||
|
||||
entity.setSpecificColorTOBEREMOVED(ColorType.BACK, s == null ? null
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), s));
|
||||
: diagram.getSkinParam().getIHtmlColorSet().getColor(s));
|
||||
return CommandExecutionResult.ok();
|
||||
}
|
||||
|
||||
|
@ -252,9 +252,8 @@ final public class CommandLinkClass extends SingleLineCommand2<AbstractClassOrOb
|
||||
link = link.getInv();
|
||||
|
||||
link.setLinkArrow(labels.getLinkArrow());
|
||||
link.setColors(color().getColor(diagram.getSkinParam().getThemeStyle(), arg,
|
||||
diagram.getSkinParam().getIHtmlColorSet()));
|
||||
link.applyStyle(diagram.getSkinParam().getThemeStyle(), arg.getLazzy("ARROW_STYLE", 0));
|
||||
link.setColors(color().getColor(arg, diagram.getSkinParam().getIHtmlColorSet()));
|
||||
link.applyStyle(arg.getLazzy("ARROW_STYLE", 0));
|
||||
link.setCodeLine(location);
|
||||
|
||||
addLink(diagram, link, arg.get("HEADER", 0));
|
||||
@ -382,12 +381,11 @@ final public class CommandLinkClass extends SingleLineCommand2<AbstractClassOrOb
|
||||
final Link link = new Link(diagram.getSkinParam().getCurrentStyleBuilder(), cl1, cl2, linkType,
|
||||
linkArg.withQualifier(firstLabel, secondLabel).withDistanceAngle(diagram.getLabeldistance(),
|
||||
diagram.getLabelangle()));
|
||||
link.setColors(color().getColor(diagram.getSkinParam().getThemeStyle(), arg,
|
||||
diagram.getSkinParam().getIHtmlColorSet()));
|
||||
link.setColors(color().getColor(arg, diagram.getSkinParam().getIHtmlColorSet()));
|
||||
|
||||
diagram.resetPragmaLabel();
|
||||
|
||||
link.applyStyle(diagram.getSkinParam().getThemeStyle(), arg.getLazzy("ARROW_STYLE", 0));
|
||||
link.applyStyle(arg.getLazzy("ARROW_STYLE", 0));
|
||||
|
||||
addLink(diagram, link, arg.get("HEADER", 0));
|
||||
return CommandExecutionResult.ok();
|
||||
|
@ -111,7 +111,7 @@ public class CommandNamespace extends SingleLineCommand2<ClassDiagram> {
|
||||
final String color = arg.get("COLOR", 0);
|
||||
if (color != null) {
|
||||
p.setSpecificColorTOBEREMOVED(ColorType.BACK,
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), color));
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(color));
|
||||
}
|
||||
return CommandExecutionResult.ok();
|
||||
}
|
||||
|
@ -111,7 +111,7 @@ public class CommandNamespace2 extends SingleLineCommand2<ClassDiagram> {
|
||||
final String color = arg.get("COLOR", 0);
|
||||
if (color != null) {
|
||||
p.setSpecificColorTOBEREMOVED(ColorType.BACK,
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), color));
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(color));
|
||||
}
|
||||
return CommandExecutionResult.ok();
|
||||
}
|
||||
|
@ -105,7 +105,7 @@ public class CommandNamespaceEmpty extends SingleLineCommand2<ClassDiagram> {
|
||||
final String color = arg.get("COLOR", 0);
|
||||
if (color != null) {
|
||||
p.setSpecificColorTOBEREMOVED(ColorType.BACK,
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), color));
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(color));
|
||||
}
|
||||
diagram.endGroup();
|
||||
return CommandExecutionResult.ok();
|
||||
|
@ -155,8 +155,7 @@ public class CommandPackage extends SingleLineCommand2<AbstractEntityDiagram> {
|
||||
p.addUrl(url);
|
||||
}
|
||||
|
||||
final Colors colors = color().getColor(diagram.getSkinParam().getThemeStyle(), arg,
|
||||
diagram.getSkinParam().getIHtmlColorSet());
|
||||
final Colors colors = color().getColor(arg, diagram.getSkinParam().getIHtmlColorSet());
|
||||
p.setColors(colors);
|
||||
|
||||
return CommandExecutionResult.ok();
|
||||
|
@ -106,7 +106,7 @@ public class CommandPackageEmpty extends SingleLineCommand2<AbstractEntityDiagra
|
||||
final String color = arg.get("COLOR", 0);
|
||||
if (color != null) {
|
||||
p.setSpecificColorTOBEREMOVED(ColorType.BACK,
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(diagram.getSkinParam().getThemeStyle(), color));
|
||||
diagram.getSkinParam().getIHtmlColorSet().getColor(color));
|
||||
}
|
||||
diagram.endGroup();
|
||||
return CommandExecutionResult.ok();
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user