Rhino C++ API  8.5
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
ON_2iSize Class Reference

#include <opennurbs_ipoint.h>

Public Member Functions

 ON_2iSize ()=default
 
 ON_2iSize (const ON_2iSize &)=default
 
 ON_2iSize (int cx, int cy)
 
 ~ON_2iSize ()=default
 
bool IsSet () const
 
bool IsZero () const
 
ON_2iSizeoperator= (const ON_2iSize &)=default
 

Static Public Member Functions

static int Compare (const ON_2iSize &lhs, const ON_2iSize &rhs)
 
static int ComparePointer (const ON_2iSize *lhs, const ON_2iSize *rhs)
 

Public Attributes

ON__INT32 cx
 
ON__INT32 cy
 

Static Public Attributes

static const ON_2iSize Unset
 (ON_UNSET_INT_INDEX,ON_UNSET_INT_INDEX) More...
 
static const ON_2iSize Zero
 (0,0) More...
 

Detailed Description

Class ON_2iSize For those situations where a Windows SDK SIZE or MFC CSize value needs to be used in code that does not link with MFC.

Constructor & Destructor Documentation

◆ ON_2iSize() [1/3]

ON_2iSize::ON_2iSize ( )
default

Default construction intentionally leaves x and y uninitialized. Use something like ON_2iSize pt(1,2); or ON_2iSize pt = ON_2iSize::Zero; when you need an initialized ON_2iSize.

◆ ~ON_2iSize()

ON_2iSize::~ON_2iSize ( )
default

◆ ON_2iSize() [2/3]

ON_2iSize::ON_2iSize ( const ON_2iSize )
default

◆ ON_2iSize() [3/3]

ON_2iSize::ON_2iSize ( int  cx,
int  cy 
)

Member Function Documentation

◆ Compare()

static int ON_2iSize::Compare ( const ON_2iSize lhs,
const ON_2iSize rhs 
)
static

Dictionary compare. Returns: -1: lhs < rhs 0: lsh == rsh +1: lhs > rhs

◆ ComparePointer()

static int ON_2iSize::ComparePointer ( const ON_2iSize lhs,
const ON_2iSize rhs 
)
static

Dictionary compare. Returns: -1: lhs < rhs 0: lsh == rsh +1: lhs > rhs

◆ IsSet()

bool ON_2iSize::IsSet ( ) const

Returns: true if neither cx nor cy are ON_UNSET_INT_INDEX.

◆ IsZero()

bool ON_2iSize::IsZero ( ) const

Returns: true if both cx and cy are 0.

◆ operator=()

ON_2iSize& ON_2iSize::operator= ( const ON_2iSize )
default

Member Data Documentation

◆ cx

ON__INT32 ON_2iSize::cx

◆ cy

ON__INT32 ON_2iSize::cy

◆ Unset

const ON_2iSize ON_2iSize::Unset
static

(ON_UNSET_INT_INDEX,ON_UNSET_INT_INDEX)

◆ Zero

const ON_2iSize ON_2iSize::Zero
static

(0,0)