1
0
mirror of https://github.com/octoleo/plantuml.git synced 2024-05-28 22:20:49 +00:00

version 1.2020.9

This commit is contained in:
Arnaud Roques 2020-05-10 16:19:20 +02:00
parent e9fb57cbbe
commit 5bd20214e2
14 changed files with 221 additions and 129 deletions

View File

@ -35,7 +35,7 @@
<groupId>net.sourceforge.plantuml</groupId> <groupId>net.sourceforge.plantuml</groupId>
<artifactId>plantuml</artifactId> <artifactId>plantuml</artifactId>
<version>1.2020.9-SNAPSHOT</version> <version>1.2020.9</version>
<packaging>jar</packaging> <packaging>jar</packaging>
<name>PlantUML</name> <name>PlantUML</name>
@ -75,9 +75,9 @@
</licenses> </licenses>
<scm> <scm>
<connection>scm:svn:svn://svn.code.sf.net/p/plantuml/code/trunk</connection> <connection>scm:svn:svn://svn.code.sf.net/p/plantuml/code/tags/plantuml-1.2020.9</connection>
<developerConnection>scm:svn:https://svn.code.sf.net/p/plantuml/code/trunk</developerConnection> <developerConnection>scm:svn:https://svn.code.sf.net/p/plantuml/code/tags/plantuml-1.2020.9</developerConnection>
<url>svn://svn.code.sf.net/p/plantuml/code/trunk</url> <url>svn://svn.code.sf.net/p/plantuml/code/tags/plantuml-1.2020.9</url>
</scm> </scm>
<issueManagement> <issueManagement>

View File

@ -13,6 +13,10 @@ root {
Shadowing 0.0 Shadowing 0.0
} }
document {
BackGroundColor White
}
stereotype { stereotype {
FontStyle italic FontStyle italic
} }

View File

@ -57,7 +57,7 @@ public class ByteArray {
} }
public String toUPF9String() throws IOException { public String toUPF9String() throws IOException {
return Upf9.decodeString(data, length); return Upf9Decoder.decodeString(data, length);
} }
public int getByteAt(int i) { public int getByteAt(int i) {

View File

@ -40,28 +40,35 @@ import java.util.List;
import java.util.Set; import java.util.Set;
import java.util.TreeSet; import java.util.TreeSet;
public class Keywords { public class Tokens {
private final List<String> keywords = new ArrayList<String>(); private final List<String> keywords = new ArrayList<String>();
public static void main(String[] args) { public static void main(String[] args) {
System.err.println("keywords=" + new Keywords().keywords.size()); System.err.println("keywords=" + new Tokens().keywords.size());
final Set<String> sorted = new TreeSet<String>(new Keywords().keywords); final Set<String> sorted = new TreeSet<String>(new Tokens().keywords);
for (String s : sorted) { for (String s : sorted) {
System.err.println(s); System.err.println(s);
} }
} }
public String compress(String s) { public String compressUnicodeE000(String s) {
for (int i = 0; i < keywords.size(); i++) { for (int i = 0; i < keywords.size(); i++) {
final char c = (char) ('\uE000' + i); final char c = (char) ('\uE000' + i);
s = s.replace(keywords.get(i), "" + c); s = s.replace(keywords.get(i), "" + c);
} }
return s; return s;
} }
public Keywords() { public String compressAscii128(String s) {
for (int i = 0; i < keywords.size(); i++) {
final char c = (char) (128 + i);
s = s.replace(keywords.get(i), "" + c);
}
return s;
}
public Tokens() {
add("actor"); add("actor");
add("participant"); add("participant");
add("usecase"); add("usecase");
@ -145,37 +152,64 @@ public class Keywords {
add("stereotype"); add("stereotype");
add("split"); add("split");
add("style"); add("style");
add("sprite");
add("!exit"); add("exit");
add("!include"); add("include");
add("!pragma"); add("pragma");
add("!undef"); add("undef");
add("!ifdef"); add("ifdef");
add("!endif"); // add("endif");
add("!ifndef"); add("ifndef");
add("!else"); // add("else");
add("!function"); add("function");
add("!procedure"); add("procedure");
add("!endfunction"); add("endfunction");
add("!endprocedure"); add("endprocedure");
add("!unquoted"); add("unquoted");
add("!return"); // add("return");
add("!startsub"); add("startsub");
add("!endsub"); add("endsub");
add("!assert"); add("assert");
add("!local"); add("local");
add("!definelong");
add("!enddefinelong");
add("!define");
add("define");
add("alias");
add("shape");
add("label");
add("BackgroundColor");
add("Color");
add("color");
add("Entity");
add("ENTITY");
add("COLOR");
add("LARGE");
add("stereo");
add("AZURE");
add("Azure");
} }
private void add(String string) { private void add(String string) {
if (keywords.contains(string)) { if (keywords.contains(string)) {
System.err.println(string);
throw new IllegalArgumentException(string); throw new IllegalArgumentException(string);
} }
if (string.length() <= 3) { if (string.length() <= 3) {
System.err.println(string);
throw new IllegalArgumentException(string);
}
if (string.matches("[!@]?[A-Za-z]+") == false) {
System.err.println(string);
throw new IllegalArgumentException(string); throw new IllegalArgumentException(string);
} }
keywords.add(string); keywords.add(string);
if (keywords.size() > 127) { if (keywords.size() > 127) {
System.err.println(string);
throw new IllegalArgumentException(); throw new IllegalArgumentException();
} }
} }

View File

@ -70,7 +70,7 @@ public class TranscoderImpl implements Transcoder {
if (format == Format.UTF8) if (format == Format.UTF8)
data = stringAnnoted.getBytes("UTF-8"); data = stringAnnoted.getBytes("UTF-8");
else else
data = Upf9.getBytes(stringAnnoted); data = Upf9Encoder.getBytes(stringAnnoted);
final byte[] compressedData = compression.compress(data); final byte[] compressedData = compression.compress(data);

View File

@ -0,0 +1,85 @@
/* ========================================================================
* PlantUML : a free UML diagram generator
* ========================================================================
*
* (C) Copyright 2009-2020, 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.code;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
public class Upf9Decoder {
private Upf9Decoder() {
}
static int decodeChar(InputStream is) throws IOException {
final int read0 = is.read();
if (read0 == -1) {
return -1;
}
if (read0 == 0x0B) {
final int read1 = is.read();
if (read1 >= 0x80)
return (char) read1;
return (char) ((0xE0 << 8) + read1);
}
if (read0 == 0x0C) {
final int read1 = is.read();
final int read2 = is.read();
return (char) ((read1 << 8) + read2);
}
if (read0 >= 0x01 && read0 <= 0x08) {
final int read1 = is.read();
return (char) ((read0 << 8) + read1);
}
if (read0 >= 0x80 && read0 <= 0xFF) {
final int read1 = is.read();
return (char) (((read0 - 0x60) << 8) + read1);
}
return (char) read0;
}
public static String decodeString(byte[] data, int length) throws IOException {
final ByteArrayInputStream bais = new ByteArrayInputStream(data, 0, length);
final StringBuilder result = new StringBuilder();
int read;
while ((read = decodeChar(bais)) != -1) {
result.append((char) read);
}
bais.close();
return result.toString();
}
}

View File

@ -38,11 +38,10 @@ package net.sourceforge.plantuml.code;
import java.io.ByteArrayInputStream; import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream; import java.io.ByteArrayOutputStream;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream;
public class Upf9 { public class Upf9Encoder {
private Upf9() { private Upf9Encoder() {
} }
@ -54,7 +53,7 @@ public class Upf9 {
private static boolean checkBack(char c, byte[] result) { private static boolean checkBack(char c, byte[] result) {
try { try {
if (c == decodeChar(new ByteArrayInputStream(result))) if (c == Upf9Decoder.decodeChar(new ByteArrayInputStream(result)))
return true; return true;
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); e.printStackTrace();
@ -64,67 +63,36 @@ public class Upf9 {
private static byte[] encodeCharInternal(char c) { private static byte[] encodeCharInternal(char c) {
if (c == '\n' || c == '\r' || c == '\t') { if (c == '\n' || c == '\r' || c == '\t') {
// Using regular ASCII code for <u+0009> <u+000A> and <u+000D>
return new byte[] { (byte) c };
}
if (c >= '\u000E' && c <= '\u0012') {
return new byte[] { (byte) c }; return new byte[] { (byte) c };
} }
if (c >= '\u0020' && c <= '\u007E') { if (c >= '\u0020' && c <= '\u007E') {
// Using regular ASCII code for ASCII printable char
return new byte[] { (byte) c }; return new byte[] { (byte) c };
} }
if (c >= '\u0080' && c <= '\u00FF') { if (c >= '\u0080' && c <= '\u00FF') {
// Char from <u+0080> to <u+00FF> are encoded as [0x0B 0x80] to [0x0B 0xFF]
return new byte[] { 0x0B, (byte) c }; return new byte[] { 0x0B, (byte) c };
} }
if (c >= '\u0100' && c <= '\u08FF') { if (c >= '\u0100' && c <= '\u08FF') {
// Char from <u+0100> to <u+08FF> are encoded as [0x01 0x00] to [0x08 0xFF]
return new byte[] { highByte(c), lowByte(c) }; return new byte[] { highByte(c), lowByte(c) };
} }
if (c >= '\u0900' && c <= '\u10FF') {
return new byte[] { (byte) (5 + highByte(c)), lowByte(c) };
}
if (c >= '\u1900' && c <= '\u1FFF') {
return new byte[] { (byte) (-3 + highByte(c)), lowByte(c) };
}
if (c >= '\u2000' && c <= '\u9FFF') { if (c >= '\u2000' && c <= '\u9FFF') {
return new byte[] { (byte) (96 + highByte(c)), lowByte(c) }; // Char from <u+2000> to <u+9FFF> are encoded as [0x80 0x00] to [0xFF 0xFF]
return new byte[] { (byte) (0x60 + highByte(c)), lowByte(c) };
} }
if (c >= '\uE000' && c <= '\uE07F') { if (c >= '\uE000' && c <= '\uE07F') {
// Char from <u+E000> to <u+E07F> are encoded as [0x0B 0x00] to [0x0B 0x7F]
return new byte[] { 0x0B, lowByte(c) }; return new byte[] { 0x0B, lowByte(c) };
} }
// All other char are encoded on 3 bytes, starting with 0x0C
return new byte[] { 0x0C, highByte(c), lowByte(c) }; return new byte[] { 0x0C, highByte(c), lowByte(c) };
} }
static int decodeChar(InputStream is) throws IOException {
final int read0 = is.read();
if (read0 == -1) {
return -1;
}
if (read0 == 0x0B) {
final int read1 = is.read();
if (read1 >= 0x80)
return (char) read1;
return (char) ((0xE0 << 8) + read1);
}
if (read0 == 0x0C) {
final int read1 = is.read();
final int read2 = is.read();
return (char) ((read1 << 8) + read2);
}
if (read0 >= 0x01 && read0 <= 0x08) {
final int read1 = is.read();
return (char) ((read0 << 8) + read1);
}
if (read0 >= 0x0E && read0 <= 0x15) {
final int read1 = is.read();
return (char) (((read0 - 5) << 8) + read1);
}
if (read0 >= 0x16 && read0 <= 0x1C) {
final int read1 = is.read();
return (char) (((read0 + 3) << 8) + read1);
}
if (read0 >= 0x80 && read0 <= 0xFF) {
final int read1 = is.read();
return (char) (((read0 - 96) << 8) + read1);
}
return (char) read0;
}
private static byte lowByte(char c) { private static byte lowByte(char c) {
return (byte) (c & 0x00FF); return (byte) (c & 0x00FF);
} }
@ -139,18 +107,9 @@ public class Upf9 {
baos.write(encodeChar(s.charAt(i))); baos.write(encodeChar(s.charAt(i)));
} }
baos.close(); baos.close();
return baos.toByteArray(); final byte[] result = baos.toByteArray();
} assert s.endsWith(Upf9Decoder.decodeString(result, result.length));
return result;
public static String decodeString(byte[] data, int length) throws IOException {
final ByteArrayInputStream bais = new ByteArrayInputStream(data, 0, length);
final StringBuilder result = new StringBuilder();
int read;
while ((read = decodeChar(bais)) != -1) {
result.append((char) read);
}
bais.close();
return result.toString();
} }
} }

View File

@ -72,25 +72,25 @@ public class PSystemDonors extends AbstractPSystem {
private static final int COLS = 6; private static final int COLS = 6;
private static final int FREE_LINES = 6; private static final int FREE_LINES = 6;
public static final String DONORS = "6qmB02mFUBXRGOc9nbfsvvsjZ8ybZ2OHBCyJYiF08fxk1iGVuDxfSR-H_YAwqhrlcX5jsPhYF6E8M13q" public static final String DONORS = "6rWB02mFUBXRGOc9nbfsvvsjZ9-86KqYM9ud58U1HJpT3OW_mBtJutuZ_KLqfNlVD2FQiZN5USOGiI3e"
+ "U9fSCsnpRmyyvfxff-Ixcz4JPiBaVmA4fYcNj0L8bI4b-FUTh_mIz0xls23HNANHuiWzilk5zpV3UUuq" + "yJIvPjZctXu8Sw9y2FxT21uW0qH9r4QrBFUas6sRAaDAyEyxN_abw1tUiK6YkKgZnP5xPFSBxs-6ytpJ"
+ "Fdhf6V08LJz5zxN_Dvr8N1uAOPPcAup1g6Y4sXSuHUTOxlzJgKkZsdrNHNMhAiTqwk8OhWeRqDK9ZmMh" + "67hf6R0ygdwAxcl_T-agw_AgAipItGgCmAZJ2DLvIp77TFz7WJjEmKvGHOybntGgvpeSggY0LoSy1XPf"
+ "cLguQv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k4okSlKQ654WjhuN9prs"
+ "E7ORPRZBQWLuK1sN2QpzwhTcbZUDkUvOgXkU8VBJ4JbLz70jhAbfyzWCR1TZVczfFvNfyP-Cw9VIcXvx" + "6sLuoYe5M50Tjmci_Ugtqonl6dFUeLGtN0RopO6SAlK8BQofQSrO26mGOtvlOJ-LzFXF1lh5jTQFlNhe"
+ "zJ1yK7vFdGADt_PG-WqZmO18tJ5WD_SvcO4xtd382rDpKjF5CYiNtTVj0i4A-ysyH1OJNjdMAfUmrXvU" + "EQYyXtU3Xczxa7x6I31S9EsOeBVqEPc1XsyOv8svEV7fOicLYsuOTe5WXVr6NoOB2I_iQ9LBDDSUNdFw"
+ "S_7jNPxTTkQmBMIVgKRJ2qKLCGEPN6pHtOc5Ki03gI05S_QMYIBI3dg3Opq3y105n_jx1k5eiNczPftZ" + "6Gq0"; + "vLtEQZjow1QoZrQZ-OMYYfY1N5YirTM9XLAE1r8a1NFsbl42QGUzmIKz0JX5mV7-xaCulT3yY6RjuncD" + "OgwA2G00";
/* /*
* Special thanks to our sponsors and donors: * Special thanks to our sponsors and donors:

View File

@ -267,7 +267,8 @@ public class QuoteUtils {
"Gunax lbh sbe pubbfvat Bprnavp Nveyvarf", "4-8-15-16-23-42", "Gunax lbh sbe pubbfvat Bprnavp Nveyvarf", "4-8-15-16-23-42",
"...naq gnk phgf. Gung'yy fubj gurz znegvnaf.", "...naq gnk phgf. Gung'yy fubj gurz znegvnaf.",
"Jurarire V srry gur arrq gb rkrepvfr, V yvr qbja hagvy vg tbrf njnl", "Ernyvgl pbagvahrf gb ehva zl yvsr", "Jurarire V srry gur arrq gb rkrepvfr, V yvr qbja hagvy vg tbrf njnl", "Ernyvgl pbagvahrf gb ehva zl yvsr",
"Vs lbh gvpxyr hf, qb jr abg ynhtu?", "V xabj n HQC wbxr, ohg lbh zvtug abg trg vg"); "Vs lbh gvpxyr hf, qb jr abg ynhtu?", "V xabj n HQC wbxr, ohg lbh zvtug abg trg vg",
"Chvfdhr prf zlfgrerf abhf qrcnffrag, srvtabaf q'ra rger y'betnavfngrhe.");
private QuoteUtils() { private QuoteUtils() {
} }

View File

@ -51,7 +51,6 @@ import net.sourceforge.plantuml.OptionFlags;
public class ImportedFiles { public class ImportedFiles {
private static final List<File> INCLUDE_PATH = FileSystem.getPath("plantuml.include.path", true);
private final List<File> imported; private final List<File> imported;
private final AParentFolder currentDir; private final AParentFolder currentDir;
@ -107,11 +106,15 @@ public class ImportedFiles {
public List<File> getPath() { public List<File> getPath() {
final List<File> result = new ArrayList<File>(imported); final List<File> result = new ArrayList<File>(imported);
result.addAll(INCLUDE_PATH); result.addAll(includePath());
result.addAll(FileSystem.getPath("java.class.path", true)); result.addAll(FileSystem.getPath("java.class.path", true));
return result; return result;
} }
private List<File> includePath() {
return FileSystem.getPath("plantuml.include.path", true);
}
private boolean isAbsolute(String nameOrPath) { private boolean isAbsolute(String nameOrPath) {
final File f = new File(nameOrPath); final File f = new File(nameOrPath);
return f.isAbsolute(); return f.isAbsolute();
@ -148,8 +151,9 @@ public class ImportedFiles {
} }
if (file != null) { if (file != null) {
final File folder = file.getSystemFolder(); final File folder = file.getSystemFolder();
// System.err.println("canonicalPath=" + path + " " + folder + " " + INCLUDE_PATH); // System.err.println("canonicalPath=" + path + " " + folder + " " +
if (INCLUDE_PATH.contains(folder)) { // INCLUDE_PATH);
if (includePath().contains(folder)) {
return true; return true;
} }
} }

View File

@ -119,19 +119,20 @@ abstract class ExtremityExtendsLike extends Extremity {
private final UTranslate pos1, pos2; private final UTranslate pos1, pos2;
private final UEllipse dot; private final UEllipse dot;
private static UTranslate getDotPos(double x, double y, double angle, double size, Point2D porig) {
Point p = new Point(x, y);
p.rotate(angle);
p.x -= size;
p.y -= size;
return p.getPos(porig);
}
public DefinedBy(Point2D porig, double angle, HColor backgroundColor) { public DefinedBy(Point2D porig, double angle, HColor backgroundColor) {
super(porig, angle, backgroundColor); super(porig, angle, backgroundColor);
double w = HALF_WIDTH - DOTHSIZE; double w = HALF_WIDTH - DOTHSIZE;
Point p1 = new Point(XSUFFIX, -w); this.pos1 = getDotPos(XSUFFIX, -w, angle, DOTHSIZE, porig);
p1.rotate(angle); this.pos2 = getDotPos(XSUFFIX, +w, angle, DOTHSIZE, porig);
p1.x -= DOTHSIZE;
this.pos1 = p1.getPos(porig);
Point p2 = new Point(XSUFFIX, +w);
p2.rotate(angle);
p2.x -= DOTHSIZE;
this.pos2 = p2.getPos(porig);
double s = DOTHSIZE + DOTHSIZE; double s = DOTHSIZE + DOTHSIZE;
this.dot = new UEllipse(s, s); this.dot = new UEllipse(s, s);
@ -170,4 +171,4 @@ abstract class ExtremityExtendsLike extends Extremity {
ug.apply(back).draw(trig); ug.apply(back).draw(trig);
} }
} }

View File

@ -161,6 +161,7 @@ public class LanguageDescriptor {
keyword.add("stereotype"); keyword.add("stereotype");
keyword.add("split"); keyword.add("split");
keyword.add("style"); keyword.add("style");
keyword.add("sprite");
preproc.add("!exit"); preproc.add("!exit");
preproc.add("!include"); preproc.add("!include");

View File

@ -305,7 +305,7 @@ public enum License {
text.add(" "); text.add(" ");
text.add("Project Info: https://plantuml.com"); text.add("Project Info: https://plantuml.com");
text.add(" "); text.add(" ");
if (licenseInfo.isValid() == false) { if (licenseInfo.isValid() == false) {
text.add("If you like this project or if you find it useful, you can support us at:"); text.add("If you like this project or if you find it useful, you can support us at:");
text.add(" "); text.add(" ");
@ -313,7 +313,8 @@ public enum License {
text.add("https://plantuml.com/liberapay (only 1\u20ac per month!)"); text.add("https://plantuml.com/liberapay (only 1\u20ac per month!)");
text.add("https://plantuml.com/paypal"); text.add("https://plantuml.com/paypal");
if (withQrcode) { if (withQrcode) {
text.add("\t<qrcode:http://plantuml.com/patreon>\t\t<qrcode:http://plantuml.com/lp>\t\t<qrcode:http://plantuml.com/paypal>"); text.add(
"\t<qrcode:http://plantuml.com/patreon>\t\t<qrcode:http://plantuml.com/lp>\t\t<qrcode:http://plantuml.com/paypal>");
} else { } else {
text.add(""); text.add("");
text.add(" "); text.add(" ");
@ -325,7 +326,8 @@ public enum License {
if (licenseInfo.getLicenseType() == LicenseType.NAMED) { if (licenseInfo.getLicenseType() == LicenseType.NAMED) {
text.add("| "); text.add("| ");
text.add("| LICENSED TO : " + licenseInfo.getOwner()); text.add("| LICENSED TO : " + licenseInfo.getOwner());
text.add("| EXPIRATION DATE : " + DateFormat.getDateInstance().format(licenseInfo.getExpirationDate())); text.add(
"| EXPIRATION DATE : " + DateFormat.getDateInstance().format(licenseInfo.getExpirationDate()));
text.add("| "); text.add("| ");
} else if (licenseInfo.getLicenseType() == LicenseType.DISTRIBUTOR) { } else if (licenseInfo.getLicenseType() == LicenseType.DISTRIBUTOR) {
text.add("| "); text.add("| ");
@ -338,7 +340,7 @@ public enum License {
} }
} }
public List<String> getJavaHeader() { public List<String> getJavaHeader(List<String> contributors) {
final List<String> h = new ArrayList<String>(); final List<String> h = new ArrayList<String>();
h.add("/* ========================================================================"); h.add("/* ========================================================================");
h.add(" * PlantUML : a free UML diagram generator"); h.add(" * PlantUML : a free UML diagram generator");
@ -468,6 +470,7 @@ public enum License {
} }
h.add(" *"); h.add(" *");
h.add(" * Original Author: Arnaud Roques"); h.add(" * Original Author: Arnaud Roques");
h.addAll(contributors);
h.add(" */"); h.add(" */");
return Collections.unmodifiableList(h); return Collections.unmodifiableList(h);
} }

View File

@ -43,7 +43,7 @@ public class Version {
private static final int MAJOR_SEPARATOR = 1000000; private static final int MAJOR_SEPARATOR = 1000000;
public static int version() { public static int version() {
return 1202008; return 1202009;
} }
public static int versionPatched() { public static int versionPatched() {
@ -79,7 +79,7 @@ public class Version {
} }
public static int beta() { public static int beta() {
final int beta = 18; final int beta = 0;
return beta; return beta;
} }
@ -92,7 +92,7 @@ public class Version {
} }
public static long compileTime() { public static long compileTime() {
return 1587910102162L; return 1589107866768L;
} }
public static String compileTimeString() { public static String compileTimeString() {