public XDDFTextBody getTextBody() { if (legend.isSetTxPr()) { return new XDDFTextBody(this, legend.getTxPr()); } else { return null; } }
public XDDFTextBody getTextBody() { if (entry.isSetTxPr()) { return new XDDFTextBody(this, entry.getTxPr()); } else { return null; } }
@Beta public XDDFTextBody getTextBody() { CTTextBody txBody = getTextBody(false); if (txBody == null) { return null; } return new XDDFTextBody(this, txBody); }
protected XSSFSimpleShape(XSSFDrawing drawing, CTShape ctShape) { this.drawing = drawing; this.ctShape = ctShape; _paragraphs = new ArrayList<>(); // initialize any existing paragraphs - this will be the default body // paragraph in a new shape, // or existing paragraphs that have been loaded from the file CTTextBody body = ctShape.getTxBody(); if (body == null) { _textBody = null; } else { _textBody = new XDDFTextBody(this, body); for (int i = 0; i < body.sizeOfPArray(); i++) { _paragraphs.add(new XSSFTextParagraph(body.getPArray(i), ctShape)); } } }
@Override protected CTTextBody getTextBody(boolean create) { CTShape shape = (CTShape) getXmlObject(); CTTextBody txBody = shape.getTxBody(); if (txBody == null && create) { XDDFTextBody body = new XDDFTextBody(this); initTextBody(body); shape.setTxBody(body.getXmlObject()); txBody = shape.getTxBody(); } return txBody; }
@Override protected CTTextBody getTextBody(boolean create) { CTTableCell cell = getCell(); CTTextBody txBody = cell.getTxBody(); if (txBody == null && create) { XDDFTextBody body = new XDDFTextBody(this); initTextBody(body); cell.setTxBody(body.getXmlObject()); txBody = cell.getTxBody(); } return txBody; }
public XDDFTextBody getBody() { if (!title.isSetTx()) { title.addNewTx(); } CTTx tx = title.getTx(); if (tx.isSetStrRef()) { tx.unsetStrRef(); } if (!tx.isSetRich()) { tx.addNewRich(); } return new XDDFTextBody(parent, tx.getRich()); }
/** * * @param shapeId * 1-based shapeId */ static CTShape prototype(int shapeId) { CTShape ct = CTShape.Factory.newInstance(); CTShapeNonVisual nvSpPr = ct.addNewNvSpPr(); CTNonVisualDrawingProps cnv = nvSpPr.addNewCNvPr(); cnv.setName("TextBox " + shapeId); cnv.setId(shapeId); nvSpPr.addNewCNvSpPr().setTxBox(true); nvSpPr.addNewNvPr(); CTShapeProperties spPr = ct.addNewSpPr(); CTPresetGeometry2D prst = spPr.addNewPrstGeom(); prst.setPrst(STShapeType.RECT); prst.addNewAvLst(); XDDFTextBody body = new XDDFTextBody(null); initTextBody(body); ct.setTxBody(body.getXmlObject()); return ct; } }
geom.addNewAvLst(); XDDFTextBody body = new XDDFTextBody(null, shape.addNewTxBody()); XDDFTextParagraph p = body.initialize(); XDDFRunProperties rp = p.getAfterLastRunProperties();
public XDDFTextBody getTextBody() { if (legend.isSetTxPr()) { return new XDDFTextBody(this, legend.getTxPr()); } else { return null; } }
@Beta public XDDFTextBody getTextBody() { CTTextBody txBody = getTextBody(false); if (txBody == null) { return null; } return new XDDFTextBody(this, txBody); }
public XDDFTextBody getTextBody() { if (entry.isSetTxPr()) { return new XDDFTextBody(this, entry.getTxPr()); } else { return null; } }
protected XSSFSimpleShape(XSSFDrawing drawing, CTShape ctShape) { this.drawing = drawing; this.ctShape = ctShape; _paragraphs = new ArrayList<>(); // initialize any existing paragraphs - this will be the default body // paragraph in a new shape, // or existing paragraphs that have been loaded from the file CTTextBody body = ctShape.getTxBody(); if (body == null) { _textBody = null; } else { _textBody = new XDDFTextBody(this, body); for (int i = 0; i < body.sizeOfPArray(); i++) { _paragraphs.add(new XSSFTextParagraph(body.getPArray(i), ctShape)); } } }
@Override protected CTTextBody getTextBody(boolean create) { CTTableCell cell = getCell(); CTTextBody txBody = cell.getTxBody(); if (txBody == null && create) { XDDFTextBody body = new XDDFTextBody(this); initTextBody(body); cell.setTxBody(body.getXmlObject()); txBody = cell.getTxBody(); } return txBody; }
@Override protected CTTextBody getTextBody(boolean create) { CTShape shape = (CTShape) getXmlObject(); CTTextBody txBody = shape.getTxBody(); if (txBody == null && create) { XDDFTextBody body = new XDDFTextBody(this); initTextBody(body); shape.setTxBody(body.getXmlObject()); txBody = shape.getTxBody(); } return txBody; }
public XDDFTextBody getBody() { if (!title.isSetTx()) { title.addNewTx(); } CTTx tx = title.getTx(); if (tx.isSetStrRef()) { tx.unsetStrRef(); } if (!tx.isSetRich()) { tx.addNewRich(); } return new XDDFTextBody(parent, tx.getRich()); }
/** * * @param shapeId * 1-based shapeId */ static CTShape prototype(int shapeId) { CTShape ct = CTShape.Factory.newInstance(); CTShapeNonVisual nvSpPr = ct.addNewNvSpPr(); CTNonVisualDrawingProps cnv = nvSpPr.addNewCNvPr(); cnv.setName("TextBox " + shapeId); cnv.setId(shapeId); nvSpPr.addNewCNvSpPr().setTxBox(true); nvSpPr.addNewNvPr(); CTShapeProperties spPr = ct.addNewSpPr(); CTPresetGeometry2D prst = spPr.addNewPrstGeom(); prst.setPrst(STShapeType.RECT); prst.addNewAvLst(); XDDFTextBody body = new XDDFTextBody(null); initTextBody(body); ct.setTxBody(body.getXmlObject()); return ct; } }
geom.addNewAvLst(); XDDFTextBody body = new XDDFTextBody(null, shape.addNewTxBody()); XDDFTextParagraph p = body.initialize(); XDDFRunProperties rp = p.getAfterLastRunProperties();