Features
- Product Catalog: Pre-loaded items (fruits, dairy, meat, etc.) with automatic price fetching.
- Dynamic Calculations: Automatically calculates sub-totals, discounts, and taxes as you type.
- Live Preview: An interactive table (Treeview) that displays all added items and financial breakdowns.
- Management Tools: Easily delete the last entry or clear the entire invoice.
- Export Function: Save your final invoice as a structured
.txtfile to your local machine. - Mac Compatibility: Uses
tkmacosxto ensure buttons look and behave correctly on macOS.
Prerequisites
Before running the application, ensure you have Python installed. You will also need to install the tkmacosx library:
pip install tkmacosx
Getting Started
- Clone the repository: ```bash git clone https://github.com/your-username/invoice-generator.git cd invoice-generator
2. **Add your assets:**
Make sure you have an image named `b.png` in the root directory for the application logo (or update the code to point to your image).
3. **Run the application:**
```bash
python main.py
How to Use
- Select Product: Use the dropdown menu to pick an item. The price will populate automatically.
- Adjust Quantity: Enter the amount you wish to purchase.
- Apply Discounts/Tax: Enter percentage values in the respective fields; the Grand Total will update instantly.
- Add to List: Click ADD ITEM to move the data into the table.
- Save: Once finished, click DOWNLOAD INVOICE to save a text copy of your receipt.
Project Structure
main.py: The core application logic and UI layout.b.png: The store logo (placeholder).README.md: Documentation.
Contributing
Contributions, issues, and feature requests are welcome! Feel free to check the issues page.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature) - Commit your Changes (
git commit -m 'Add some AmazingFeature') - Push to the Branch (
git push origin feature/AmazingFeature) - Open a Pull Request
Note: If you are using this on Windows/Linux and don't want to use tkmacosx, you can simply replace the Button imports with the standard tk.Button.
Built With
- python
- tkinter
Log in or sign up for Devpost to join the conversation.