Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS General Discussion » CExtGroupBox::STYLE_ROUNDED and SetBkColor Collapse All
Subject Author Date
Michael Morrison Jun 3, 2008 - 1:33 AM

Using Prof-UIS 2.50


I have two questions:


1) How do you restore the default color gradient background once you have set a different background using CExtGroupBox::SetBkColor?


2) With a GroupBox set to STYLE_ROUNDED, the background color is still drawn as a rectangle with square edges rather than a rectangle with rounded edges.  Is there a way to make the background fill edges rounded to match the outline of the groupbox? 


Thanks.

Technical Support Jun 24, 2008 - 4:52 AM

Here is the result of your code. It is by design because we fill the entire group box client area.

Michael Morrison Jun 4, 2008 - 7:38 AM

Sure, just do this:


m_wndGroupBox.SetStyle( CExtGroupBox::STYLE_ROUNDED );

m_wndGroupBox.SetBkColor( RGB(0,255,0) );


And you should see that the filled green rectangle is square rather than rounded.


 


 

Technical Support Jun 4, 2008 - 7:32 AM

1) To restore the default background color just -1L:

m_wndGroupBox.SetBkColor( COLORREF(-1L) );
2) We cannot confirm this. Would you show the code you are using for changing the group box style? We used the following one:
m_wndGroupBox.SetStyle( CExtGroupBox::STYLE_ROUNDED );


Michael Morrison Jun 23, 2008 - 10:25 PM

Sure, just do this:




m_wndGroupBox.SetStyle( CExtGroupBox::STYLE_ROUNDED );



m_wndGroupBox.SetBkColor( RGB(0,255,0) );




And you should see that the filled green rectangle is square rather than rounded.