Rhino C++ API  7.26
Public Types | Public Member Functions | Protected Member Functions | Friends | List of all members
CRhinoUiExpandableTabCtrlItem Class Reference

#include <RhinoSdkUiExpandableTabCtrl.h>

Public Types

enum  item_states {
  is_expanded = 0, is_active, is_hidden, is_pressed,
  is_invalid
}
 

Public Member Functions

 CRhinoUiExpandableTabCtrlItem ()
 
 CRhinoUiExpandableTabCtrlItem (const CRhinoUiExpandableTabCtrlItem &)
 
virtual ~CRhinoUiExpandableTabCtrlItem ()=default
 
CDialog * GetDialogPage () const
 
CRect GetPageRect () const
 
CSize GetPageSize () const
 
class CRhinoUiExpandableTabCtrlGetTabCtrl () const
 
CRect GetTabRect () const
 
int HitTest (CPoint pt) const
 
int ImageIndex () const
 
bool IsTabHidden () const
 
bool ItemState (item_states flag) const
 
LPCTSTR Name () const
 
const CRhinoUiExpandableTabCtrlItemoperator= (const CRhinoUiExpandableTabCtrlItem &)
 
bool PointOverItem (CPoint pt, bool bCheckPageRect=false) const
 

Protected Member Functions

virtual void DrawItem (CDC &dc)
 
CRect GetExpandContractButtonRect () const
 
void ScrollTabClientPoint (CPoint &pt) const
 
void ScrollTabClientRect (CRect &r) const
 
bool SetItemState (item_states flag, bool b)
 
bool UseSpecialColors () const
 

Friends

class CRhinoUiExpandableTabCtrl
 
class CRhinoUiModlessDockingDialogManager
 

Detailed Description

Copyright (c) 1993-2016 Robert McNeel & Associates. All rights reserved. Rhinoceros is a registered trademark of Robert McNeel & Associates.

THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.

For complete Rhino SDK copyright information see http://www.rhino3d.com/developer. CRhinoUiExpandableTabCtrlItem

Description: Control class for tab items. Used by CRhinoUiExpandableTabCtrl class bellow.

Member Enumeration Documentation

◆ item_states

Description: States the tab page may be in. They are not mutually exclusive.

Enumerator
is_expanded 

Tab page is visible.

is_active 

Mouse is currently over this item and so it is highlighted.

is_hidden 

If this is set to true then the tab does not appear in the tab control.

is_pressed 
is_invalid 

For internal use, should always be last item in list.

Constructor & Destructor Documentation

◆ CRhinoUiExpandableTabCtrlItem() [1/2]

CRhinoUiExpandableTabCtrlItem::CRhinoUiExpandableTabCtrlItem ( )

◆ ~CRhinoUiExpandableTabCtrlItem()

virtual CRhinoUiExpandableTabCtrlItem::~CRhinoUiExpandableTabCtrlItem ( )
virtualdefault

◆ CRhinoUiExpandableTabCtrlItem() [2/2]

CRhinoUiExpandableTabCtrlItem::CRhinoUiExpandableTabCtrlItem ( const CRhinoUiExpandableTabCtrlItem )

Member Function Documentation

◆ DrawItem()

virtual void CRhinoUiExpandableTabCtrlItem::DrawItem ( CDC &  dc)
protectedvirtual

Description: Draw tab caption

Parameters: dc [in] Tab control device context to be used when drawing.

See Also: CRhinoUiExpandableTabCtrlItem::GetTabRect() CRhinoUiExpandableTabCtrlItem::ItemState() CRhinoUiExpandableTabCtrlItem::DrawItemArrow()

◆ GetDialogPage()

CDialog* CRhinoUiExpandableTabCtrlItem::GetDialogPage ( ) const

Description: Get the dialog page associated with this item.

Returns: If the tab has been added and the page has been created then a valid pointer to the page associated with this item will be returned. If the page has not been created then NULL is returned.

See Also: CRhinoUiExpandableTabCtrl::AddPage() CRhinoUiExpandableTabCtrl::InsertPage()

◆ GetExpandContractButtonRect()

CRect CRhinoUiExpandableTabCtrlItem::GetExpandContractButtonRect ( ) const
protected

Description: Get the expand/contract button rectangle.

Returns: Expand/contract button rectangle in tab control client window units.

See Also: CRhinoUiExpandableTabCtrlItem::ScrollTabClientRect()

◆ GetPageRect()

CRect CRhinoUiExpandableTabCtrlItem::GetPageRect ( ) const

Description: Display rectangle associated with this item if it is expanded. If the item is hidden or contracted an empty rectangle is returned.

Returns: Display rectangle associated with this item if it is expanded. If the item is hidden or contracted an empty rectangle is returned.

◆ GetPageSize()

CSize CRhinoUiExpandableTabCtrlItem::GetPageSize ( ) const

Description: Get the size of the page associated with this item.

Returns: Return the size of the dialog page associated with this item.

◆ GetTabCtrl()

class CRhinoUiExpandableTabCtrl* CRhinoUiExpandableTabCtrlItem::GetTabCtrl ( ) const

Description: Get pointer to tab control this item is inserted in.

Returns: Returns pointer to tab control this item is inserted in or NULL if not inserted yet.

See Also: CRhinoUiExpandableTabCtrl::AddPage() CRhinoUiExpandableTabCtrl::InsertPage()

◆ GetTabRect()

CRect CRhinoUiExpandableTabCtrlItem::GetTabRect ( ) const

Description: The tab rectangle is the rectangle used to display the tab name and expand/contract button.

Returns: Tab caption rectangle if item is not hidden. If item is hidden an empty rectangle is returned.

◆ HitTest()

int CRhinoUiExpandableTabCtrlItem::HitTest ( CPoint  pt) const

Description: Test to see if point is over item.

Parameters: pt [in] Point in tab control client window coordinates.

Returns: Returns CRhinoUiExpandableTabCtrl::hit_test value which identifies which part, if any, the point is over.

See Also: CRhinoUiExpandableTabCtrl::hit_test

◆ ImageIndex()

int CRhinoUiExpandableTabCtrlItem::ImageIndex ( ) const

Description: Index into image list, if provided, which will appear to the left of Name() Returns: Only meaningfull if CRhinoUiExpandableTabCtrl::SetImageList() called. If so it is a zero based index of the image to be displayed to the left of the tab name.

◆ IsTabHidden()

bool CRhinoUiExpandableTabCtrlItem::IsTabHidden ( ) const

Description: Check to see if hidden state is set.

Returns: Returns true if CRhinoUiExpandableTabCtrlItem::is_hidden flag is set.

See Also: CRhinoUiExpandableTabCtrlItem::SetItemState() CRhinoUiExpandableTabCtrlItem::ItemState()

◆ ItemState()

bool CRhinoUiExpandableTabCtrlItem::ItemState ( item_states  flag) const

Description: Check to see if an item state is set.

Parameters: flag [in] Flag to check

Returns: If flag is set then returns true otherwise false.

See Also: CRhinoUiExpandableTabCtrlItem::SetItemState()

◆ Name()

LPCTSTR CRhinoUiExpandableTabCtrlItem::Name ( ) const

Description: Tab label Returns: Text which will left aligned on the tab

◆ operator=()

const CRhinoUiExpandableTabCtrlItem& CRhinoUiExpandableTabCtrlItem::operator= ( const CRhinoUiExpandableTabCtrlItem )

◆ PointOverItem()

bool CRhinoUiExpandableTabCtrlItem::PointOverItem ( CPoint  pt,
bool  bCheckPageRect = false 
) const

Description: Check to see if point is over this tab or tab page.

Parameters: pt [in] Point to test in tab control client window coordinates. bCheckPageRect [in] If true will check to see if point is over client are of tab page. If false then only checks tab label. Returns: Returns true if point is over the tab. If bCheckPageRect is true then true will be returned of point is over the page.

◆ ScrollTabClientPoint()

void CRhinoUiExpandableTabCtrlItem::ScrollTabClientPoint ( CPoint &  pt) const
protected

Description: If the tab control has a scroll bar visible then adjust the point to reflect the current scroll bar position.

Parameters: pt [in/out] Point to adjust

See Also: CRhinoUiExpandableTabCtrl::ScrollTabClientPoint()

◆ ScrollTabClientRect()

void CRhinoUiExpandableTabCtrlItem::ScrollTabClientRect ( CRect &  r) const
protected

Description: If the tab control has a scroll bar visible then adjust the rectangle to reflect the current scroll bar position.

Parameters: r [in/out] Rectangle to adjust

See Also: CRhinoUiExpandableTabCtrl::ScrollTabClientRect()

◆ SetItemState()

bool CRhinoUiExpandableTabCtrlItem::SetItemState ( item_states  flag,
bool  b 
)
protected

Description: Set CRhinoUiExpandableTabCtrlItem::item_states flag.

Parameters: flag [in] Item state flag to set b [in] New value for item state flag

Returns: Returns previous item state flag value.

See Also: CRhinoUiExpandableTabCtrlItem::ItemState()

◆ UseSpecialColors()

bool CRhinoUiExpandableTabCtrlItem::UseSpecialColors ( ) const
protected

Friends And Related Function Documentation

◆ CRhinoUiExpandableTabCtrl

friend class CRhinoUiExpandableTabCtrl
friend

◆ CRhinoUiModlessDockingDialogManager