![]() If you're not familiar with the Lua C API, I personally found _Programming_In_Lua_, 3rd Edition very helpful - it's lua 5.2 based, and we're at 5.3, but aside from there now being a distinction between numbers (floats) and integers, I've not found any changes necessary in the C side of my code. ![]() While you can make additions to the Hammerspoon source itself and compile a development copy for testing, I usually find it easier to write things as an external module first - quicker compiles so shorter turn around time, and determining where things belong if/when they are moved into the core application can sometimes be challenging> Where lots of rapid clicks are needed in a short period of time, this program does it automatically, without needing an external stimulus. I can't claim many of them are great code - I've cleaned up my style a lot in the last year or so - but they should (I hope!) mostly still work. Auto-Clicker is a program that simulates clicking and is designed to produce extremely fast clicks, that are needed to play a certain type of games. The Wiki (also available from the github page) may have some links to third party extensions and samples as well - it's been a while since I've checked it out, but I know I listed some external modules I've written there in the past. Probably the easiest way to start is to take a look at the code at, especially the extensions folder (to be honest, except for very specific things, I mostly ignore the rest of the code myself) and read through the Contributing.md file. We haven't had any Swift based module submissions yet, so I don't know what that might entail or if we could even support it at present, but it shouldn't be too hard to convert into Objective-C, if you want to take a crack at it. but we don't use CGWindowListCopyWindowInfo to get that list, so it would be interesting to see. Our existing method of getting all windows doesn't pick up on the Dock having *any* windows when Mission Control is active - I've already checked. The Swift code in the second link looks promising, but it's basically looking to see if the Dock owns a window with the Y component of it's frame set to -1 - I don't know if that's a safe assumption for future OS X updates or versions, since I don't find it referenced anywhere else (though I admit my search was cursory). Sometimes you need to automate your automation tools, and Hammerspoon is automatable in several ways. Keep a history of the clipboard, only for text. ![]() Adds a hotkey to reload the hammerspoon configuration, and a pathwatcher to automatically reload on changes. Generate simple or strong passwords and copy them to clipboard. Looking through the sites you link and doing a little digging on my own, this is a surprisingly difficult thing to do reliably. Autoclicker tool, configurable with clicks per seconds. ![]()
0 Comments
Leave a Reply. |