/** * @return the line end decoration length */ @SuppressWarnings("WeakerAccess") public DecorationSize getLineTailLength() { CTLineProperties ln = getLn(this, false); DecorationSize ds = DecorationSize.MEDIUM; if (ln != null && ln.isSetTailEnd() && ln.getTailEnd().isSetLen()) { ds = DecorationSize.fromOoxmlId(ln.getTailEnd().getLen().intValue()); } return ds; }
/** * @return the line end decoration shape */ @SuppressWarnings("WeakerAccess") public DecorationShape getLineHeadDecoration() { CTLineProperties ln = getLn(this, false); DecorationShape ds = DecorationShape.NONE; if (ln != null && ln.isSetHeadEnd() && ln.getHeadEnd().isSetType()) { ds = DecorationShape.fromOoxmlId(ln.getHeadEnd().getType().intValue()); } return ds; }
/** * Specifies the line end width in relation to the line width. */ @SuppressWarnings("WeakerAccess") public void setLineHeadLength(DecorationSize style) { CTLineProperties ln = getLn(this, true); if (ln == null) { return; } CTLineEndProperties lnEnd = ln.isSetHeadEnd() ? ln.getHeadEnd() : ln.addNewHeadEnd(); if (style == null) { if (lnEnd.isSetLen()) { lnEnd.unsetLen(); } } else { lnEnd.setLen(STLineEndLength.Enum.forInt(style.ooxmlId)); } }
/** * specifies decorations which can be added to the tail of a line. */ @SuppressWarnings("WeakerAccess") public void setLineTailWidth(DecorationSize style) { CTLineProperties ln = getLn(this, true); if (ln == null) { return; } CTLineEndProperties lnEnd = ln.isSetTailEnd() ? ln.getTailEnd() : ln.addNewTailEnd(); if (style == null) { if (lnEnd.isSetW()) { lnEnd.unsetW(); } } else { lnEnd.setW(STLineEndWidth.Enum.forInt(style.ooxmlId)); } }
/** * Specifies the line end decoration, such as a triangle or arrowhead. */ @SuppressWarnings("WeakerAccess") public void setLineTailDecoration(DecorationShape style) { CTLineProperties ln = getLn(this, true); if (ln == null) { return; } CTLineEndProperties lnEnd = ln.isSetTailEnd() ? ln.getTailEnd() : ln.addNewTailEnd(); if (style == null) { if (lnEnd.isSetType()) { lnEnd.unsetType(); } } else { lnEnd.setType(STLineEndType.Enum.forInt(style.ooxmlId)); } }
/** * @return the line end decoration width */ @SuppressWarnings("WeakerAccess") public DecorationSize getLineHeadWidth() { CTLineProperties ln = getLn(this, false); DecorationSize ds = DecorationSize.MEDIUM; if (ln != null && ln.isSetHeadEnd() && ln.getHeadEnd().isSetW()) { ds = DecorationSize.fromOoxmlId(ln.getHeadEnd().getW().intValue()); } return ds; }
public LineEndWidth getWidth() { return LineEndWidth.valueOf(props.getW()); }
public LineEndLength getLength() { return LineEndLength.valueOf(props.getLen()); }
public LineEndType getType() { return LineEndType.valueOf(props.getType()); }
public void setWidth(LineEndWidth width) { props.setW(width.underlying); } }
public void setLength(LineEndLength length) { props.setLen(length.underlying); }
public void setType(LineEndType type) { props.setType(type.underlying); }
/** * Specifies the line end width in relation to the line width. */ @SuppressWarnings("WeakerAccess") public void setLineTailLength(DecorationSize style) { CTLineProperties ln = getLn(this, true); if (ln == null) { return; } CTLineEndProperties lnEnd = ln.isSetTailEnd() ? ln.getTailEnd() : ln.addNewTailEnd(); if (style == null) { if (lnEnd.isSetLen()) { lnEnd.unsetLen(); } } else { lnEnd.setLen(STLineEndLength.Enum.forInt(style.ooxmlId)); } }
/** * specifies decoration width of the head of a line. * * @param style the decoration width */ @SuppressWarnings("WeakerAccess") public void setLineHeadWidth(DecorationSize style) { CTLineProperties ln = getLn(this, true); if (ln == null) { return; } CTLineEndProperties lnEnd = ln.isSetHeadEnd() ? ln.getHeadEnd() : ln.addNewHeadEnd(); if (style == null) { if (lnEnd.isSetW()) { lnEnd.unsetW(); } } else { lnEnd.setW(STLineEndWidth.Enum.forInt(style.ooxmlId)); } }
/** * Specifies the line end decoration, such as a triangle or arrowhead. * * @param style the line end docoration style */ @SuppressWarnings("WeakerAccess") public void setLineHeadDecoration(DecorationShape style) { CTLineProperties ln = getLn(this, true); if (ln == null) { return; } CTLineEndProperties lnEnd = ln.isSetHeadEnd() ? ln.getHeadEnd() : ln.addNewHeadEnd(); if (style == null) { if (lnEnd.isSetType()) { lnEnd.unsetType(); } } else { lnEnd.setType(STLineEndType.Enum.forInt(style.ooxmlId)); } }
/** * @return the line end decoration width */ @SuppressWarnings("WeakerAccess") public DecorationSize getLineTailWidth() { CTLineProperties ln = getLn(this, false); DecorationSize ds = DecorationSize.MEDIUM; if (ln != null && ln.isSetTailEnd() && ln.getTailEnd().isSetW()) { ds = DecorationSize.fromOoxmlId(ln.getTailEnd().getW().intValue()); } return ds; }
public LineEndWidth getWidth() { return LineEndWidth.valueOf(props.getW()); }
public LineEndLength getLength() { return LineEndLength.valueOf(props.getLen()); }
public LineEndType getType() { return LineEndType.valueOf(props.getType()); }