Click here to Skip to main content
Rate this: bad
Please Sign up or sign in to vote.
See more: C++
Hey Friends
Any idea of how i can draw a text using CDC with Transparency / Opacity ?
Something like Watermarking[^] in MFC ?
On Windows there is option of making Windows Alpha Blend / Transparent using something like
static PSLWA pSetLayeredWindowAttributes = NULL;
static BOOL initialized = FALSE;

BOOL MakeWindowTransparent(HWND hWnd, unsigned char factor)
   /* First, see if we can get the API call we need. If we've tried
    * once, we don't need to try again. */
   if (!initialized)
      HMODULE hDLL = LoadLibrary ("user32");
      pSetLayeredWindowAttributes = 
         (PSLWA) GetProcAddress(hDLL, "SetLayeredWindowAttributes");
      initialized = TRUE;
   /* ... elided ... */
Is there any related way for Text ?

Posted 17-Feb-13 10:14am

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Perhaps this will help you
C++ GDI+ drawing text on a transparent layered window[^]

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Advertise | Privacy | Mobile
Web04 | 2.8.150302.1 | Last Updated 17 Feb 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100