Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Screenshot To Text #319

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 49 additions & 0 deletions Planet Simulation/pomodoro.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
import time
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why it's on the planet simulation script?

import tkinter as tk
from tkinter import messagebox

def start():
work_time = 25*60
break_time = 5*60
long_break = 15*60

cycles = 0

def countDown(t):
while t:
mins, secs = divmod(t, 60)
timer = '{:02d}:{:02d}'.format(mins, secs)
timer_label.config(text=timer)
root.update()
time.sleep(1)
t-=1

def startCycle():
nonlocal cycles
if cycles < 4:
countDown(work_time)
messagebox.showinfo("Time's up!", "Take a 5-minute break!")
countDown(break_time)
cycles +=1
startCycle()
else:
countDown(work_time)
messagebox.showinfo("Time's up!", "Take a 15-minute break!")
countDown(long_break)
cycles = 0

startCycle()




root = tk.Tk()
root.title("Pomodoro Timer")

timer_label = tk.Label(root, font = ('Helvetica', 48), text="25:00")
timer_label.pack(pady=20)

start_btn = tk.Button(root, text="Start Pomdoro", command=start)
start_btn.pack()

root.mainloop()
30 changes: 30 additions & 0 deletions Screenshot To Text/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# OCR Text Extractor
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add this script to the main README file.
Screenshot To Text/main.py. Why is this empty?
Selfie with Python/README.md, why is this empty as well?


## Overview
**OCR Text Extractor** is a Python application that allows users to extract text from images using Optical Character Recognition (OCR) via the Tesseract engine. The application provides a simple and user-friendly graphical interface for uploading images, capturing full-screen screenshots, or pasting images from the clipboard to extract text.

## Features
- **Select Image File**: Choose an image from your computer to extract text from. Supported formats include `.png`, `.jpg`, `.jpeg`, and `.bmp`.
- **Paste Image from Clipboard**: Take a partial screenshot (e.g., using Windows + Shift + S) and extract text from the image saved in the clipboard.
- **Capture Full Screen Screenshot**: Capture a screenshot of your entire screen and extract text from it.

## Requirements
To run this application, you need to have the following installed:

- Python 3.x
- The following Python packages:
- `pytesseract` (Download Tesseract OCR from https://github.com/UB-Mannheim/tesseract/wiki and Add to Environment Path)
- `Pillow` (Python Imaging Library, a fork of PIL)
- `Tkinter` (comes pre-installed with Python on most systems)

### Installation of Required Packages
You can install the required packages using pip:

```bash
pip install pytesseract Pillow
```

### How to Run
```bash
python main.py
```
Empty file added Screenshot To Text/main.py
Empty file.
Empty file added Selfie with Python/README.md
Empty file.