CStatusBarCtrl::GetTextLength
从状态栏控件的特定部分检索长度,在字符,该文本。
int GetTextLength(
int nPane,
int* pType = NULL
) const;
参数
nPane
检索的文本的部分从零开始的索引。pType
为接收类型信息的整数的指针。 该类型可以是以下值之一:0 该文本比状态栏的平面绘制带有边框显示较低。
SBT_NOBORDERS 该文本绘制,没有边框。
该文本父窗口绘制SBT_OWNERDRAW。
SBT_POPOUT 该文本高于状态栏的平面绘制带有边框显示。
返回值
长度,在字符,文本。
示例
int nType;
int nLength = m_wndSBC.GetTextLength(0, &nType);
switch( nType )
{
case 0:
// Text is drawn with a border to appear lower than the
// plane of the status bar
break;
case SBT_NOBORDERS:
// text is drawn without borders
break;
case SBT_OWNERDRAW:
// Text is drawn by the parent window
break;
case SBT_POPOUT:
// Text is drawn with a border to appear higher than the
// plane of the status bar
break;
}
要求
Header: afxcmn.h