CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Sep 2007
    Posts
    7

    Question How to change window brightness and transparency?

    Hi everyone,

    Can someone tell me how to change window brightness and transparency with a certain key combination, for example: alt+shift+up/down arrow?

    By this I mean: What libraries do I need to use in order to achieve this, for example: window.h and etc?

    As for the transparency is "true transparency" possible? If possible, how do I achieve this effect? What I mean by "true transparency" is that the window is transparent or not very opaque, but the text including the title bar text on the window are not very transparent or very opaque.

    Thanks.
    Last edited by cloud1; December 12th, 2009 at 04:38 AM.

  2. #2
    Join Date
    Apr 2009
    Location
    Cochin
    Posts
    83

    Re: How to change window brightness and transparency?

    Read the MSDN documentation for AlphaBlend() API for Windows.. It allows regional transparency also...


    If you need full window transparency( including non-client area like titlebar and sizebar ), you had to include extended style WS_EX_LAYERED to your window and use the SetLayeredWindowAttributes() API to adjust the alpha.. 255 means completely opaque, and 0 means completely transparent... you can adjust values between 0 and 255.
    "I studied everything but never topped. Today, toppers of the world's best universities are my employees"

    -William Henry Gates (Bill Gates)

  3. #3
    Join Date
    Nov 2009
    Posts
    18

    Re: How to change window brightness and transparency?

    If you're using .NET, Transparency is a property you can set.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured