Repository navigation
Keysharp 0.0.0.16
New
Ks.Image class — capture, load or create an image, then draw on it, transform it, search it and read/write its pixels before saving it. Replaces ImageCapture(). Full on Windows, partial on Linux (X11).
Ks.Overlay class — always-on-top, click-through canvas using the same drawing primitives as Image. Now backs Highlight(), and ToolTip() on Linux/macOS.
Ks.WinEvent — cross-platform window event subscriptions: Active, Exist, NotExist, Move, Minimize, Restore, TitleChange, plus Pause/Stop. Import with #import "Ks" { WinEvent }.
OCR library — new OCR.ks with a pluggable engine (Tesseract by default), built on Image.
Demos — ClipboardHistory, InputHUD, OCRSnip, Shell, WindowGrab, WindowTiler.
Also: Ks.A_ThreadId and Exit(ThreadId); Ks.MonitorGetScale() and Ks.MonitorFromPoint() alongside fully cross-platform monitor functions; InputHook.OnMouseDown/OnMouseUp/OnMouseMove; Gui +ClickThrough and +AutoScroll; an ImageSearch *Dir scan-direction option.
Platform
Linux — SharpHook and the legacy X11 hook/sender logic are removed. All input now goes through the keysharp-inputd daemon (evdev + uinput), reworked for multi-user handling, per-script permissions, unicode sending and mouse buttons.
Wayland — overlays, clipboard and window manipulation via KWin scripting and Keysharp shell extensions for GNOME (including v48+) and Cinnamon.
macOS — hook and sender logic revamped on CGEventTap; the key sender now works. Binaries are signed, and releases ship DMG/PKG with SHA256 checksums.
Internals — the old PlatformManager/WindowManager hierarchies were replaced by a service-oriented Platform layer with shared failure/retry recovery.
Breaking changes
ImageCapture()is replaced by theImageclass- Linux input requires
keysharp-inputd— the SharpHook/X11 fallback is gone A_ScaledScreenDPIis renamed toA_ScreenScaleA_OSTypenow returnsWINDOWS/OSX/LINUXA_LineFilein the main file resolves toA_FullScriptPath#importinside a function or class body binds to that scope instead of module-wide, and unknown imports throw- Reserved words can no longer be used as variable names
- Invalid Gui options now throw
Fixes
Release-mode stack traces for C# exceptions, OnExit teardown, scripts exiting when the last Eto window closed, thread priority handling, DLL path normalization, Windows overlay flicker and emoji tray icons, and a long tail of Linux/macOS window and input bugs. Parser fixes for #include, static variables, derefs and remap syntax. Performance: RegEx pattern caching, font caching, cheaper per-call thread setup and faster keyboard-layout queries.