Made wxInfoBar::SetFont() change the text message font.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@62269 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -66,6 +66,14 @@ public:
|
|||||||
// get the currently used effect animation duration
|
// get the currently used effect animation duration
|
||||||
int GetEffectDuration() const { return m_effectDuration; }
|
int GetEffectDuration() const { return m_effectDuration; }
|
||||||
|
|
||||||
|
|
||||||
|
// overridden base class methods
|
||||||
|
// -----------------------------
|
||||||
|
|
||||||
|
// setting the font of this window sets it for the text control inside it
|
||||||
|
// (default font is a larger and bold version of the normal one)
|
||||||
|
virtual bool SetFont(const wxFont& font);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
// common part of all ctors
|
// common part of all ctors
|
||||||
void Init();
|
void Init();
|
||||||
|
@@ -108,6 +108,18 @@ bool wxInfoBar::Create(wxWindow *parent, wxWindowID winid)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool wxInfoBar::SetFont(const wxFont& font)
|
||||||
|
{
|
||||||
|
if ( !wxInfoBarBase::SetFont(font) )
|
||||||
|
return false;
|
||||||
|
|
||||||
|
// check that we're not called before Create()
|
||||||
|
if ( m_text )
|
||||||
|
m_text->SetFont(font);
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
void wxInfoBar::UpdateParent()
|
void wxInfoBar::UpdateParent()
|
||||||
{
|
{
|
||||||
wxWindow * const parent = wxGetTopLevelParent(GetParent());
|
wxWindow * const parent = wxGetTopLevelParent(GetParent());
|
||||||
|
Reference in New Issue
Block a user