public void setLineCap(LineCap cap) { if (cap == null) { if (props.isSetCap()) { props.unsetCap(); } } else { props.setCap(cap.underlying); } }
public LineCap getLineCap() { if (props.isSetCap()) { return LineCap.valueOf(props.getCap()); } else { return null; } }
@Override public boolean fetch(XSLFShape shape) { CTLineProperties ln = getLn(shape, false); if (ln != null && ln.isSetCap()) { setValue(LineCap.fromOoxmlId(ln.getCap().intValue())); return true; } return false; } };
/** * * @param cap the line end cap style */ @SuppressWarnings("WeakerAccess") public void setLineCap(LineCap cap) { CTLineProperties ln = getLn(this, true); if (ln == null) { return; } if (cap == null) { if (ln.isSetCap()) { ln.unsetCap(); } } else { ln.setCap(STLineCap.Enum.forInt(cap.ooxmlId)); } }
@SuppressWarnings("WeakerAccess") public LineCap getBorderCap(BorderEdge edge) { CTLineProperties ln = getCTLine(edge, false); if (ln == null || ln.isSetNoFill() || !ln.isSetSolidFill() || !ln.isSetCap()) { return null; } return LineCap.fromOoxmlId(ln.getCap().intValue()); }
/** * * @return the line end cap style */ @SuppressWarnings("WeakerAccess") public LineCap getLineCap() { PropertyFetcher<LineCap> fetcher = new PropertyFetcher<LineCap>() { @Override public boolean fetch(XSLFShape shape) { CTLineProperties ln = getLn(shape, false); if (ln != null && ln.isSetCap()) { setValue(LineCap.fromOoxmlId(ln.getCap().intValue())); return true; } return false; } }; fetchShapeProperty(fetcher); LineCap cap = fetcher.getValue(); if (cap == null) { CTLineProperties defaultLn = getDefaultLineProperties(); if (defaultLn != null && defaultLn.isSetCap()) { cap = LineCap.fromOoxmlId(defaultLn.getCap().intValue()); } } return cap; }
ln.setAlgn(STPenAlignment.CTR); if (!ln.isSetCap()) { ln.setCap(STLineCap.FLAT);
public void setLineCap(LineCap cap) { if (cap == null) { if (props.isSetCap()) { props.unsetCap(); } } else { props.setCap(cap.underlying); } }
public LineCap getLineCap() { if (props.isSetCap()) { return LineCap.valueOf(props.getCap()); } else { return null; } }
@Override public boolean fetch(XSLFShape shape) { CTLineProperties ln = getLn(shape, false); if (ln != null && ln.isSetCap()) { setValue(LineCap.fromOoxmlId(ln.getCap().intValue())); return true; } return false; } };
/** * * @param cap the line end cap style */ @SuppressWarnings("WeakerAccess") public void setLineCap(LineCap cap) { CTLineProperties ln = getLn(this, true); if (ln == null) { return; } if (cap == null) { if (ln.isSetCap()) { ln.unsetCap(); } } else { ln.setCap(STLineCap.Enum.forInt(cap.ooxmlId)); } }
@SuppressWarnings("WeakerAccess") public LineCap getBorderCap(BorderEdge edge) { CTLineProperties ln = getCTLine(edge, false); if (ln == null || ln.isSetNoFill() || !ln.isSetSolidFill() || !ln.isSetCap()) { return null; } return LineCap.fromOoxmlId(ln.getCap().intValue()); }
/** * * @return the line end cap style */ @SuppressWarnings("WeakerAccess") public LineCap getLineCap() { PropertyFetcher<LineCap> fetcher = new PropertyFetcher<LineCap>() { @Override public boolean fetch(XSLFShape shape) { CTLineProperties ln = getLn(shape, false); if (ln != null && ln.isSetCap()) { setValue(LineCap.fromOoxmlId(ln.getCap().intValue())); return true; } return false; } }; fetchShapeProperty(fetcher); LineCap cap = fetcher.getValue(); if (cap == null) { CTLineProperties defaultLn = getDefaultLineProperties(); if (defaultLn != null && defaultLn.isSetCap()) { cap = LineCap.fromOoxmlId(defaultLn.getCap().intValue()); } } return cap; }
ln.setAlgn(STPenAlignment.CTR); if (!ln.isSetCap()) { ln.setCap(STLineCap.FLAT);