[solved]wrong bg color in disabled CXTPControlEdit |
Post Reply |
Author | ||
JoseAngel
Groupie Joined: 21 March 2006 Location: Spain Status: Offline Points: 35 |
Post Options
Thanks(1)
Posted: 28 March 2016 at 3:37pm |
|
CXTPControlEdit is actually a RichEdit control. The background of the RichEdit for the selected theme is controlled in CXTPControlEditCtrl::UpdateCharFormat() sending to it a EM_SETBKGNDCOLOR message with the correspondent background color. The problem is that when the RichEdit control is disabled, it doesn't use the specified color and it always use COLOR_BTNFACE as background color. I purpose to change the CXTPControlEdit::OnEnabledChanged() from void CXTPControlEdit::OnEnabledChanged() { if (m_pEdit && m_pEdit->GetSafeHwnd()) { m_pEdit->EnableWindow(GetEnabled()); m_pEdit->UpdateCharFormat(); } } to void CXTPControlEdit::OnEnabledChanged() { if (m_pEdit && m_pEdit->GetSafeHwnd()) { m_pEdit->SetReadOnly(!GetEnabled()); m_pEdit->UpdateCharFormat(); } } and now the background color will be the correct one when the toolbar is disabled.
|
||
olebed
Admin Group Joined: 01 July 2014 Location: Ukraine Status: Offline Points: 841 |
Post Options
Thanks(0)
|
|
Hello,
We solved this issue in similar way
also in theme Office2016****Black.ini text color is very close to background.
Regards, Oleksandr Lebed |
||
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |