public ShapeGeometryRow AddInfiniteLine(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a, ShapeSheet.CellValueLiteral b) { var row = ShapeGeometryRow.CreateInfiniteLine(x, y, a, b); this.Rows.Add(row); return(row); }
public ShapeGeometryRow AddArcTo(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a) { var row = ShapeGeometryRow.CreateArcTo(x, y, a); this.Rows.Add(row); return(row); }
public ShapeGeometryRow AddEllipse(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a, ShapeSheet.CellValueLiteral b, ShapeSheet.CellValueLiteral c, ShapeSheet.CellValueLiteral d) { var row = ShapeGeometryRow.CreateEllipse(x, y, a, b, c, d); this.Rows.Add(row); return(row); }
public ShapeGeometryRow AddLineTo(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y) { var row = ShapeGeometryRow.CreateLineTo(x, y); this.Rows.Add(row); return(row); }
public ShapeGeometryRow AddNURBSTo(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a, ShapeSheet.CellValueLiteral b, ShapeSheet.CellValueLiteral c, ShapeSheet.CellValueLiteral d, ShapeSheet.CellValueLiteral e) { var row = ShapeGeometryRow.CreateNURBSTo(x, y, a, b, c, d, e); this.Rows.Add(row); return(row); }
public static ShapeGeometryRow CreateMoveTo(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y) { // http://msdn.microsoft.com/en-us/library/aa195679(v=office.11).aspx var row = new ShapeGeometryRow(IVisio.VisRowTags.visTagMoveTo); row.X = x; row.Y = y; return(row); }
public static void Set(IVisio.Shape shape, string name, ShapeSheet.CellValueLiteral udfcell_value, ShapeSheet.CellValueLiteral udfcell_prompt) { if (shape == null) { throw new System.ArgumentNullException(nameof(shape)); } UserDefinedCellHelper.CheckValidName(name); if (UserDefinedCellHelper.Contains(shape, name)) { string full_prop_name = UserDefinedCellHelper.GetRowName(name); if (udfcell_value.HasValue) { string value_cell_name = full_prop_name; var cell = shape.CellsU[value_cell_name]; cell.FormulaU = VisioAutomation.Utilities.Convert.StringToFormulaString(udfcell_value.Value); } if (udfcell_prompt.HasValue) { string prompt_cell_name = full_prop_name + ".Prompt"; var cell = shape.CellsU[prompt_cell_name]; cell.FormulaU = VisioAutomation.Utilities.Convert.StringToFormulaString(udfcell_prompt.Value); } return; } short row = shape.AddNamedRow( UserDefinedCellHelper._userdefinedcell_section, name, (short)IVisio.VisRowIndices.visRowUser); var writer = new VisioAutomation.ShapeSheet.Writers.SrcWriter(); if (udfcell_value.HasValue) { var src = new ShapeSheet.Src(UserDefinedCellHelper._userdefinedcell_section, row, (short)IVisio.VisCellIndices.visUserValue); var formula = VisioAutomation.Utilities.Convert.StringToFormulaString(udfcell_value.Value); writer.SetFormula(src, formula); } if (udfcell_prompt.HasValue) { var src = new ShapeSheet.Src(UserDefinedCellHelper._userdefinedcell_section, row, (short)IVisio.VisCellIndices.visUserPrompt); var formula = VisioAutomation.Utilities.Convert.StringToFormulaString(udfcell_prompt.Value); writer.SetFormula(src, formula); } writer.Commit(shape); }
public static GeometryRow CreatePolylineTo(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a) { // http://msdn.microsoft.com/en-us/library/aa195682(v=office.11).aspx var row = new GeometryRow(IVisio.VisRowTags.visTagPolylineTo); row.X = x; row.Y = y; row.A = a; return(row); }
public static ShapeGeometryRow CreateSplineKnot(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a) { // http://msdn.microsoft.com/en-us/library/aa195667(v=office.11).aspx var row = new ShapeGeometryRow(IVisio.VisRowTags.visTagSplineSpan); row.X = x; row.Y = y; row.A = a; return(row); }
public static ShapeGeometryRow CreateInfiniteLine(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a, ShapeSheet.CellValueLiteral b) { // http://msdn.microsoft.com/en-us/library/aa195682(v=office.11).aspx var row = new ShapeGeometryRow(IVisio.VisRowTags.visTagInfiniteLine); row.X = x; row.Y = y; row.A = a; row.B = b; return(row); }
public static ShapeGeometryRow CreateSplineStart(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a, ShapeSheet.CellValueLiteral b, ShapeSheet.CellValueLiteral c, ShapeSheet.CellValueLiteral d) { // http://msdn.microsoft.com/en-us/library/aa195663(v=office.11).aspx var row = new ShapeGeometryRow(IVisio.VisRowTags.visTagSplineBeg); row.X = x; row.Y = y; row.A = a; row.B = b; row.C = c; row.D = d; return(row); }
public static GeometryRow CreateEllipticalArcTo(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a, ShapeSheet.CellValueLiteral b, ShapeSheet.CellValueLiteral c, ShapeSheet.CellValueLiteral d) { // http://msdn.microsoft.com/en-us/library/aa195660(v=office.11).aspx var row = new GeometryRow(IVisio.VisRowTags.visTagEllipticalArcTo); row.X = x; row.Y = y; row.A = a; row.B = b; row.C = c; row.D = d; return(row); }
public static ShapeGeometryRow CreateNurbsTo(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a, ShapeSheet.CellValueLiteral b, ShapeSheet.CellValueLiteral c, ShapeSheet.CellValueLiteral d, ShapeSheet.CellValueLiteral e) { // http://msdn.microsoft.com/en-us/library/aa195685(v=office.11).aspx var row = new ShapeGeometryRow(IVisio.VisRowTags.visTagEllipse); row.X = x; row.Y = y; row.A = a; row.B = b; row.C = c; row.D = d; row.E = e; return(row); }
private string SmartStringToFormulaString(ShapeSheet.CellValueLiteral formula, bool force_no_quoting) { if (!formula.HasValue) { return(null); } if (formula.Value.Length == 0) { return(VisioAutomation.Utilities.Convert.StringToFormulaString(formula.Value)); } if (formula.Value[0] != '\"') { if (force_no_quoting) { return(formula.Value); } return(VisioAutomation.Utilities.Convert.StringToFormulaString(formula.Value)); } return(formula.Value); }
private string SmartStringToFormulaString(ShapeSheet.CellValueLiteral formula, bool force_no_quoting) { if (!formula.HasValue) { return(null); } if (formula.Value.Length == 0) { return(formula.Encode()); } if (formula.Value[0] != '\"') { if (force_no_quoting) { return(formula.Value); } return(formula.Encode()); } return(formula.Value); }
public GeometryRow AddSplineKnot(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a) { var row = GeometryRow.CreateSplineKnot(x, y, a); this.Rows.Add(row); return(row); }
public GeometryRow AddPolylineTo(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a) { var row = GeometryRow.CreatePolylineTo(x, y, a); this.Rows.Add(row); return(row); }
public GeometryRow AddSplineStart(ShapeSheet.CellValueLiteral x, ShapeSheet.CellValueLiteral y, ShapeSheet.CellValueLiteral a, ShapeSheet.CellValueLiteral b, ShapeSheet.CellValueLiteral c, ShapeSheet.CellValueLiteral d) { var row = GeometryRow.CreateSplineStart(x, y, a, b, c, d); this.Rows.Add(row); return(row); }
protected SrcFormulaPair newpair(ShapeSheet.Src src, ShapeSheet.CellValueLiteral formula) { return(new SrcFormulaPair(src, formula)); }
public SrcFormulaPair(ShapeSheet.Src src, ShapeSheet.CellValueLiteral formula) { this.Src = src; this.Formula = formula; }
public CustomPropertyCells(ShapeSheet.CellValueLiteral value) { this.Value = value; this.Type = 2; }