Click here to Skip to main content
15,899,026 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Remove Features/components from Windows 7 Pin
Aabid23-Sep-10 1:04
Aabid23-Sep-10 1:04 
QuestionView Pin
john563222-Sep-10 21:52
john563222-Sep-10 21:52 
AnswerRe: View [modified] Pin
mesajflaviu22-Sep-10 22:15
mesajflaviu22-Sep-10 22:15 
QuestionDrawing Pin
Benjamin Bruno22-Sep-10 7:29
Benjamin Bruno22-Sep-10 7:29 
QuestionRe: Drawing Pin
David Crow22-Sep-10 8:06
David Crow22-Sep-10 8:06 
AnswerRe: Drawing Pin
sharp prospector23-Sep-10 4:14
sharp prospector23-Sep-10 4:14 
QuestionCListCtrl Border Pin
john563222-Sep-10 6:50
john563222-Sep-10 6:50 
AnswerRe: CListCtrl Border Pin
Maximilien22-Sep-10 8:46
Maximilien22-Sep-10 8:46 
You need to override the OnNcPaint, not the OnPaint.

And don't forget to call "Default();" to draw the interior
for example (done for a listbox derived class, but you should be able to see how it workd...
void MyListBox::OnNcPaint()
{
// draw the inside.
Default();

// draw over the border.
CRect rc;
GetWindowRect(rc);

CDC *pDC = GetParent()->GetDC();
GetParent()->ScreenToClient( rc );
// do the drawing ...
pDC->FrameRect( rc , brush );
rc.DeflateRect( 1, 1, 1, 1 );
pDC->FrameRect( rc,brush );

}
Watched code never compiles.

GeneralRe: CListCtrl Border Pin
john563222-Sep-10 22:42
john563222-Sep-10 22:42 
AnswerRe: CListCtrl Border Pin
Rolf Kristensen23-Sep-10 0:49
Rolf Kristensen23-Sep-10 0:49 
GeneralRe: CListCtrl Border Pin
john563223-Sep-10 4:17
john563223-Sep-10 4:17 
QuestionReason for UAC prompt , porting for Win7 Pin
Moak22-Sep-10 6:14
Moak22-Sep-10 6:14 
AnswerRe: Reason for UAC prompt , porting for Win7 Pin
Eugen Podsypalnikov22-Sep-10 6:33
Eugen Podsypalnikov22-Sep-10 6:33 
GeneralRe: Reason for UAC prompt , porting for Win7 Pin
Moak22-Sep-10 6:38
Moak22-Sep-10 6:38 
GeneralRe: Reason for UAC prompt , porting for Win7 Pin
Eugen Podsypalnikov22-Sep-10 6:57
Eugen Podsypalnikov22-Sep-10 6:57 
GeneralRe: Reason for UAC prompt , porting for Win7 Pin
Moak23-Sep-10 5:49
Moak23-Sep-10 5:49 
AnswerRe: Reason for UAC prompt , porting for Win7 Pin
krmed22-Sep-10 7:05
krmed22-Sep-10 7:05 
GeneralRe: Reason for UAC prompt , porting for Win7 Pin
Moak22-Sep-10 12:58
Moak22-Sep-10 12:58 
QuestionCreate a new menu in the MDI appliaction [modified] Pin
VulcanYang22-Sep-10 0:14
VulcanYang22-Sep-10 0:14 
AnswerRe: Create a new menu in the MDI appliaction Pin
Sauro Viti22-Sep-10 0:19
professionalSauro Viti22-Sep-10 0:19 
AnswerRe: Create a new menu in the MDI appliaction Pin
tayyebe5-Oct-10 1:31
tayyebe5-Oct-10 1:31 
GeneralRe: Create a new menu in the MDI appliaction Pin
VulcanYang5-Oct-10 3:02
VulcanYang5-Oct-10 3:02 
QuestionTime Format Pin
john563222-Sep-10 0:14
john563222-Sep-10 0:14 
AnswerRe: Time Format Pin
Shivanand Gupta22-Sep-10 0:36
Shivanand Gupta22-Sep-10 0:36 
AnswerRe: Time Format Pin
Richard MacCutchan22-Sep-10 1:44
mveRichard MacCutchan22-Sep-10 1:44 

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.