{"id":52,"date":"2008-08-27T23:49:32","date_gmt":"2008-08-28T04:49:32","guid":{"rendered":"https:\/\/www.6waghs.net\/poojanblog\/?p=28"},"modified":"2011-03-05T13:35:48","modified_gmt":"2011-03-05T18:35:48","slug":"autohotkey-transparency-script","status":"publish","type":"post","link":"https:\/\/poojanblog.com\/blog\/2008\/08\/autohotkey-transparency-script\/","title":{"rendered":"Autohotkey transparency script"},"content":{"rendered":"<p>I use <a title=\"WikidPad home page (Google Group)\" href=\"http:\/\/groups.google.com\/group\/wikidpad\/web\/home\" target=\"_blank\">WikidPad<\/a> at work (and at home) to keep logs\/notes on tasks that I&#8217;m doing (or want to do). One nice feature of WikidPad is that it has an &#8220;always on top&#8221; setting which keeps the WikidPad window on top while another window (behind it) is active.<\/p>\n<p>I use this feature with my <a title=\"Real VNC: original makers of virtual network computing (VNC) Linux remote-desktop software\" href=\"http:\/\/www.realvnc.com\" target=\"_blank\">VNC<\/a> 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.<\/p>\n<p>Turns out, <a title=\"AutoHotkey: swiss-army knife of Windows desktop tweaking &amp; hacking\" href=\"http:\/\/www.autohotkey.com\/\" target=\"_blank\">AutoHotkey<\/a> already has this feature. The following script does the trick:<\/p>\n<pre>    #T::\r\n    DetectHiddenWindows, on\r\n    WinGet, curtrans, Transparent, A\r\n    if ! curtrans\r\n        curtrans = 255\r\n    newtrans := curtrans - 64\r\n    if newtrans &gt; 0\r\n    {\r\n        WinSet, Transparent, %newtrans%, A\r\n\r\n    }\r\n    else\r\n    {\r\n        WinSet, Transparent, 255, A\r\n        WinSet, Transparent, OFF, A\r\n    }\r\n    return\r\n\r\n    #w::\r\n    DetectHiddenWindows, on\r\n    WinSet, TransColor, Black 128, A\r\n    return\r\n\r\n    #o::\r\n    WinSet, Transparent, 255, A\r\n    WinSet, Transparent, OFF, A\r\n    return\r\n\r\n    #g::  ; Press Win+G to show the current settings of the window under the mouse.\r\n    MouseGetPos,,, MouseWin\r\n    WinGet, Transparent, Transparent, ahk_id %MouseWin%\r\n    WinGet, TransColor, TransColor, ahk_id %MouseWin%\r\n    ToolTip Translucency:`t%Transparent%`nTransColor:`t%TransColor%\r\n    return<\/pre>\n<p>Key codes:<\/p>\n<pre>&lt;Win&gt;+T: Increments transparency by 25% (with wrap-around)\r\n&lt;Win&gt;+W: Set black color to be 50% transparent (also does click-through)\r\n&lt;Win&gt;+O: Reset transparency settings<\/pre>\n<p>Here&#8217;s a screenshot of a partially transparent WikidPad hovering over a full-screen VNC session; Ion3 is my window manager:<\/p>\n<p><a href=\"http:\/\/poojanblog.com\/poojanblog\/wp-content\/uploads\/2008\/08\/windowstransparencyscript.png\"><img loading=\"lazy\" decoding=\"async\" style=\"display: block; float: none; margin-left: auto; margin-right: auto; border: 0px;\" title=\"Transparency example with WikidPad over VNC\" src=\"http:\/\/poojanblog.com\/poojanblog\/wp-content\/uploads\/2008\/08\/windowstransparencyscript.png\" border=\"0\" alt=\"Transparency example with WikidPad over VNC\" width=\"248\" height=\"188\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I use WikidPad at work (and at home) to keep logs\/notes on tasks that I&#8217;m doing (or want to do). One nice feature of WikidPad is that it has an &#8220;always on top&#8221; setting which keeps the WikidPad window on top while another window (behind it) is active. I use this feature with my VNC [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[4],"tags":[11,220,74,77,78,79,80],"class_list":["post-52","post","type-post","status-publish","format-standard","hentry","category-desktop-computing","tag-autohotkey","tag-desktop-computing","tag-transparency","tag-vnc","tag-wikidpad","tag-windows-vista","tag-windows-xp"],"jetpack_featured_media_url":"","jetpack_likes_enabled":true,"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/posts\/52","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/comments?post=52"}],"version-history":[{"count":4,"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/posts\/52\/revisions"}],"predecessor-version":[{"id":743,"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/posts\/52\/revisions\/743"}],"wp:attachment":[{"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/media?parent=52"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/categories?post=52"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/poojanblog.com\/blog\/wp-json\/wp\/v2\/tags?post=52"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}