because the internet

fun with autohotkey

stumbling through the piles of rubble that make up my drafts folder, i didn’t really see anything i thought would make for a decent november post, so i decided to just pretty much document whatever it is i’m doing at the time. not only is it very low-effort for me, but i think it might be pretty useful for anyone who finds this blag.

i really hope that self-resizes to fit in this column, because i hate doing work. anyways, the above is a screenshot demonstrating two things i got working with autohotkey: toggling both the titlebars, and transparency levels, of a window.

they are fairly basic things to do, but the thing is, the typical AHK user is so advanced that there’s little documentation on how to do something like this - you might find the core of a similar script weaved into some super-complex function that also does about fifty other things.

this is meant to be used with windows 10. if you use any windows OS up to 7, you’ll want to uncomment the line in the ‘titlebar on’ script - in win10, “0xc40000” controls the titlebar+borders, whereas “0x800000” controls the titlebar in earlier OSes. A quick thing to note is that my script will turn off both the titlebar and the window borders - the variable that turns off only the titlebar left the windows looking a little messy, with a bit of UI still visible at the top of a window.

disabling the titlebar will leave the window in an unmovable state - but an awesome companion for a setup like this is the recently-revived powertoys utility from microsoft, available from their store or via github. here i am using the “fancy zones” utility, which lets you define any combination of ‘zones’ and effectively divvy up your desktop into a bunch of smaller spaces. you can then hold shift while moving a window, and attach it to one of these spaces. after enabling an option in the menu, using winkey+[arrow] will let you move an attached window between the different spaces. for me, this means despite lacking titlebars, i could move the three terminal windows in the screenshot to any other defined zone with some keypresses, despite not having the titlebars.

anyways, without further ado, the code:

#o::  ; transparency on win+o
MouseGetPos,,, MouseWin
WinSet, Transparent, 230, ahk_id %MouseWin%

^#o::  ; " " off ctrl+win+o
MouseGetPos,,, MouseWin
WinSet, Transparent, Off, ahk_id %MouseWin%

; titlebar off win+c
; uncomment the commented line for >win10 OS
; WinSet, Style, -0x800000, A
WinSet, Style, -0xc40000, A 

; " " on ctrl+win+c
WinSet, Style, +0xC00000, A

that about wraps it up.

notes to self

some related stuff i’d like to post about:

hot soft ware

pastel available from github or cargo cargo install pastel, pastel is a wonderful tool for anyone working on any sort of theme for terminal programs. literally the only caveat is it requires a 256-color or better terminal, but i feel like this is a given - otherwise you probably wouldn’t be too interested in theming your term. i’ve used it extensively to refer to when coming up with my own colorschemes (yeah ill post about it later) - the real selling point for me was that you can use the lighten and darken commands to adjust a color until it’s juuuussst right.


xunlong has released some new boards, so there’s been some nice price cuts on the old stock. right now, the Orange Pi One Plus is a mere $19.99 plus s/h, which means you can get a 1.8Ghz(!!) H6 processor, two USB outs (one in OTG form), an HDMI out, and a gig of RAM for 25 bucks. For me at least, this combo of features has been my unicorn - impossible to find at this price. Armbian maintains a dev branch build for this board, so while you can’t grab a nice, polished official armbian release, the dev release is leaps and bounds better than the garbage that xunlong offers for software.

that about wraps it up. as usual i might try to get some more writing in before next month - as usual you should assume i won’t. over and out,