[WPPA+ dbg msg: Photo 0 does not exist in call to wppa_get_picture_html(). Type = From : wppa-picture.php line: 44 in function wppa_get_picture_html - wppa_initialize_javascript - apply_filters - do_action]

Poojan (Wagh) Blog

Requests for comment

Archive for the ‘AutoHotkey’ tag

Autohotkey transparency script

with 13 comments

I use WikidPad at work (and at home) to keep logs/notes on tasks that I’m doing (or want to do). One nice feature of WikidPad is that it has an “always on top” setting which keeps the WikidPad window on top while another window (behind it) is active.

I use this feature with my VNC session (most of my work is on Linux) so that I can copy/paste results and snippets. Unfortunately, a lot of time the result itself (due to its placement within the VNC session) is right behind the WikidPad window. It would be nice to have WikidPad be transparent.

Turns out, AutoHotkey already has this feature. The following script does the trick:

    DetectHiddenWindows, on
    WinGet, curtrans, Transparent, A
    if ! curtrans
        curtrans = 255
    newtrans := curtrans - 64
    if newtrans > 0
        WinSet, Transparent, %newtrans%, A

        WinSet, Transparent, 255, A
        WinSet, Transparent, OFF, A

    DetectHiddenWindows, on
    WinSet, TransColor, Black 128, A

    WinSet, Transparent, 255, A
    WinSet, Transparent, OFF, A

    #g::  ; Press Win+G to show the current settings of the window under the mouse.
    MouseGetPos,,, MouseWin
    WinGet, Transparent, Transparent, ahk_id %MouseWin%
    WinGet, TransColor, TransColor, ahk_id %MouseWin%
    ToolTip Translucency:`t%Transparent%`nTransColor:`t%TransColor%

Key codes:

<Win>+T: Increments transparency by 25% (with wrap-around)
<Win>+W: Set black color to be 50% transparent (also does click-through)
<Win>+O: Reset transparency settings

Here’s a screenshot of a partially transparent WikidPad hovering over a full-screen VNC session; Ion3 is my window manager:

Transparency example with WikidPad over VNC

Written by PoojanWagh

August 27th, 2008 at 11:49 pm