ViewGetClipPlanes Method

Returns all the clip planes of the view.

Namespace:  Tekla.Structures.Model.UI
Assembly:  Tekla.Structures.Model (in Tekla.Structures.Model.dll) Version: 2023.0.3
Syntax
public ClipPlaneCollection GetClipPlanes()

Return Value

Type: ClipPlaneCollection
The clip planes of the view.
Examples
The following example shows how all ClipPlanes are deleted from the first visible view:
using System;
using System.Collections;
using Tekla.Structures.Model.UI;
using Tekla.Structures.Geometry3d;

public class GetClipPlanesExample
{
    public void GetClipPlanesExample1()
    {
        ModelViewEnumerator ViewEnum = ViewHandler.GetVisibleViews();
        ViewEnum.MoveNext();
        View ActiveView = ViewEnum.Current;
        ClipPlaneCollection ClipPlanes = ActiveView.GetClipPlanes();
        if (ClipPlanes.Count > 0)
        {
            IEnumerator PlaneEnum = ClipPlanes.GetEnumerator();
            while (PlaneEnum.MoveNext())
            {
                ClipPlane CPlane = PlaneEnum.Current as ClipPlane;
                if (CPlane != null)
                    CPlane.Delete();
            }
        }
    }
}
See Also
Was this helpful?
The feedback you give here is not visible to other users. We use your comments to improve the content.
Previous
Next