pycrossword
User Guide
×
Menu tab
Index tab

3.9.2.2. Text file sources

 
To use words from a text file, follow the same instructions as with databases, but select the File type in the Source Type box. The controls differ from the Database option:
 
3.9.2.2. Text file sources
Fig. 3.9.2.2.1. Configuring a text file source
1

Word source name

1. Word source name
Type a name for this word source, e.g. "eng20"
2

Source file path

2. Source file path
Path to the source text file. For this example, I took the "english.20" word list from the SCOWL project.
Note that the file type (extension) doesn't matter, it doesn't have to be *.txt or anything else.
3

Character encoding

3. Character encoding
The source file encoding used to read the data from it correctly. Leave utf_8 (Unicode) if you are unsure.
4

Part-of-speech delimiter

4. Part-of-speech delimiter
If your file contains part-of-speech data, it should be separated from the words with a delimiting symbol. The most common delimiters are the space (" ") and the slash ("/").
5

Shuffle

5. Shuffle
With this option activated (by default), the search results will be shuffled randomly during crossword generation. When unchecked, the results will always reflect the original ordering (as in the source file).
6

Edit

6. Edit
You may edit your text file in an external editor (such as the free Notepad++) if it is set in Options > Plugins > Third-party > Text Editor. The inactive button indicates that an external editor is not assigned.
 
submit to reddit
Made with help of Dr.Explain