Scanner with Tcl/Tk
A user interface without any hassle wiithin 5min
No Python, no compiler, a simple grid layout to call
scanimage. An easy tool for my 8year old
to turn workbooks, tests and home schooling results into
I decided to go with pure Tcl/Tk because there are only linux computers in our household. The program has a simple structure and may offer a way into programming. The basic structure is taken from a documentation.
These few lines are the program's basic structure. Only the other columns are missing as well as a few lines of fear-driven code to catch errors and validate input. The button starts the sub command to commandeer the scanner. Its output goes into a folder with the week's number. Grid layout looks like this:
My target audience was quite fast understanding the principle of operation: choose from left to right. Text input receives a task's title or page number. Date and number of week are derived automatically. A starter on the desktop decorated with a scanner image are easy to invoke. It only requires a few minutes of work for my daughter to scan a week's work.
Tkinter is not necessary to use themes. And it requires only 4
lines of code. I prefer the classic ttkthemes.
The Python code is not necessary. Place a symbolic link to
append to lookup path:
- A First (Real) Example (tkdocs.com) – Tcl Real World example
- Tkinter's ttkthemes (github.com) – TkinterEP ttkthemes