/** * Initialize default structure of a new shape group */ internal static CT_GroupShape Prototype() { if (prototype == null) { CT_GroupShape shape = new CT_GroupShape(); CT_GroupShapeNonVisual nv = shape.AddNewNvGrpSpPr(); CT_NonVisualDrawingProps nvpr = nv.AddNewCNvPr(); nvpr.id = (0); nvpr.name = ("Group 0"); nv.AddNewCNvGrpSpPr(); CT_GroupShapeProperties sp = shape.AddNewGrpSpPr(); CT_GroupTransform2D t2d = sp.AddNewXfrm(); CT_PositiveSize2D p1 = t2d.AddNewExt(); p1.cx = (0); p1.cy = (0); CT_Point2D p2 = t2d.AddNewOff(); p2.x = (0); p2.y = (0); CT_PositiveSize2D p3 = t2d.AddNewChExt(); p3.cx = (0); p3.cy = (0); CT_Point2D p4 = t2d.AddNewChOff(); p4.x = (0); p4.y = (0); prototype = shape; } return(prototype); }
internal static CT_GroupShape Prototype() { if (XSSFShapeGroup.prototype == null) { CT_GroupShape ctGroupShape = new CT_GroupShape(); CT_GroupShapeNonVisual groupShapeNonVisual = ctGroupShape.AddNewNvGrpSpPr(); CT_NonVisualDrawingProps visualDrawingProps = groupShapeNonVisual.AddNewCNvPr(); visualDrawingProps.id = 0U; visualDrawingProps.name = "Group 0"; groupShapeNonVisual.AddNewCNvGrpSpPr(); CT_GroupTransform2D groupTransform2D = ctGroupShape.AddNewGrpSpPr().AddNewXfrm(); CT_PositiveSize2D ctPositiveSize2D1 = groupTransform2D.AddNewExt(); ctPositiveSize2D1.cx = 0L; ctPositiveSize2D1.cy = 0L; CT_Point2D ctPoint2D1 = groupTransform2D.AddNewOff(); ctPoint2D1.x = 0L; ctPoint2D1.y = 0L; CT_PositiveSize2D ctPositiveSize2D2 = groupTransform2D.AddNewChExt(); ctPositiveSize2D2.cx = 0L; ctPositiveSize2D2.cy = 0L; CT_Point2D ctPoint2D2 = groupTransform2D.AddNewChOff(); ctPoint2D2.x = 0L; ctPoint2D2.y = 0L; XSSFShapeGroup.prototype = ctGroupShape; } return(XSSFShapeGroup.prototype); }
public void SetCoordinates(int x1, int y1, int x2, int y2) { CT_GroupTransform2D xfrm = this.ctGroup.grpSpPr.xfrm; CT_Point2D off = xfrm.off; off.x = (long)x1; off.y = (long)y1; CT_PositiveSize2D ext = xfrm.ext; ext.cx = (long)x2; ext.cy = (long)y2; CT_Point2D chOff = xfrm.chOff; chOff.x = (long)x1; chOff.y = (long)y1; CT_PositiveSize2D chExt = xfrm.chExt; chExt.cx = (long)x2; chExt.cy = (long)y2; }
/** * Sets the coordinate space of this group. All children are constrained * to these coordinates. */ public void SetCoordinates(int x1, int y1, int x2, int y2) { CT_GroupTransform2D t2d = ctGroup.grpSpPr.xfrm; CT_Point2D off = t2d.off; off.x = (x1); off.y = (y1); CT_PositiveSize2D ext = t2d.ext; ext.cx = (x2); ext.cy = (y2); CT_Point2D chOff = t2d.chOff; chOff.x = (x1); chOff.y = (y1); CT_PositiveSize2D chExt = t2d.chExt; chExt.cx = (x2); chExt.cy = (y2); }
public CT_GroupTransform2D AddNewXfrm() { this.xfrmField = new CT_GroupTransform2D(); return(this.xfrmField); }