Click here to Skip to main content
15,924,039 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionTree Draw Pin
polopo21-Aug-08 19:55
polopo21-Aug-08 19:55 
AnswerRe: Tree Draw Pin
Hamid_RT21-Aug-08 20:00
Hamid_RT21-Aug-08 20:00 
GeneralRe: Tree Draw Pin
polopo21-Aug-08 20:01
polopo21-Aug-08 20:01 
GeneralRe: Tree Draw Pin
Hamid_RT21-Aug-08 20:10
Hamid_RT21-Aug-08 20:10 
GeneralRe: Tree Draw Pin
polopo21-Aug-08 22:21
polopo21-Aug-08 22:21 
GeneralRe: Tree Draw Pin
Hamid_RT21-Aug-08 23:38
Hamid_RT21-Aug-08 23:38 
QuestionHow to set the border width of dialog box Pin
Ganesh_T21-Aug-08 19:45
Ganesh_T21-Aug-08 19:45 
AnswerRe: How to set the border width of dialog box Pin
Nibu babu thomas21-Aug-08 20:52
Nibu babu thomas21-Aug-08 20:52 
You need to increase non client area size for this purpose handle WM_NCCALCSIZE, add a message map entry for ON_WM_NCCALCSIZE()...

A sample implementation looks likewise...


void CDialogTestDlg::OnNcCalcSize(BOOL bCalcValidRects, NCCALCSIZE_PARAMS* lpncsp)
{
   UNREFERENCED_PARAMETER( bCalcValidRects ); // Read the docs on this variable

   // Increase border width by 4!
   lpncsp->rgrc->top  += 4;
   lpncsp->rgrc->left += 4;
   lpncsp->rgrc->bottom -= 4;
   lpncsp->rgrc->right -= 4;
   CWnd::OnNcCalcSize( bCalcValidRects, lpncsp );
}


Also note that you may need to handle WM_NCPAINT to fill out increased region.


Nibu babu thomas
Microsoft MVP for VC++


Code must be written to be read, not by the compiler, but by another human being.

Programming Blog: http://nibuthomas.wordpress.com

QuestionHow to read contents of a .txt file line by line Pin
kapardhi21-Aug-08 19:25
kapardhi21-Aug-08 19:25 
AnswerRe: How to read contents of a .txt file line by line Pin
Naveen21-Aug-08 19:28
Naveen21-Aug-08 19:28 
AnswerRe: How to read contents of a .txt file line by line Pin
_AnsHUMAN_ 21-Aug-08 19:29
_AnsHUMAN_ 21-Aug-08 19:29 
AnswerRe: How to read contents of a .txt file line by line Pin
Hamid_RT21-Aug-08 19:56
Hamid_RT21-Aug-08 19:56 
QuestionVC++ MFC Pin
Selvan.S21-Aug-08 19:23
Selvan.S21-Aug-08 19:23 
AnswerRe: VC++ MFC Pin
nisha0000021-Aug-08 19:26
nisha0000021-Aug-08 19:26 
General[Message Deleted] Pin
Madan Chauhan21-Aug-08 20:15
Madan Chauhan21-Aug-08 20:15 
GeneralRe: VC++ MFC Pin
Hamid_RT21-Aug-08 20:22
Hamid_RT21-Aug-08 20:22 
AnswerRe: VC++ MFC Pin
Hamid_RT21-Aug-08 19:55
Hamid_RT21-Aug-08 19:55 
AnswerRe: VC++ MFC Pin
Jijo.Raj21-Aug-08 20:36
Jijo.Raj21-Aug-08 20:36 
QuestionLPARAM problem Pin
Dhiraj kumar Saini21-Aug-08 18:50
Dhiraj kumar Saini21-Aug-08 18:50 
AnswerRe: LPARAM problem Pin
Joe Woodbury21-Aug-08 18:57
professionalJoe Woodbury21-Aug-08 18:57 
GeneralRe: LPARAM problem Pin
Dhiraj kumar Saini21-Aug-08 19:02
Dhiraj kumar Saini21-Aug-08 19:02 
GeneralRe: LPARAM problem Pin
Joe Woodbury21-Aug-08 19:46
professionalJoe Woodbury21-Aug-08 19:46 
Questioncall OnCancel of Dialog from a thread in the dialog Pin
ptr_Electron21-Aug-08 18:47
ptr_Electron21-Aug-08 18:47 
AnswerRe: call OnCancel of Dialog from a thread in the dialog Pin
Jijo.Raj21-Aug-08 19:41
Jijo.Raj21-Aug-08 19:41 
QuestionHow do I edit a combo box's list-box item in-place ? Pin
SherTeks21-Aug-08 18:12
SherTeks21-Aug-08 18:12 

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.