soui 5.0.0.1
Soui5 Doc
 
Loading...
Searching...
No Matches
SIconWnd Class Reference

图标控件 More...

#include <SCmnCtrl.h>

Public Member Functions

 SIconWnd ()
 构造函数
 
virtual ~SIconWnd ()
 析构函数
 
void SetIcon (HICON hIcon) OVERRIDE
 设置图标
 
virtual HRESULT SetAttribute (const SNS::SStringW &amp;amp;amp;amp;strAttribName, const SNS::SStringW &amp;amp;amp;amp;strValue, BOOL bLoading=FALSE)
 

Protected Member Functions

SIZE MeasureContent (int wid, int hei) override
 测量内容大小
 
void OnPaint (IRenderTarget *pRT)
 绘制控件
 
HRESULT OnAttrIcon (const SStringW &value, BOOL bLoading)
 
void OnScaleChanged (int scale) override
 Called when the scale of the window changes.
 

Protected Attributes

SStringW m_strIconSrc
 
HICON m_theIcon
 

Detailed Description

图标控件

图标控件。 @usage <icon src="icon:16" />

Definition at line 1027 of file SCmnCtrl.h.

Constructor & Destructor Documentation

◆ SIconWnd()

SIconWnd::SIconWnd ( )

构造函数

Definition at line 1147 of file SCmnCtrl.cpp.

◆ ~SIconWnd()

SIconWnd::~SIconWnd ( )
virtual

析构函数

Definition at line 1152 of file SCmnCtrl.cpp.

Member Function Documentation

◆ MeasureContent()

SIZE SIconWnd::MeasureContent ( int wid,
int hei )
overrideprotectedvirtual

测量内容大小

Parameters
wid父容器宽度
hei父容器高度
Returns
内容大小

Reimplemented from SWindow.

Definition at line 1166 of file SCmnCtrl.cpp.

◆ OnAttrIcon()

HRESULT SIconWnd::OnAttrIcon ( const SStringW & value,
BOOL bLoading )
protected

Definition at line 1190 of file SCmnCtrl.cpp.

◆ OnPaint()

void SIconWnd::OnPaint ( IRenderTarget * pRT)
protected

绘制控件

Parameters
pRT绘制设备句柄

Definition at line 1158 of file SCmnCtrl.cpp.

◆ OnScaleChanged()

void SIconWnd::OnScaleChanged ( int scale)
overrideprotectedvirtual

Called when the scale of the window changes.

Parameters
scaleThe new scale value.

Reimplemented from SWindow.

Definition at line 1197 of file SCmnCtrl.cpp.

◆ SetAttribute()

virtual HRESULT SIconWnd::SetAttribute ( const SNS::SStringW &amp;amp;amp;amp; strAttribName,
const SNS::SStringW &amp;amp;amp;amp; strValue,
BOOL bLoading = FALSE )
inlinevirtual

Reimplemented from SWindow.

Definition at line 1067 of file SCmnCtrl.h.

◆ SetIcon()

void SIconWnd::SetIcon ( HICON hIcon)

设置图标

Parameters
hIcon图标句柄

Definition at line 1180 of file SCmnCtrl.cpp.

Member Data Documentation

◆ m_strIconSrc

SStringW SIconWnd::m_strIconSrc
protected

Definition at line 1076 of file SCmnCtrl.h.

◆ m_theIcon

HICON SIconWnd::m_theIcon
protected

图标资源句柄

Definition at line 1077 of file SCmnCtrl.h.


The documentation for this class was generated from the following files: