Object Model Reference : Classes : C : CrossPoint : Properties : CrossPoint.PositionX |
Property PositionX As Double
Member of CrossPoint
The PositionX property returns the x-coordinate of the point of intersection of curve segments.
The PositionX property returns a read-only value.
The following VBA example creates two intersecting ellipses and combines them into a single curve. At the intersections of the ellipses (now subpaths), small circles are created.
Sub XPosition() |
Dim s1 As Shape, sr As New ShapeRange |
Dim s As Shape |
Dim cps As CrossPoints |
Dim cp As CrossPoint |
sr.Add ActiveLayer.CreateEllipse2(4, 4, 3) |
sr.Add ActiveLayer.CreateEllipse2(5, 3, 2) |
Set s = sr.Combine |
Set cps = s.Curve.Subpaths(1).GetIntersections(s.Curve.Subpaths(2)) |
For Each cp In cps |
ActiveLayer.CreateEllipse2 cp.PositionX, cp.PositionY, 0.1 |
Next cp |
End Sub |
Copyright 2013 Corel Corporation. All rights reserved.