http://msdn.microsoft.com/en-us/library/sa8ahz7h(v=vs.80).aspx有人可以向我解釋CDC :: SelectObject嗎?
//Border
CPen pen;
pen.CreatePen(PS_DASH, 20, RGB(0, 0, 0));
CPen* penOld = dc.SelectObject(&pen);
dc.Rectangle(rect);
dc.FillRect(rect, &brush);
請問這個代碼工作的?它繪製一個矩形,然後繪製一個邊框。我無法理解它。