Have wxPGTextCtrlEditor::UpdateControl() update wxTextCtrl font boldness based on property's modified-status
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@57568 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -283,9 +283,22 @@ void wxPGTextCtrlEditor::UpdateControl( wxPGProperty* property, wxWindow* ctrl )
|
||||
else
|
||||
s = property->GetDisplayedString();
|
||||
|
||||
tc->SetValue(s);
|
||||
}
|
||||
tc->SetValue(s);
|
||||
|
||||
// Update font boldness
|
||||
wxPropertyGrid* pg = property->GetGrid();
|
||||
if ( pg->HasFlag(wxPG_BOLD_MODIFIED) )
|
||||
{
|
||||
if ( property->HasFlag(wxPG_PROP_MODIFIED) )
|
||||
tc->SetFont(pg->GetCaptionFont());
|
||||
else
|
||||
tc->SetFont(pg->GetFont());
|
||||
|
||||
#if defined(__WXMSW__) && !defined(__WXWINCE__)
|
||||
::SendMessage(GetHwndOf(tc), EM_SETMARGINS, EC_LEFTMARGIN | EC_RIGHTMARGIN, MAKELONG(0, 0));
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
// Provided so that, for example, ComboBox editor can use the same code
|
||||
// (multiple inheritance would get way too messy).
|
||||
|
Reference in New Issue
Block a user