how to Get shape in attachments files?


Author
Message
panbo hong
panbo hong
Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)
Group: Forum Members
Posts: 4, Visits: 1
I have two shapes ,how to Get shape in attachments files? thanks!
Attachments
SchematicDiagram.gif (173 views, 16.00 KB)
Reply
Nevron Support
Nevron Support
Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)
Group: Administrators
Posts: 3.1K, Visits: 4.2K

Hi,

The current version of the diagramming component does not support this kind of operation, but the new diagramming component we are currently working on will support them. Currently with the old diagram the closest thing to what you want can be achieved like this:

// Create a graphics path that represents the model of the polygon

GraphicsPath path = new GraphicsPath();

path.AddRectangle(new RectangleF(0, 0, 200, 150));

path.AddArc(117, 0, 300, 150, 135, 90);

 

// Host the graphics path in a NCustomPath primitive

NCustomPath pathPrimitive = new NCustomPath(path, PathType.ClosedFigure);

 

// Create a composite shape and put the path primitive in it

NCompositeShape shape = new NCompositeShape();

shape.Primitives.AddChild(pathPrimitive);

 

// Add the composite shape to the drawing document's active layer

m_View.Document.ActiveLayer.AddChild(shape);

 

// Update the model bounds

shape.UpdateModelBounds();

 

// Reposition the shape

shape.Location = new NPointF(200, 200);

Note that this is not done through means of Constructive Solid Geometry (CSG). Real CSG support will be available in the new diagramming component we are currently working on.



Best Regards,
Nevron Support Team


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...





Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search