Add screen recording, crop, and a Cap-style result window
Recording: Ctrl+Shift+Cmd+R (or the menu) opens the same selection flow — a marquee records that region, clicking a window records it (following moves). Video is H.264 .mov at 60fps via SCStream -> AVAssetWriter with the cursor included, auto-saved to ~/Movies and revealed in Finder on stop. A red border and a floating timer/stop bar show during recording, both excluded from the video. Audio is wired behind a flag for later. The result window gains a Crop button (crop to the selection; annotations translate and stay editable) and is restyled after Cap: sliding-pill Screenshot/Text switcher, capsule buttons in Cap blue, circular icon buttons, and the content on a rounded card — light and dark. Generated with OpenCode Assisted-by: Kimi:k3
This commit is contained in:
@@ -97,9 +97,14 @@ final class OverlayView: NSView {
|
||||
}
|
||||
|
||||
// Esc hint — the only way out once clicks are consumed by the tap.
|
||||
let hint = frozenImage != nil
|
||||
? "Frozen screen · drag to select · Esc to cancel"
|
||||
: "Drag to select · hover + click a window to capture it · Esc to cancel"
|
||||
let hint: String
|
||||
if controller?.isRecordingMode == true {
|
||||
hint = "Drag to select · hover + click a window to record · Esc to cancel"
|
||||
} else if frozenImage != nil {
|
||||
hint = "Frozen screen · drag to select · Esc to cancel"
|
||||
} else {
|
||||
hint = "Drag to select · hover + click a window to capture it · Esc to cancel"
|
||||
}
|
||||
let hintAttrs: [NSAttributedString.Key: Any] = [
|
||||
.font: NSFont.monospacedSystemFont(ofSize: 12, weight: .medium),
|
||||
.foregroundColor: NSColor.white.withAlphaComponent(0.85),
|
||||
|
||||
Reference in New Issue
Block a user