IsCurveLinear

Verifies an object is a linear curve object.

Syntax

rhinoscriptsyntax.IsCurveLinear (object_id, segment_index=-1)

rhinoscript.curve.IsCurveLinear (object_id, segment_index=-1)

Parameters

object_id

Required.  String or Guid.  The object's identifier.

segment_index

Optional. Number. If object_id identifies a polycurve object, then segment_index identifies the curve segment of the polycurve to query.

Returns

Boolean

True if successful, otherwise False.

Example

import rhinoscriptsyntax as rs

id = rs.GetObject("Select a curve")

if rs.IsCurve(id):

    if rs.IsCurveLinear(id):

        print "The object is a linear curve."

    else:

        print "The object is not a linear curve."

else:

    print "The object is not a curve."

Also See

IsCurve

IsCurveClosed

IsCurvePeriodic

IsCurvePlanar