Initial commit: Snipping Tool menu bar screenshot app

This commit is contained in:
2026-07-01 15:27:57 +02:00
commit 1c2b52fa30
25 changed files with 718 additions and 0 deletions
+25
View File
@@ -0,0 +1,25 @@
import Foundation
enum CaptureMode: String, CaseIterable {
case fullScreen
case window
case region
/// Stable id used to register/unregister the matching global hot key.
var hotKeyID: UInt32 {
switch self {
case .fullScreen: return 1
case .window: return 2
case .region: return 3
}
}
/// Extra arguments passed to /usr/sbin/screencapture for this mode.
var screencaptureArguments: [String] {
switch self {
case .fullScreen: return []
case .window: return ["-i", "-W"]
case .region: return ["-i", "-s"]
}
}
}