Click here to Skip to main content
15,909,737 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralSending string (text or array of character) trough a socket-connection. Pin
SimCom5-Jan-05 9:22
SimCom5-Jan-05 9:22 
GeneralRe: Sending string (text or array of character) trough a socket-connection. Pin
Ravi Bhavnani5-Jan-05 10:13
professionalRavi Bhavnani5-Jan-05 10:13 
GeneralRe: Sending string (text or array of character) trough a socket-connection. Pin
SimCom5-Jan-05 23:55
SimCom5-Jan-05 23:55 
GeneralClass Confusion Pin
whitee5-Jan-05 7:57
whitee5-Jan-05 7:57 
GeneralRe: Class Confusion Pin
Gerald Schwab5-Jan-05 8:49
Gerald Schwab5-Jan-05 8:49 
GeneralDrawing rectangles, lines and arcs in directx Pin
SteQve5-Jan-05 7:51
SteQve5-Jan-05 7:51 
GeneralOpenGL question : wglUseFontBitmaps and glGenLists Pin
Maximilien5-Jan-05 4:55
Maximilien5-Jan-05 4:55 
GeneralRe: OpenGL question : wglUseFontBitmaps and glGenLists Pin
El Corazon5-Jan-05 7:03
El Corazon5-Jan-05 7:03 
GeneralRe: OpenGL question : wglUseFontBitmaps and glGenLists Pin
Maximilien5-Jan-05 7:21
Maximilien5-Jan-05 7:21 
GeneralFrom C to C++ Pointer Pin
jw815-Jan-05 4:55
jw815-Jan-05 4:55 
GeneralRe: From C to C++ Pointer Pin
David Crow5-Jan-05 5:24
David Crow5-Jan-05 5:24 
GeneralRe: From C to C++ Pointer Pin
jw815-Jan-05 5:26
jw815-Jan-05 5:26 
GeneralRe: From C to C++ Pointer Pin
David Crow5-Jan-05 5:54
David Crow5-Jan-05 5:54 
GeneralRe: From C to C++ Pointer Pin
jw815-Jan-05 15:38
jw815-Jan-05 15:38 
GeneralRe: From C to C++ Pointer Pin
Maximilien5-Jan-05 16:14
Maximilien5-Jan-05 16:14 
GeneralRe: From C to C++ Pointer Pin
jw815-Jan-05 17:16
jw815-Jan-05 17:16 
GeneralRe: From C to C++ Pointer Pin
ThatsAlok5-Jan-05 22:05
ThatsAlok5-Jan-05 22:05 
GeneralRe: From C to C++ Pointer Pin
Maximilien5-Jan-05 5:43
Maximilien5-Jan-05 5:43 
GeneralRe: How to draw static controls and check box buttons transparently ? Pin
rrrado5-Jan-05 3:41
rrrado5-Jan-05 3:41 
GeneralRe: How to draw static controls and check box buttons transparently ? Pin
YoSilver7-Jan-05 0:35
YoSilver7-Jan-05 0:35 
Then the solution is to forward the WM_ERASEBKGND message of a control to the wnd proc of the parent dialog that is responsible for drawing a gradient background. Before passing a DC handle, set the viewport origin to match the control position in the dialog.

Another problem with group boxes is correct painting of contained sibling controls. If this problem will arise, try this :

void myGroupBox::PreSubclassWindow() 
{
    ASSERT(::GetWindowLong(::GetParent(m_hWnd), GWL_STYLE) & WS_CLIPCHILDREN);
    ASSERT((::GetWindowLong(m_hWnd, GWL_STYLE) & BS_TYPEMASK) == BS_GROUPBOX);

    ModifyStyle(0, WS_CLIPSIBLINGS);
    SetWindowPos(&CWnd::wndBottom, 0,0,0,0, SWP_NOSIZE|SWP_NOMOVE);

    CButton::PreSubclassWindow();
}


Group boxes are a common headache for all programmers. The simplest solution is to avoid gradient background and make it just lighter than common COLOR_BTNFACE, 75 percent - that will do and look neat.

One always gets the deserved.

http://www.silveragesoftware.com/hffr.html
Update your source code with my tool HandyFile Find And Replace!
GeneralRe: How to draw static controls and check box buttons transparently ? Pin
rrrado11-Jan-05 4:04
rrrado11-Jan-05 4:04 
GeneralRe: How to draw static controls and check box buttons transparently ? Pin
YoSilver11-Jan-05 6:35
YoSilver11-Jan-05 6:35 
GeneralAccessing Large CMapStringToString's inside Critical Sections Pin
MJWhiteman25-Jan-05 2:56
MJWhiteman25-Jan-05 2:56 
GeneralRe: Accessing Large CMapStringToString's inside Critical Sections Pin
basementman5-Jan-05 4:38
basementman5-Jan-05 4:38 
GeneralCritical Sections Pin
MJWhiteman25-Jan-05 2:47
MJWhiteman25-Jan-05 2:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.