Learn How To set the style of the shapes in a visio page with Aspose.Diagram
In this tutorial, we'll set the style of the shapes in a visio file.
We'll start by creating a new diagram using the Aspose.Diagram library and draw shapes.
In this tutorial, we'll set the style of the shapes in a visio file.
We'll start by creating a new diagram using the Aspose.Diagram library and draw shapes.
using System;
using System.Drawing;
using System.IO;
using Aspose.Diagram.Saving;
using Aspose.Diagram;
//Set line weight for the shape
Aspose.Diagram.Diagram diagram = new Aspose.Diagram.Diagram();
diagram.Pages[0].PageSheet.PageProps.PageWidth.Value = 10;
diagram.Pages[0].PageSheet.PageProps.PageHeight.Value = 10;
var shapeId=diagram.Pages[0].DrawEllipse(5, 5, 5, 5);
// Get shape by its ID
Aspose.Diagram.Shape shape = diagram.Pages[0].Shapes.GetShape(1);
// Set line weight, defualt in IN
shape.Line.LineWeight=new DoubleValue(5,MeasureConst.PT);
diagram
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising. Google's data policies
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.