DrawFocusRect

  BOOL DrawFocusRect(hdc, lprc)    
  HDC hdc; /* handle of device context */
  CONST RECT *lprc; /* address of structure with rectangle */

This function draws a rectangle in the style used to indicate focus.

Parameters

hdc

Identifies the device context.

lprc

Points to a RECT structure that specifies the coordinates of the rectangle to be drawn.

Return Value

FALSE on error, TRUE on success

Comments

Since this is an XOR function, calling this function a second time with the same rectangle removes the rectangle from the display.

The rectangle drawn by this function cannot be scrolled. To scroll an area containing a rectangle drawn by this function, call DrawFocusRect to remove the rectangle from the display, scroll the area, and then call DrawFocusRect to draw the rectangle in the new position.