Skip to content

Latest commit

 

History

History
56 lines (41 loc) · 1.73 KB

File metadata and controls

56 lines (41 loc) · 1.73 KB

Home

Function name : SetTextColor

Group: Font and Text - Library: gdi32


Sets the text color for the specified device context to the specified color.


Code examples:

Printing text on the main VFP window
Using FrameRgn for displaying system colors
Splash Screen for the VFP application
Using the DrawText function
Using Font and Text functions
How to put a horizontal text scrolling on the form (a news line, marquee)
How to put a vertical text scrolling on the form (a movie cast)
Printing text with the Escape function
Subclassing CommandButton control to create BackColor property
Vertical Label control
Placing On-screen Alert on top of all windows

Declaration:

COLORREF SetTextColor(
  HDC hdc,           // handle to DC
  COLORREF crColor   // text color
);  

FoxPro declaration:

DECLARE INTEGER SetTextColor IN gdi32;
	INTEGER hdc, INTEGER crColor  

Parameters:

hdc [in] Handle to the device context.

crColor [in] Specifies the color of the text.


Return value:

If the function succeeds, the return value is a color reference for the previous text color as a COLORREF value. If the function fails, the return value is CLR_INVALID (0xFFFFFFFF).