public String getSpecificDecorationSvek() { final StringBuilder sb = new StringBuilder(); final boolean isEmpty1 = decor1 == LinkDecor.NONE && hat1 == LinkHat.NONE; final boolean isEmpty2 = decor2 == LinkDecor.NONE && hat2 == LinkHat.NONE; if (isEmpty1 && isEmpty2) { sb.append("arrowtail=none"); sb.append(",arrowhead=none"); } else if (isEmpty1 == false && isEmpty2 == false) { sb.append("dir=both,"); sb.append("arrowtail=empty"); sb.append(",arrowhead=empty"); } else if (isEmpty1 && isEmpty2 == false) { sb.append("arrowtail=empty"); sb.append(",arrowhead=none"); sb.append(",dir=back"); } else if (isEmpty1 == false && isEmpty2) { sb.append("arrowtail=none"); sb.append(",arrowhead=empty"); } // if (decor1 == LinkDecor.NONE && decor2 != LinkDecor.NONE) { // sb.append("dir=back,"); // } // if (decor1 != LinkDecor.NONE && decor2 != LinkDecor.NONE) { // sb.append("dir=both,"); // } // // sb.append("dir=both,"); // // sb.append("arrowtail="); // sb.append(decor2.getArrowDotSvek()); // sb.append(",arrowhead="); // sb.append(decor1.getArrowDotSvek()); final double arrowsize = Math.max(decor1.getArrowSize(), decor2.getArrowSize()); if (arrowsize > 0) { sb.append(",arrowsize=" + arrowsize); } return sb.toString(); }
public double getMarginDecors2( StringBounder stringBounder, UFont fontQualif, SpriteContainer spriteContainer) { final double q = getQualifierMargin(stringBounder, fontQualif, qualifier2, spriteContainer); final LinkDecor decor = getType().getDecor2(); return decor.getSize() + q; }