use of org.openxmlformats.schemas.drawingml.x2006.spreadsheetDrawing.CTGroupShapeNonVisual in project poi by apache.
the class XSSFShapeGroup method prototype.
/**
* Initialize default structure of a new shape group
*/
protected static CTGroupShape prototype() {
if (prototype == null) {
CTGroupShape shape = CTGroupShape.Factory.newInstance();
CTGroupShapeNonVisual nv = shape.addNewNvGrpSpPr();
CTNonVisualDrawingProps nvpr = nv.addNewCNvPr();
nvpr.setId(0);
nvpr.setName("Group 0");
nv.addNewCNvGrpSpPr();
CTGroupShapeProperties sp = shape.addNewGrpSpPr();
CTGroupTransform2D t2d = sp.addNewXfrm();
CTPositiveSize2D p1 = t2d.addNewExt();
p1.setCx(0);
p1.setCy(0);
CTPoint2D p2 = t2d.addNewOff();
p2.setX(0);
p2.setY(0);
CTPositiveSize2D p3 = t2d.addNewChExt();
p3.setCx(0);
p3.setCy(0);
CTPoint2D p4 = t2d.addNewChOff();
p4.setX(0);
p4.setY(0);
prototype = shape;
}
return prototype;
}
use of org.openxmlformats.schemas.drawingml.x2006.spreadsheetDrawing.CTGroupShapeNonVisual in project poi by apache.
the class XSLFSlide method prototype.
private static CTSlide prototype() {
CTSlide ctSlide = CTSlide.Factory.newInstance();
CTCommonSlideData cSld = ctSlide.addNewCSld();
CTGroupShape spTree = cSld.addNewSpTree();
CTGroupShapeNonVisual nvGrpSpPr = spTree.addNewNvGrpSpPr();
CTNonVisualDrawingProps cnvPr = nvGrpSpPr.addNewCNvPr();
cnvPr.setId(1);
cnvPr.setName("");
nvGrpSpPr.addNewCNvGrpSpPr();
nvGrpSpPr.addNewNvPr();
CTGroupShapeProperties grpSpr = spTree.addNewGrpSpPr();
CTGroupTransform2D xfrm = grpSpr.addNewXfrm();
CTPoint2D off = xfrm.addNewOff();
off.setX(0);
off.setY(0);
CTPositiveSize2D ext = xfrm.addNewExt();
ext.setCx(0);
ext.setCy(0);
CTPoint2D choff = xfrm.addNewChOff();
choff.setX(0);
choff.setY(0);
CTPositiveSize2D chExt = xfrm.addNewChExt();
chExt.setCx(0);
chExt.setCy(0);
ctSlide.addNewClrMapOvr().addNewMasterClrMapping();
return ctSlide;
}
use of org.openxmlformats.schemas.drawingml.x2006.spreadsheetDrawing.CTGroupShapeNonVisual in project poi by apache.
the class XSLFGroupShape method prototype.
/**
* @param shapeId 1-based shapeId
*/
static CTGroupShape prototype(int shapeId) {
CTGroupShape ct = CTGroupShape.Factory.newInstance();
CTGroupShapeNonVisual nvSpPr = ct.addNewNvGrpSpPr();
CTNonVisualDrawingProps cnv = nvSpPr.addNewCNvPr();
cnv.setName("Group " + shapeId);
cnv.setId(shapeId + 1);
nvSpPr.addNewCNvGrpSpPr();
nvSpPr.addNewNvPr();
ct.addNewGrpSpPr();
return ct;
}
Aggregations