TheJoeFin / Text-Grab

Use OCR in Windows quickly and easily with Text Grab. With optional background process and notifications.
https://www.microsoft.com/en-us/p/text-grab/9mznkqj7sl0b?cid=TextGrabGitHub
MIT License
3.28k stars 221 forks source link

Automatically copy the recognized text #367

Open vivadavid opened 11 months ago

vivadavid commented 11 months ago

Describe the pain point and your solution I think that it would be practical to include a setting to automatically copy the text you've just recognized, so you can quickly paste it without having to go to the Edit Text Window. A user with experience using OCR may safely anticipate whether the quality of the image will lead to good OCR, and he or she can always go to the Edit Text Window if needed.

I don't know if the size of the recognized text could be a problem, but since you can only recognize something the size of your screen, the number of characters should be kept within a reasonable limit.

I wonder if this setting should be disabled by default. A user might have something important stored in the Clipboard, which he or she would unknowingly lose after getting the text recognized.

TheJoeFin commented 11 months ago

This is how Text Grab works today. Maybe I'm missing something.

How Text Grab works today:

  1. Activate Full Screen Grab"

  2. Select region of text to OCR

    1. Do NOT have "Send To Edit Text Window" checked (show as checked here) image
  3. Paste into text field

You can even enable auto paste where the text gets pasted right into any text field! image

vivadavid commented 11 months ago

Hi, @TheJoeFin,

Sorry, you are right: the setting was there, and in my case, it was enabled. I should have checked all the settings before posting my message. Since the text wasn't being copied to the Clipboard, I just assumed the feature didn't exist.

However, as you mentioned earlier, if you disable Never automatically add text to the clipboard, but you also enable Send to an Edit Text Window, the second setting overrides the first setting. Wouldn't it make sense to have them independent from each other, so you can have the text automatically saved in the Clipboard and, at the same time, you can directly go to the Edit Text Window just to make sure the recognized text is correct?

By the way, I don't get what this feature does: "Try to Insert text in text fields after Fullscreen Grab after".

vivadavid commented 11 months ago

My previous comment had a mistake in the last line, which I have now corrected. I'm not having my best day today.

TheJoeFin commented 11 months ago

David, I hear you, but I think this may be a problem of communicating what is possible and how Text Grab works, not a new feature.

My recommendation for something you should try is:

  1. Use the Fullscreen grab to capture text
  2. Send it to an Edit Text Window
  3. Make your first Button in the Edit Text Window "Copy & Close"
  4. Press Ctrl + 1 to activate it

The feature Try to Insert text in text fields after Fullscreen Grab will paste the copied text after the set time.

vivadavid commented 11 months ago

Hi, @TheJoeFin ,

  1. Yes, I know now it's not a new feature: I apologized earlier about that. But as the thread was already open, I thought about making a suggestion.
  2. I still believe it'd be useful to add the text automatically to the clipboard even if Edit Text Window is enabled. However, there is a risk: if the user edits something and he or she forgets to click on Copy & Close, he'd keep an unedited version of the text on the clipboard.
  3. After capturing text wih Fullscreen Grab, I've immediately placed the cursor on a Notepad document, but nothing's happened.
TheJoeFin commented 10 months ago
  1. I still believe it'd be useful to add the text automatically to the clipboard even if Edit Text Window is enabled. However, there is a risk: if the user edits something and he or she forgets to click on Copy & Close, he'd keep an unedited version of the text on the clipboard.

I'm going to keep the behavior as it is today. If you accidently close an Edit Text Window you can recover the text by opening a new Edit Text Window, clicking File, clicking Recent, and clicking the one you want to open. Also you can set a keyboard shortcut to open the last Edit Text window just closed

image

  1. After capturing text wih Fullscreen Grab, I've immediately placed the cursor on a Notepad document, but nothing's happened.

Yep. Found another bug thank you for being so thorough!

vivadavid commented 10 months ago

You're welcome, @TheJoeFin , and thanks for the new release! I'll check it out tomorror!