ocrdesktop(1)
π¦ ocrdesktop(1) β General Commands Manual π¦
okay so bestie, this is ocrdesktop(1), and it lives in the General Commands Manual section, and it's literally the accessibility tool you didn't know you needed. buckle up π
β¨ NAME β¨
ocrdesktop β read and interact with content on your GUI desktop via OCR π«Ά
πΈ SYNOPSIS πΈ
ocrdesktop [options...]
π DESCRIPTION π
OCRdesktop is a useful accessibility tool that grabs content off your screen as text, using OCR technology. no cap. π
It takes an image of the current window or workspace, preps it so the results come out better, and then lets tesseract recognize the text on it. The result gets presented in a caret-enabled text area as a detailed list with coordinates β where you can emulate clicks on the text, or just yeet the results straight to the clipboard. There are two main views π
- The browse mode view: This is where the OCR results are displayed in a caret-browsable text area. There are buttons to perform mouse clicks, change views, etc., available in a traditional menu layout that you open with F10.
- The detailed view: In this view you can see meta data for the displayed items. Each output text string is shown in the first column of a table. The 2nd column gives the font size used. The 3rd column shows color information when available. The next column has the X coordinant for that item, and the following column has its Y coordinant. Finally, a percent value for accuracy confidence is shown. You can also see and change the font used to display output using the Tab key. The shortcut to toggle between these two views is Ctrl+V. π₯
π§ Setup
Assign the command ocrdesktop to a keyboard shortcut in your desktop environment. e.g., in Gnome or Unity you can do this via the Gnome Control Center, in the Keyboard window, in the Shortcuts tab. β¨
For languages other than english, set your language code with ocrdesktop -l <languagecode>. Use the tesseract language codes for <languagecode>. You also can use other parameters to expand the function when starting OCRdesktop.
Of course the program can be run via your desktop's run box or dash, but running from a terminal may not be desirable β because the terminal window will be in ocrdesktop's screenshot. π
Tip: make at least two shortcuts β one without options to capture the active window only, and another with -d to take a screenshot of the whole desktop. π«Ά
π Usage
ocrdesktop, when run with no commandline options, shows the processed output of the active window. Run ocrdesktop with the -d switch and the whole desktop is processed. π
If the OCR quality is not good in the first processing of a screenshot, there are transformation options that may improve character recognission accuracy. To use these options, take new screenshots using one or more transformation flags. Available transformation options are:
-iwill invert foreground and background color or tone.-guses a gray scale instead of original colors.-buses a barier blackwhite method. This method uses the gray scale, and sets a barier where all shades darker than the barier are considered black, and everything lighter is seen as white. The default barier is200, but can be set on the commandline. This method is useful when working with very bright colors or blurry text.
Open menus to see all available options. They are devided in to three categories: ocrdesktop, interact and macros. There are keyboard shortcuts for all ocrdesktop options. In ocrdesktop you find toggle view, send to clipboard and quit. interact has controls for simulated mouse clicks etc. The macros menu lets you load, unload, and save macros. π
π Macros
In most desktop environments, global shortcuts don't work while menus are open β e.g., the file menu in the menu bar at the top of most programs. Ocrdeskop can use preclicks: macros that can be run before the screenshot is taken. This allows you to close all menus and let OCRdesktop click on the menu before it recognizes the window. π¦
To use preclick macros, press on preclick in the interact menu, or use the Ctrl+P shortcut. Then choose a mouse click to perform before OCRdesktop starts the next time. After you click on the button that starts a mouse click, nothing will happen. Next time you run OCRdesktop, it will ask what to do. You can press Run, so all stored clicks will execute. After that, OCRdesktop takes its screenshot for OCR on the screen as it is after the click action has been performed. Use the Save As option and Preclick and Save As again, and the second click will also be stored β e.g. for opening a sub menu. π
You can also fire keyboard shortcuts into the preclick macros. To enter the shortcut recording mode, press Ctrl+K or select the Send Key menue entry in the Interact menu. Now every keystroke you type is appended to the currently active preclick macro. Pressing F4 will leve the recording mode. Leving the shortcut recording mode may have a delay of up to 2 seconds. β³
You can save as many mouse operations as you want.
Choose unload in the macro window to erase the macro, so its lost. If you press Cancel, no mouse clicks are performed, but the main window opens. The macro will not be deleted and you will be asked next time you start OCRDesktop if you want to run your stored clicks. π
Tip: macros are stored in ~/.activeOCRMacro.ocrm. The Save As option lets you store macros in another location if yu choose. It will open a standard file chooser window where you select a name and location for your macro file. π
π OPTIONS π
-bβ convert to black and white before doing OCR;-toptional to set barier point-cβ send text output to clipboard-dβ perform OCR on the whole desktop, not just the active window-gβ convert colors to gray scale before doing OCR-hβ show a short help message-iβ invert foreground and background colors before doing OCR-mβ execute macro: path to macro-file is required with-m-nβ no GUI is shown: run with-cor-m-pβ print debug messages
π§ EXIT CODES π§
literally nothing here, bestie β the original page lists this section and leaves it empty. no exit-code lore today π
π FILES π
/usr/bin/ocrdesktopβ the executable/usr/share/man/man1/ocrdesktop.1.gzβ this manpage
π BUGS π
Leving the shortcut recording mode may have a delay of up to 2 seconds. π
Please report bugs and/or submit fixes or code enhancements to chrys87@web.de. do it, she'd love that π
π AUTHOR π
ocrdesktop was written by Chrys <chrys87@web.de>. B.H. wrote this manpage. π«Ά
π WEBSITE π
https://aur.archlinux.org/packages/ocrdesktop/https://wiki.archlinux.org/index.php?title=Ocrdesktop&redirect=no
π SEE ALSO π
π Copyright Notice π
## You may distribute this work under the GNU General Public License3 or
## optionally any later version of the GPL if required by your project.
okay and the lil sign-off π β this page's footer says the manpage template was generated by s... on 27/09/2015, and it closes with ocrdesktop(1) again, so likeβ¦ full circle, periodt. πβ¨
π¦ where this page comes from
- arch rolling: ocrdesktop 4.0-2 Β· GPL3
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms