hammerspoon2-docs
    Preparing search index...

    Function create

    • Create a new canvas Named create() rather than v1's new() -- new cannot be used as a JavaScriptCore-exported method name (it collides with the JS new operator keyword at the bridging layer), and this codebase's conventions additionally forbid method names starting with new/alloc/copy (an ARC/ObjC hazard).

      Parameters

      • rect: object

        A {x, y, w, h} dictionary describing the canvas window's frame

      Returns HSCanvas

      A new HSCanvas, not yet shown