{"id":30614126,"url":"https://github.com/fgatto13/pythonstopwatch","last_synced_at":"2026-06-23T17:32:22.364Z","repository":{"id":307501174,"uuid":"1029737541","full_name":"fgatto13/PythonStopWatch","owner":"fgatto13","description":"A PyQt5 stopwatch app with real-time clock, custom 7-segment-style font, and dynamic UI. Includes start/stop/reset controls, hover effects, and precise 10ms updates.","archived":false,"fork":false,"pushed_at":"2025-07-31T15:42:39.000Z","size":251,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-07-31T17:41:18.294Z","etag":null,"topics":["beginner-project","custom-font","desktop-app","gui","pyqt5","python","qt","stopwatch","time-tracking"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fgatto13.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-07-31T13:49:15.000Z","updated_at":"2025-07-31T15:47:05.000Z","dependencies_parsed_at":"2025-07-31T17:41:19.971Z","dependency_job_id":"65c13992-e63f-4dad-ba7d-679ea51878bc","html_url":"https://github.com/fgatto13/PythonStopWatch","commit_stats":null,"previous_names":["fgatto13/pythonstopwatch"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/fgatto13/PythonStopWatch","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fgatto13%2FPythonStopWatch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fgatto13%2FPythonStopWatch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fgatto13%2FPythonStopWatch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fgatto13%2FPythonStopWatch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fgatto13","download_url":"https://codeload.github.com/fgatto13/PythonStopWatch/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fgatto13%2FPythonStopWatch/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272815845,"owners_count":24997662,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-30T02:00:09.474Z","response_time":77,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["beginner-project","custom-font","desktop-app","gui","pyqt5","python","qt","stopwatch","time-tracking"],"created_at":"2025-08-30T07:01:30.838Z","updated_at":"2026-06-23T17:32:22.317Z","avatar_url":"https://github.com/fgatto13.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🐍 PythonStopWatch ⏱️\n## 🖼 App Preview\nHere you can see what the app looks like:\n\n![Screen1](assets/Screenshot%202025-07-31%20alle%2017.24.14.png)\n\nAnd here are a couple of screenshots to show how the app behaves based on the operation performed:\n\n\u003cp float=\"left\"\u003e\n    \u003cimg src=\"assets/Screenshot%202025-07-31%20alle%2017.24.14.png\" width=\"135\"/\u003e\n    \u003cimg src=\"assets/Screenshot%202025-07-31%20alle%2017.24.28.png\" width=\"135\"/\u003e\n    \u003cimg src=\"assets/Screenshot%202025-07-31%20alle%2017.24.38.png\" width=\"135\"/\u003e\n\u003c/p\u003e\n\nThis project is a stopwatch application built with **PyQt5**, combining a real-time digital clock with a start/stop/reset timer. It features a custom 7-segment-style font, dynamic styling, and a clean, interactive interface.\n\n---\n\n## 🚀 Features\n\n- ✅ Stopwatch with Start / Stop / Reset functionality\n- ✅ Real-time digital clock displayed at the top\n- ✅ Updates every 10 milliseconds\n- ✅ Custom font (`DS-DIGIT.TTF`) loaded safely with fallback\n- ✅ Clean UI with bold styling and hover effects\n- ✅ Custom cursor for buttons\n- ✅ Button states change dynamically (e.g., disable Start after press)\n- ✅ Designed for modularity and clarity using multiple classes\n\n---\n\n## 🗂 Project Structure\n\n```\nPythonStopwatch/\n├── main.py              # Entry point – initializes and runs the app\n├── stopwatch.py         # Main widget – stopwatch UI and logic\n├── digitalClock.py      # Reused digital clock widget with real-time display\n├── fonts/\n│   └── ds_digital/\n│       └── DS-DIGIT.TTF # Custom digital-style font\n```\n\n---\n\n## 🎨 Styling\n\nThe app uses Qt Style Sheets (QSS) within Python to style:\n\n- Labels and buttons with rounded borders\n- Button hover states\n- Font sizes and background colors\n\nButtons are enhanced with a **pointing hand cursor** to signal interactivity.\n\n---\n\n## 🧠 How It Works\n\n- The stopwatch uses `QTime` and `QTimer` to track elapsed time in 10ms intervals.\n- The digital clock updates every second using its own `QTimer`.\n- Time is formatted consistently using `f\"{val:02}\"` specifiers to ensure fixed-width layout.\n- The custom font is loaded using `QFontDatabase.addApplicationFont(...)` with safe fallbacks and exception handling.\n- Font path detection adapts for PyInstaller or `.app` bundle usage.\n\n---\n\n## ▶️ Running the App\n\n```bash\npip install PyQt5\npython main.py\n```\n\n---\n\n## 💾 Font Loading\n\nThe stopwatch uses a custom font stored at:\n\n```\nfonts/ds_digital/DS-DIGIT.TTF\n```\n\nIt is loaded programmatically and safely handled in case the file is missing or fails to register.\n\n---\n\n## 🧑‍💻 Author\n\nBuilt by @fgatto13  \nThis project reflects applied concepts of custom font handling, \ntime management, event-driven programming, and clean UI design in PyQt5.\n\n## 🙏 Credits \u0026 Acknowledgments\n\nThis project is based on a PyQt5 digital stopwatch tutorial originally created by [BroCode](https://www.youtube.com/watch?v=ix9cRaBkVe0\u0026t=17196s).\n\nThe original tutorial served as a foundation for building a simple stopwatch GUI. \n\nThis version adds:\n- event handling of the various buttons (enabled/disabled dynamically)\n- dynamic changes based on events for the text\n- a custom font\n- reuse of another custom widget (digital clock)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffgatto13%2Fpythonstopwatch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffgatto13%2Fpythonstopwatch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffgatto13%2Fpythonstopwatch/lists"}