diff --git a/markups/concept.md b/markups/concept.md new file mode 100644 index 0000000..bddb358 --- /dev/null +++ b/markups/concept.md @@ -0,0 +1,40 @@ +# WindPix - Screenshot Integration for Windsurf + +## Overview +WindPix is a macOS utility that streamlines the process of sharing screenshots within the Windsurf application. It automates the workflow of capturing, copying, and sending screenshots to the LLM chat interface. + +## Core Functionality +1. **Screenshot Capture** + - Triggered by global hotkey (⌘P) + - Supports both full screen and area selection + - Screenshot control panel for accept/redo/cancel + +2. **Windsurf Integration** + - Optional automatic chat window focus + - Automatic clipboard management + - Automatic screenshot submission + +## Technical Implementation +1. **Screenshot Mechanism** + - Uses native macOS screenshot capabilities + - Supports area selection and full screen + - Built-in screenshot preview and control + +2. **Automation Flow** + - Configurable focus chat option + - Automatic Windsurf launch + - Auto-close with Windsurf option + +## User Experience +- System tray menu for easy access +- Configurable settings via menu +- Visual feedback through control panel +- How-to instructions built in + +## Current Features +- Global hotkey (⌘P) +- Area selection toggle +- Focus chat toggle +- Auto-close with Windsurf toggle +- Built-in instructions +- System tray controls diff --git a/markups/distribution.md b/markups/distribution.md new file mode 100644 index 0000000..4858c29 --- /dev/null +++ b/markups/distribution.md @@ -0,0 +1,81 @@ +# Distributing WindPix + +To distribute WindPix to other users, follow these steps: + +## For Developers (Creating the Distribution) + +1. Build the release version: + ```bash + cd WindPixMVP + swift build -c release + ``` + +2. Create an App Bundle: + ```bash + # Create the app bundle structure + mkdir -p WindPix.app/Contents/MacOS + mkdir -p WindPix.app/Contents/Resources + + # Copy the built executable + cp .build/release/WindPixMVP WindPix.app/Contents/MacOS/WindPix + + # Copy instructions.md to Resources + cp ../instructions.md WindPix.app/Contents/Resources/ + ``` + +3. Create Info.plist: + Create a file at `WindPix.app/Contents/Info.plist` with the following content: + ```xml + + + + + CFBundleExecutable + WindPix + CFBundleIdentifier + com.hugo.windpix + CFBundleName + WindPix + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + LSMinimumSystemVersion + 10.15 + LSUIElement + + + + ``` + +4. Create a ZIP archive: + ```bash + zip -r WindPix.zip WindPix.app + ``` + +## For Users (Installing the App) + +1. Download the WindPix.zip file +2. Extract the ZIP file +3. Move WindPix.app to your Applications folder +4. When first launching the app: + - Right-click on WindPix.app and select "Open" + - Click "Open" in the security dialog that appears + - Grant the necessary permissions when prompted: + * Screen Recording (for taking screenshots) + * Accessibility (for keyboard shortcuts) + +## Requirements + +- macOS 10.15 or later +- Windsurf IDE installed + +## Notes + +- The app is currently unsigned, so users will need to explicitly allow it to run +- The app requires Windsurf IDE to be running +- Make sure to grant all requested permissions for full functionality + +## Support + +For support or questions, contact: bartwisch666@gmail.com diff --git a/markups/featurelist.md b/markups/featurelist.md new file mode 100644 index 0000000..3f248ca --- /dev/null +++ b/markups/featurelist.md @@ -0,0 +1 @@ +- always automatically focus on cascade chat window \ No newline at end of file diff --git a/markups/icon_instructions.md b/markups/icon_instructions.md new file mode 100644 index 0000000..f6c9f0c --- /dev/null +++ b/markups/icon_instructions.md @@ -0,0 +1,52 @@ +# Creating an App Icon for WindPix + +To create a proper app icon, you'll need to create images in the following sizes and save them in the `AppIcon.iconset` folder: + +1. Required icon files and sizes: + - icon_16x16.png (16×16) + - icon_16x16@2x.png (32×32) + - icon_32x32.png (32×32) + - icon_32x32@2x.png (64×64) + - icon_128x128.png (128×128) + - icon_128x128@2x.png (256×256) + - icon_256x256.png (256×256) + - icon_256x256@2x.png (512×512) + - icon_512x512.png (512×512) + - icon_512x512@2x.png (1024×1024) + +2. After creating these images, convert them to .icns: + ```bash + cd WindPixMVP + iconutil -c icns AppIcon.iconset + ``` + +3. Add to Info.plist: + The following entry will be added to Info.plist: + ```xml + CFBundleIconFile + AppIcon + ``` + +## Icon Design Guidelines + +1. Keep it simple and recognizable even at small sizes +2. Use the macOS icon grid for proper proportions +3. Consider both light and dark backgrounds +4. Make sure the icon looks good in both color and monochrome + +## Tools for Creating Icons + +You can use these tools to create your icon: +- Adobe Photoshop +- Sketch +- Figma +- Pixelmator Pro +- Icon Set Creator (Mac App Store) + +## Testing the Icon + +After creating the icon: +1. Build the app bundle +2. Copy AppIcon.icns to WindPix.app/Contents/Resources/ +3. Update Info.plist +4. The icon should appear in Finder and the Dock diff --git a/markups/idea.md b/markups/idea.md new file mode 100644 index 0000000..73e7f95 --- /dev/null +++ b/markups/idea.md @@ -0,0 +1,17 @@ +# Initial Idea vs Current Implementation + +## Original Idea +A program for Mac that creates a screenshot with a shortcut. +The screenshot is copied to the clipboard. +Then the key combination "cmd + l" is pressed to focus the chat window in the "windsurf" program. +After a 1-second delay, the image from the clipboard is pasted into the chat window using "cmd + v". +After another 1-second delay, the ENTER key is pressed to forward the image to the LLM. + +## Current Implementation +The idea has evolved into a more sophisticated application with: +- System tray presence with wind icon +- Configurable screenshot behavior (area/full screen) +- Optional chat window focus +- Screenshot preview and control panel +- Automatic Windsurf launch +- Auto-close capability diff --git a/markups/instructions.md b/markups/instructions.md new file mode 100644 index 0000000..056562c --- /dev/null +++ b/markups/instructions.md @@ -0,0 +1,39 @@ +# Welcome to WindPix - Your Screenshot Companion for Windsurf + +WindPix makes it easy to include screenshots in your Windsurf workflow, helping you communicate more effectively with the LLM. + +## Getting Started +1. Launch WindPix - you'll see a wind icon in your system tray +2. WindPix will automatically launch Windsurf if it's not running +3. Click the wind icon to access settings and options + +## Taking Screenshots +1. Press ⌘P to initiate a screenshot +2. If area selection is enabled, select the area you want to capture +3. In the control panel that appears: + - Click "Accept" to send the screenshot to Windsurf + - Click "Redo" to take another screenshot + - Click "Cancel" to abort + +## Configuration Options +Access these by clicking the wind icon: +- **Use Area Selection**: Toggle between area selection and full screen +- **Focus Chat Before Paste**: Automatically focus the chat window +- **Auto-close with Windsurf**: Close WindPix when Windsurf closes + +## Required Permissions +WindPix needs these permissions to function: +- Screen Recording (for screenshots) +- Accessibility (for keyboard simulation) +- Input Monitoring (for hotkey) + +## Tips +- You can take multiple screenshots for one prompt +- Use area selection for precise captures +- Keep Windsurf's chat window visible for best results + +## Support +For issues or suggestions, visit: +https://github.com/bartwisch/windpix/issues + +Created by Hugo (bartwisch666@gmail.com) diff --git a/markups/mvp.md b/markups/mvp.md new file mode 100644 index 0000000..8d5f5b4 --- /dev/null +++ b/markups/mvp.md @@ -0,0 +1,58 @@ +# WindPix MVP Status + +## Implemented Features +1. Global hotkey (⌘P) +2. Area selection and full screen modes +3. Screenshot control panel + - Accept/Redo/Cancel options +4. System tray menu + - Configuration options + - How-to instructions +5. Automatic Windsurf integration + - Auto-launch + - Optional chat focus + - Auto-close capability + +## Current Tech Stack +- Swift command-line tool with AppKit UI +- Global hotkey using Carbon API +- Screenshot capture using native APIs +- System tray integration +- Window management + +## Implemented Functionality + +1. **Core Application** +```swift +// AppDelegate manages: +- System tray icon and menu +- Windsurf monitoring +- Configuration options +- Instructions window +``` + +2. **Permissions** +✓ Screen Recording +✓ Accessibility +✓ Input Monitoring + +## Current Status +- MVP is fully functional +- Core features implemented +- Basic UI through system tray +- Error handling in place +- Configuration options available + +## Completed MVP Goals +✓ Screenshot capture with hotkey +✓ Preview and control panel +✓ System tray presence +✓ Basic settings +✓ Windsurf integration + +## Future Enhancements +- Custom keyboard shortcuts +- Enhanced error notifications +- Installation package +- Auto-updates +- Multiple monitor improvements diff --git a/markups/techstack.md b/markups/techstack.md new file mode 100644 index 0000000..e2379d4 --- /dev/null +++ b/markups/techstack.md @@ -0,0 +1,85 @@ +# WindPix Technical Stack + +## Core Technologies + +### Programming Language +- **Swift 5.9+** + - Native macOS development + - System API integration + - Clean and modern syntax + - Type-safe operations + +### Frameworks Used +- **AppKit** + - System tray implementation + - Window and panel management + - Menu creation and handling + - Basic UI components + +- **Foundation** + - Core functionality + - File operations + - Timer management + - Error handling + +- **Carbon** + - Global hotkey registration + - Keyboard event handling + +### System Integration +- **Screenshot Capabilities** + - Native screenshot commands + - Area selection support + - Clipboard management + +- **Window Management** + - Windsurf window detection + - Focus management + - Event simulation + +### Development Tools +- **Xcode** + - Development environment + - Debugging tools + - Performance monitoring + +### Distribution +- **GitHub** + - Version control + - Issue tracking + - Release management + +### Current Architecture +- **AppDelegate** + - Application lifecycle + - Menu management + - Configuration handling + +- **HotkeyManager** + - Keyboard event handling + - Screenshot automation + - Window management + +- **ScreenshotControlPanel** + - User interface for preview + - Action handling + - Visual feedback + +## System Requirements +- macOS 13.0 (Ventura) or newer +- 20MB disk space +- Minimal RAM usage + +## Development Environment Setup +1. Install Xcode from Mac App Store +2. Install command line tools: + ```bash + xcode-select --install + ``` +3. Clone repository and open in Xcode + +## Testing Framework +- **XCTest** + - Unit testing + - UI testing + - Performance testing diff --git a/markups/todos.md b/markups/todos.md new file mode 100644 index 0000000..3deb2fc --- /dev/null +++ b/markups/todos.md @@ -0,0 +1,56 @@ +# WindPix Development Tasks + +## Phase 1: Project Setup +- [x] Create new Xcode project +- [x] Set up Git repository +- [x] Configure SwiftLint +- [x] Create initial README.md +- [x] Set up basic app structure with AppKit + +## Phase 2: Core Screenshot Functionality +- [x] Implement screenshot capture using NSScreen +- [x] Set up pasteboard (clipboard) management +- [x] Create status bar menu item +- [x] Implement global hotkey using Carbon Hot Key API +- [x] Add basic error handling and logging + +## Phase 3: Windsurf Integration +- [x] Implement window focus using Accessibility API +- [x] Create pasteboard paste functionality +- [x] Add keyboard event simulation +- [x] Implement configurable delays between actions +- [x] Add error handling for Windsurf integration + +## Phase 4: UI Development +- [x] Design status bar menu +- [x] Create preferences window + - [x] Hotkey configuration + - [x] Delay settings + - [x] General preferences +- [x] Add notification handling +- [x] Implement dark mode support + +## Current Development Tasks +- [ ] Enhance error notifications +- [ ] Improve multiple monitor support +- [ ] Add custom keyboard shortcuts +- [ ] Create installer package + +## Future Enhancements +- [ ] Auto-update system +- [ ] More configuration options +- [ ] Enhanced preview capabilities +- [ ] Performance optimizations + +## Documentation +- [x] Basic user documentation +- [x] Installation instructions +- [ ] Advanced usage guide +- [ ] Troubleshooting guide + +## Distribution +- [x] GitHub repository setup +- [x] Basic release +- [ ] Code signing +- [ ] Notarization +- [ ] DMG installer