A modern, cross-platform image viewer and cropper built with Python and Tkinter. Features adaptive theming, intuitive navigation, and efficient batch cropping capabilities.
- Cross-Platform: Runs on Windows, macOS, and Linux
- Adaptive Theming: Automatically detects and adapts to system dark/light mode
- Intuitive Navigation: Keyboard shortcuts and mouse controls
- Batch Cropping: Efficiently crop multiple images with auto-advance
- Modern UI: Clean, responsive interface with high-DPI support
- Multiple Formats: Supports PNG, JPG, JPEG, GIF, BMP image formats
- Smart Saving: Automatic directory management for cropped images
- Python 3.8 or higher
- tkinter (usually included with Python)
- Pillow (PIL) for image processing
pip install Pillow>=10.0.0
python run.pygit clone https://github.com/bhupenderkaushal/croppy.git
cd croppy
pip install -r requirements.txt
python run.pypip install croppy
croppypip install Pillow
python run.py# If using system Python
pip3 install Pillow
python3 run.py
# If using Homebrew Python and tkinter issues
brew install python-tk
pip install Pillow
python run.pysudo apt-get update
sudo apt-get install python3-tk python3-pip
pip3 install Pillow
python3 run.pysudo dnf install python3-tkinter python3-pip
pip3 install Pillow
python3 run.pysudo pacman -S tk python-pip
pip install Pillow
python run.py- ๐ Button: Select a folder containing images
- โ โ Arrows: Navigate between images (or use arrow keys)
- โ๏ธ Button: Enter crop mode
- โ Button: Exit crop mode
- Escape Key: Exit fullscreen mode
- Click ๐ to select an image directory
- Navigate to desired image using โ โ buttons or arrow keys
- Click โ๏ธ to enter crop mode
- Click and drag to select the area to crop
- Confirm save when prompted
- Application auto-advances to next image
โ/โ: Previous imageโ/โ: Next imageEscape: Exit crop mode or fullscreen
Croppy is built with a modular architecture:
croppy/main.py: Main application coordinatorcroppy/theme_manager.py: System theme detection and color managementcroppy/ui_components.py: User interface setup and event handlingcroppy/image_handler.py: Image loading, display, and processingcroppy/file_manager.py: File operations and directory managementcroppy/crop_manager.py: Crop mode and selection handlingrun.py: Cross-platform startup script
Croppy automatically detects your system theme. Colors are defined in croppy/theme_manager.py and can be customized:
# Dark mode colors
'button_bg': '#2a2a2a' # Button background
'button_fg': '#ffffff' # Button text
'canvas_bg': '#1e1e1e' # Image canvas background
# ... more colorsSupported image formats:
- PNG (.png)
- JPEG (.jpg, .jpeg)
- GIF (.gif)
- BMP (.bmp)
Linux: Install tkinter package
# Ubuntu/Debian
sudo apt-get install python3-tk
# Fedora/CentOS
sudo dnf install python3-tkinter
# Arch Linux
sudo pacman -S tkInstall Pillow:
pip install Pillow>=10.0.0Croppy automatically handles DPI scaling on Windows 10+. For older systems or manual control, DPI awareness is set in run.py.
If you encounter permission issues accessing directories:
# Grant Terminal full disk access in System Preferences > Security & Privacy- For large image directories, Croppy loads images on-demand
- Crop operations use the original image resolution for quality
- Memory usage is optimized with image buffering
git clone <repository-url>
cd croppy
pip install -r requirements.txt
# Optional: Install development tools
pip install black mypy flake8 pytestThe project uses modern Python practices:
- Type hints (Python 3.8+ compatible)
- Black code formatting
- Mypy type checking
- Flake8 linting
python -m pytest tests/python -m build- Python: 3.8 or higher
- Operating System: Windows 10+, macOS 10.14+, Linux (modern distributions)
- RAM: 512MB minimum, 1GB recommended
- Storage: 50MB for application, additional space for images
- Display: Any resolution, optimized for high-DPI displays
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Built with Python and Tkinter
- Image processing powered by Pillow (PIL)
- Cross-platform compatibility testing
- Modern UI design principles
