2#include <control/SEdit.h>
7 :
m_crCue(RGBA(0xcc, 0xcc, 0xcc, 0xff))
17 if (!
m_strCue.GetText(FALSE).IsEmpty() && GetWindowTextLength() == 0)
24 if (!
m_strCue.GetText(FALSE).IsEmpty() && GetWindowTextLength() == 0)
31 algin &= ~(DT_CENTER | DT_RIGHT);
32 if (m_dwStyle & ES_CENTER)
34 else if (m_dwStyle & ES_RIGHT)
43 if (!strCue.IsEmpty() && GetWindowTextLength() == 0 && !IsFocused())
46 BeforePaint(pRT, painter);
51 CRect rcInsetPixel = GetStyle().GetPadding();
52 rc.DeflateRect(rcInsetPixel.left, rcInsetPixel.top, rcInsetPixel.right, rcInsetPixel.bottom);
56 AfterPaint(pRT, painter);
67 HRESULT hr = __baseCls::OnLanguageChanged();
void OnSetFocus(SWND wndOld)
Handle set focus event.
void OnKillFocus(SWND wndFocus)
Handle kill focus event.
virtual HRESULT OnLanguageChanged()
Handle language change event.
void OnPaint(IRenderTarget *pRT)
Paint the control.
void GetCueText(IStringT *pStr) SCONST
Get the cue text.
UINT GetCueTextAlign()
Get the alignment of the cue text.
Helper class for painting.
void OnSetFocus(SWND wndOld)
Handle set focus message.
void OnPaint(IRenderTarget *pRT)
Handle paint message.
void OnKillFocus(SWND wndFocus)
Handle kill focus message.
UINT GetTextAlign() const
Retrieves the text alignment of the window.
Interface for rendering target objects.
HRESULT DrawText(LPCTSTR pszText, int cchLen, LPRECT pRc, UINT uFormat) PURE
Draw text within a rectangle.
COLORREF SetTextColor(COLORREF color) PURE
Sets the current text color.