This Python-based application provides a user-friendly graphical interface for resizing images to multiple predefined or custom sizes. Built using PyQt6, it allows users to quickly select an image, choose output sizes, and save resized images in various formats.
- Drag-and-Drop Support: Easily add images by dragging and dropping them into the application window.
- Customizable Sizes: Add, remove, or select specific sizes for image resizing.
- Batch Resizing: Resize images into multiple sizes at once.
- Supported Formats: PNG, JPG, BMP, GIF, and SVG.
- Output Directory Management: Automatically sets the output directory and allows users to change it.
- Preview Image: Displays a preview of the selected image before resizing.
- Python 3.8+
- PyQt6 library
- Clone the repository:
git clone https://github.com/yblis/resize_icon cd resize_icon
- Install the required dependencies:
pip install PyQt6
- Run the application:
python app.py
- Select an Image:
- Click the "Select Image" button or drag and drop an image into the application.
- Choose Sizes:
- Use the checkboxes to select the desired output sizes.
- Add custom sizes by clicking the "Add Sizes" button.
- Set Output Directory:
- The output directory is set automatically based on the image's location.
- You can change it by clicking the "Select Directory" button.
- Set Base Name and Format:
- Enter a base name for the resized images.
- Choose the output format from the dropdown menu.
- Resize Images:
- Click the "Resize Images" button to start the resizing process.
- View Output:
- Once the resizing is complete, the output directory will open automatically.
image_resizer/
├── app.py # Main application script
└── README.md # Documentation
- Image Selection:
- Users can select an image either by browsing or using drag-and-drop.
- Size Management:
- Predefined sizes are displayed as checkboxes.
- Users can add custom sizes using a dialog.
- Resizing Process:
- The application resizes the image into selected sizes and saves them in the specified format.
- If an unsupported format (e.g., SVG for raster resizing) is selected, a warning is displayed.
- Error Handling:
- The application provides user-friendly error messages for issues such as unsupported formats, missing output directories, or invalid inputs.
Contributions are welcome! Feel free to open issues or submit pull requests.
This project is licensed under the MIT License. See the LICENSE
file for more details.
- PyQt6 documentation
- Open-source community for helpful resources and guidance.