PalmWord++ v2.2 and PalmWordPro v1.2
by Graham Wheeler
gramster@bigfoot.com























1. Introduction

PalmWord++ and PalmWordPro are powerful dictionary searching programs for use with word games line Scrabble, Target, crosswords, and codewords/cryptograms. You can use them to generate lists of anagrams and words, given a set of constraints on the available letters and their positions.

PalmWordPro has all of the functionality of PalmWord++, plus the ability to have multiple dictionaries resident at the same time, and switch between them freely. PalmWordPro also includes a Win32 dictionary maintenance program (FreeBSD or Linux executables available to registered users upon request)..

To use PalmWord++, you must also install one of the dictionary databases it comes with for it to search. To use PalmWordPro, you must install at least one of the dictionary databases it comes with.

The currently available dictionaries are:

demo.pdb - the dictionary that comes with the trial versions of PalmWord++ and PalmWordPro, this has 28,524 words, of up to 6 letters in length.

ospd3.pdb - for Scrabble players, this dictionary is made from the OSPD3 word list of  116,887 words of up to 13 characters in length.

small.pdb - a crossword dictionary of 53,975 common words of up to 13 characters in length.

medium.pdb - a medium sized crossword dictionary of 124,228 words of up to 13 characters in length.

large.pdb - this large crossword dictionary has 227,238 words of up to 15 letters in length.

huge.pdb - this very large dictionary has 341,907 entries of up to 15 letters in length (PalmWordPro only).

scrabtor.pdb - a Scrabble tournament dictionary of 173,866 words (PalmWordPro only)

The trial versions may be used with the demo.pdb dictionary only. Unauthorised redistribution of the other dictionary database files is not permitted.

In the rest of this document, we will refer to PalmWord++ most of the time - this applies to both programs. We refer to PalmWordPro only when discussing the additional features of PalmWordPro.
 

2. Quick Start

Section 3 provides a detailed description of how to use the programs. This section provides a quick introduction which will allow you to do the most common types of searches.

General Crossword Help

For help with a crossword word, where only some letters are known:

Finding Anagrams

The procedure for finding anagrams is identical to the above, except that you should  ensure that the button at the bottom right of the Main form is set to "Floating" instead of "Anchored" before you enter the word(s) that you want to find anagrams of..

For multi-word anagrams, check the Multi checkbox before starting the search (if the word breaks can occur anywhere) or use the "|" character as before to mark specific positions as word breaks (as in a crossword anagram clue). For example, if you had a crossword
clue "Wicked television arrangement (4,3,3)" which you guessed was an anagram of "television", you could enter "tele|vis|ion" to find all possible matches.

What's Missing in this Quick Start

Anagram hunting and crossword clue assistance are the most common uses of PalmWord++, and you don't need to know much more than this to get lots of benefit from the program. However, PalmWord++ supports far more complicated types of searching than this, including the ability to search for words with known prefixes and suffixes (such as words beginning with `post'- or words ending in `-tion'), and the ability to use numeric placeholders (variables) to specify letters; this is useful in the type of crossword known as a codeword, where each square is labeled with a number from 1 through 26 corresponding to a letter, and no clues are given. If you need this sort of functionality, you should read and understand the next section.
 

3. Detailed Description

The method used by PalmWord++ for searching  is fairly complex but worth understanding if you want to make full use of it. Underlying each search are two pieces of information:

A few examples can be used to illustrate the idea: Given a template and a letter pool, PalmWord++ tries to find matches by plugging different letters from the letter pool into different positions in the template.

Match Types

In the Main form, you can choose what type of match to use. There are three possibilities, and each possibility can also be used in either single word or multi-word mode:

The prefix and suffix matches can be illustrated by continuing with our last example. That is, we have template "R#P#" and letter pool "O,E". Using prefix matching, PalmWord++ would find words that match any of the following situations:
 
TEMPLATE
LETTER POOL
R
OE
R#
OE
R#P
OE
R#P#
OE

Using suffix matching, PalmWord++ would instead find matches of:
 
 TEMPLATE
LETTTER POOL
#
OE
P#
OE
#P#
OE
R#P#
OE

Thus with prefix matching, PalmWord++ will see if any of the following are valid words:

      R    RO   RE   ROP   REP   ROPE   REPO

while with suffix matching, it will check:

      O    E    PO   PE    OPE   EPO    ROPE    REPO

Actually, this is not strictly true. Because the letter pool can contain wildcards and letter ranges as well as specific letters, if PalmWord++ were to consider every possible permutation, some searches would take infinitely long (effectively, anyway), due to the exponential explosion in the number of possible arrangements. Instead, PalmWord++ walks through the dictionary, and checks which words in the dictionary can correspond to the template and letter pool. This can make some searches much slower, but does mean that there is a finite and not too large number of matches that must be done, and thus it is guaranteed to find all matches within a reasonable space of time. Of course, this is mainly true for single words - once you start searching for multi-word matches there is once again an explosion of possibilities, that even an efficient algorithm can choke on. Fortunately, if a search is taking too long for your liking, you can abort it at any time by pressing the Stop button in the Word form.

Note that in the case that the template is unconstrained (that is, all #'s), then prefix and suffix matching are identical, both having the meaning "words consisting of one or more letters from the pool".

If you didn't understand the last paragraph, reread the whole last section.

Specifying Search Patterns

When making consultations, you don't explicitly specify the template and letter pool as two separate pieces of information. Rather, you specify a single pattern, which PalmWord++ can split into a template and pool.

In the simplest case a pattern is a sequence of letters (whitespace may be present but is ignored). The letters may be either upper case or lower case, the former meaning that the letter must occur in that position (i.e. the letter  is a template constraint), while lower case means the letter need not be in that position (i.e. it is a letter in the letter pool). Thus our example above could be specified as "RoPe", or equivalently as "RePo".

A few more examples should help here. It should be clear by now that the order of letters in the template is fixed and significant, while the order of letters in the pool is arbitrary.
 
PATTERN
TEMPLATE
LETTER POOL
informatION
#######ION
informat
MISinformed
MIS########
informed
TreateD
T#####D
reate
T.....D
T#####D
any 5 letters
T:::::D
T-----D
empty

The first two are typical examples of patterns that would be used for suffix and prefix matching, respectively. The third is typical of a crossword situation where the first and last letters are known, and it is suspected that the word is an anagram of `treated'. The last two cases are a similar crossword lookup, with two known letters only (see below for a further explanation of these last two patterns).

Elements in the pattern that correspond to elements in the template are called "anchored", while elements in the pattern that go in the letter pool are called "floating".  During pattern input PalmWord++ is either in "floating" mode (in which case letters are entered in lower case by default) or "anchored" mode (in which case letters are entered in upper case by default). A button on the Main form toggles between these two modes. Note that the button only affects the default letter case of subsequently entered letters; it does NOT affect the actual search. If a letter appears in upper case in the pattern it is anchored, irrespective of the current setting of the input mode button, and similarly for lower case floating characters.
 

Letter Ranges

Patterns can also have `letter ranges' enclosed in brackets, such as `[A-Z]' (any letter), `[AEIOU]' (any one vowel) or `[A-MZ]' (any one of A through M, or Z). To specify the opposite of a range, start the range with an exclamation mark or caret. For example, [!AEIOU] matches any non-vowel. The  case of the first letter in the range determines whether the range will be used as a word template constraint or as a letter pool entry; other than this letter case is ignored. Thus, for example, "[a-Z]" is legitimate and equivalent to "[a-z]". Similarly "[A-z]" is equivalent to "[A-Z]".

PalmWord++ will allow you to use any type of brackets, and mix different types of brackets (thus "{a-z)" is acceptable and equivalent to "[a-z]").

There are shortcut buttons on the Main form for entering the left and right brackets, minus sign, and caret for negating character ranges.
Section 4 describes the user interface of PalmWord++ in some detail.

Special Pattern Characters

Patterns can also have some special characters. Each has an "upper case" (or anchored) and a "lower case" (or floating) form, analogous to letters. The special characters are:
 
MEANING
ANCHORED (TEMPLATE)
FLOATING
(LETTER POOL)
Any letter
:
.
Any vowel
*
+
Any consonant
=
-

The patterns above ("T.....D" and "T:::::D") are effectively equivalent, but this need not always be the case. For example, "Ta....D" and "Ta::::D" are not the same; in the former the `a' can be used in any of the five central positions, and the character in the second position can be any legitimate character, while in the latter case the `a', even though lower case, must occur in the second position, as all other  positions are in upper case and thus locked in place.

You cannot use these special characters within a range (thus for example, "[*y]" is not valid).
There are shortcut buttons in the Main form for entering these characters. The shortcut buttons are labeled "Any", "Vowel" and "Consonant", but will insert the single corresponding character into the pattern when pressed. The actual character entered will depend on whether the program is in "anchored" mode or "floating" mode.

Multi-Word Patterns

You can select multi-word matching in either of two ways: by checking the Multi checkbox on the main screen, or by explicitly specifying where word breaks should be by using the character "|" within your pattern. The former method is useful when you don't care where the word breaks occur; for example, when trying to find all multi-word anagrams. The latter method is useful when the word breaks must be in known locations in the position template. For example,  if you have a crossword clue that consists of a 3 letter word followed by a 4 letter word, and you think this is an anagram of teacher, you could use the pattern "tea|cher".

Be warned that multi-word anagram matching can be very time consuming, especially using the checkbox approach!

Using Variables

You can use the numbers 1 through 26 to represent letters. This is mostly useful for a certain type of crossword puzzle often called a codeword , due to its relationship with simple secret codes (namely substitution ciphers). A codeword usually has no clues in the usual crossword sense, but instead each empty square in the grid is labeled with a number from 1 through 26. Each number corresponds to exactly one letter, and this correspondence holds true throughout the grid. For example,  if the number 7 represents the letter G in a particular square, then all squares in the grid  labeled with a 7 can be filled in with G's.

A single word example may be `1 2 2 1 3'. This pattern would match words such as ABBAS, ALLAY, TOOTH and TEETH. To enter such a pattern in PalmWord++, you must separate the numbers with spaces (there is a shortcut button for this). You can also specify a constraint  on a variable by separating it from the number with a slash character. For example:

        1/[AEIOU] 2 2 1 3

 is the same pattern as before except that the variable `1' must be a vowel.

All numeric variables are considered anchored; PalmWord++ does not yet support floating variables. If you specify a floating constraint (such as a lower case letter) it will be treated as the equivalent anchored constraint.

PalmWord++ will remember the possible assignments of letters to variables between searches and use these to constrain further searches. This is useful to maintain consistent constraints while matching different words in the grid. Be warned, however - this process can eliminate more than you would like, particularly if the word on the grid happens to not be in the PalmWord++ dictionary you are using. Interrupting the search is another way in which the constraints can be improperly computed, and thus PalmWord++ only records the constraints from a match after you have stepped through all the possible matches in the Word Form.

You can discard the current constraints and start afresh at any stage selecting Reset Constraints from the Edit menu in the Main form, or by pressing the Rst button in the Variables form (see below for more about these).

As you become confident about the associations between the numbers and the letters in the grid you can start using variable assignments. Assignments differ from constraints in that they are made explicitly by the user, are reset separately, and must be of a single letter to a variable (whereas the constraints are of character ranges that can match the variables). To assign a letter to a variable, you need to tap on the variable in the Variable form. That pops up the Variable Assignment dialog. You can clear all variable assignments by pressing Clr in the Variable form or by selecting Clear Assignments from the Edit menu in the Main form.
 

Word Length and Count Constraints

You can specify minimum and maximum word lengths for prefix, and suffix, and the minimum and maximum number of words allowed
per match for multi-word matching. If these are set to the default they will have no effect. They can be useful when generating multi-word
anagrams with patterns that contain several A's or I's, as PalmWord++ will likely  churn out thousands of matches in these cases starting
with the words `A', `AA', and/or `I'. Setting the minimum length to three (for example) can help prevent this.

A Tip for Multi-Word Anagrams

Quite often there will be thousands of possible anagrams and it becomes impossible to hunt down the good ones. There is a
technique to help in this case - look through some of the possibilities, and select a word you think is appropriate in the final anagram.
Then subtract this word from the input, and see what words can be made from the remaining letters. For example, consider
VEGETARIAN. We see that some anagrams have the word RAVE, and decide to use this. This means we must find anagrams of the remaining letters, namely GETIAN. We find the word EATING. Thus VEGETARIAN=EATING RAVE.
 

4.The User Interface

The Main Form in PalmWord++

The Main Form in PalmWordPro (note the popup trigger for selecting the dictionary).

The Main Form is what you see when you start up the program. The various controls are:

PalmWordPro includes an extra list box trigger, which can be used to pop up a list of available dictionaries and allow you to choose the one to use for subsequent searches.
 

This is the dialog box for selecting the type of matching to use

This is the dialog for selecting a minimum word count.

This is the dialog for selecting the minimum word length for multi-word matching.

The dialogs for entering the maximum word count and maximum word length are identical apart from their titles.

After pressing Go! in the Main Form, PalmWord++ will display the matches found in the Word Form, shown below.

  The Word Form, displaying the partial results of a pattern search.

The controls in the Word Form are:

If you press the Vars button, the Variable Form will be displayed. This is shown below:
 

The Variable Form, showing some computed variable constraints and one assignment

There are three buttons at the top right, namely:

You can assign a value to a variable by tapping on its entry in the list. This will pop up the Set Variable dialog shown below, from which you can associate a specific letter with a variable (effectively making it a constant) or break the association and make the variable variable once more.

The Set Variable dialog, with the selected variable currently set to be `B'.

When in the Main Form, you can access a menu bar with two menus. the Edit Menu and the Help Menu. The Help Menu has just one selection, namely `About PalmWord++. The Main Menu is shown below:

Many of these are standard operations for PalmPilot apps for text editing. The ones specific to PalmWord++ are:
 


Using A Keyboard

If you have a Palm keyboard, you can make use of some additional key assignments (you can do this with Graffiti too but its more tedious than using the buttons on the screen). In the Main Form, you can use the tilde character ~ to recall a history item; just enter a digit from 0 through 9 after the tilde. ~0 recalls the last pattern, ~1 the pattern before that, and so on.

In the Word For, the following keys are equivalent to buttons on the screen:

Newline or PageDown, or the down scroll button on the Palm - equivalent to tapping the Next button
'r', 'R', or the up scroll button - equivalent to tapping the Redo button
'n', 'N', or backspace - equivalent to tapping the New button
'v' or 'V' - equivalent to tapping the Vars button
 

5. The Dictionary Manager (PalmWordPro Only)

PalmWordPro includes a command-line utility for MS-Windows systems named dictmgr.exe. This program can be used to dump the contents of a .pdb dictionary database to a word list in an ASCII text file, and to produce .pdb dictionary files from word lists in ASCII text files.

To list the words in a dictionary, use the form:
 

dictmgr -l pdbfile


If you want to send the output to a file, you can use:
 

dictmgr -l -o txtfile pdbfile


To build a .pdb dictionary from a word list in a text file, use:
 

dictmgr -n name -o pdbfile txtfile


The name should be a short descriptive name. It must be quoted if it contains spaces. The input txtfile must have one word per line. You can specify up to 16 txtfiles on the command line and the word lists will be merged into a single .pdb file.

The following example dumps the words in the large dictionary to an ASCII text file called words.txt:
 

dictmgr -l -o words.txt large.pdb


The next example recreates the large dictionary database from the dumped word list:
 

dictmgr -S -n "Large" -o large.pdb words.txt


Note that building a .pdb file can take quite a while, especially for large word lists!

The -S flag shown above tells dictmgr that the words.txt file is already sorted, which makes dictmgr start up faster and use less memory.

Versions of the dictionary manager are also available for FreeBSD (maybe Solaris too if there is a demand). Registered users should contact the author if they wish to obtain any of these. I've never understood the GPL and GLPL viruses well enough to know whether I'm safe releasing a version for Linux, so Linux users lose, I'm afraid. Switch to FreeBSD, is my advice!
 

6. Registration

PalmWord++ and PalmWordPro are shareware, and cost US$10 and US$15 respectively. The trial versions can be used with the demo.pdb dictionary for 21 days for evaluation purposes. If you continue to use either of the programs after that, you must pay for them. The full versions can be purchased and downloaded from PalmGear Headquarters at http://www.palmgear.com. Registered users get access to other dictionaries and to future updates.

7. Disclaimer

This software is provided "as is", and the author makes no warranties as to its fitness for any purpose.

8. Version History

Note - I only started keeping track of this with version 1.4;  the rest are as I can remember.

Changes in version 1.1

Added the ability to restart the current search.

Changes in version 1.2

Added the progress bar.

Changes in version 1.3

Added the Stop! button to interrupt searches.

Added the special character shortcut buttons.

Changes in version 1.4

Introduced the history feature, and the Clear button,  and preserved the main form settings better between  consultations.

Changes in version 1.5

Made the main form settings and history persistent, even  if you temporarily switch to another application.

Made the button labels more meaningful.

Fixed some bugs in v1.4.

Changes in version 1.6

Added a button shortcut for `-'.

Reduced stack usage; the introduction of the history feature increased stack usage to such an extent that blowing the stack and crashing the Palm was possible in 1.4 and 1.5.

Changes in version 1.7

Fixed the problem of the pattern field being clobbered by an old value when changing the mode toggle.

Added support for variables (numeric placeholders).

Added support for `|' as a word separator.

Tidied up some of the screen layout.

Created HTML manual.

Changed the open mode of the dictionary to read-only to support flash RAM database residency.

Changes in version PalmWord++ 1.8 / PalmWordPro 1.0

Fixed all known reproducible bugs.

Reimplemented variable support to work more intuitively.

Radically reduced stack requirements, moving much of the data that was previously allocated on the stack to the global variable space.

Added the dictionary maintenance program and split into two products.

Improved the speed of the searches.

Changes in PalmWord++ 2.1 and PalmWordPro 1.1

PalmWord++ 1.8 should really have been called PalmWord++ 2.0, and so I'm jumping to 2.1 here which makes it easier to keep in sync with PalmWordPro's version number.

dictmgr will now sort the input word lists if necessary, and no longer requires the word lists to be presorted.

Added a Scrabble (tm) tournament dictionary to those shipped with PalmWordPro.

Fixed a bug in the word length handling. If the minimum word length was set to some positive value but the maximum word length was set to `Any' then the word length settings didn't have any effect.

Fixed a bug in the drawing of the progress bar.

When you start a new search (by starting the application or tapping on New in the Word List form), the pattern is now cleared instead of being set to the last one used.

You can now use a newline in the graffiti area to start a search as an alternative to tapping on the Go! button.

Changes in PalmWord++ 2.2 and PalmWordPro 1.2 (31 April 2000)

Added the additional key assignments to make it easier to drive PalmWord from a keyboard

Fixed the version number shown in the About box.
 

8. Known Bugs/Limitations/Common Problems

There are no known bugs in this release (there are some shortcomings, but that's what progress is all about!)

There are some limitations. Search patterns are restricted to 63 characters, while words are restricted to 31.
You can have at most 32 floating elements in a pattern (more than this and PalmWord will probably take forever to find anything anyway).

From questions I get asked by e-mail, I think I should just stress a few points:

You must load a dictionary .pdb file or PalmWord will just show a "No dictionary!" error when you try to search.

Think of the search in terms of the two components of letter pool and word template. Imagine the letter pool as a group of letter tiles, some of which are like jokers or wildcards, although they may be restricted to sub-ranges of the alphabet (such as vowels). These tiles have to be placed into
a crossword like template, and some of them may have to be used in specific positions in that template.

The different pattern elements you enter each have to correspond to a single letter PalmWord does not yet have support for regular expression type wildcards, such as `.*' which typically represents an arbitrary sequence of zero or more characters; i.e. they have variable length.

Remember the Floating/Anchored button is just like a Caps Lock button - it has no effect on characters already entered but sets the letter case for further input. It is the actual case of the letters as they appear on the display that determines whether they are fixed in position or floating.

To find all words that start with some known prefix, such as NEO for example, you would enter a pattern like "NEO::::::::::::" (remember `:' corresponds to `any letter'). You would select Prefix matching, with a minimum word length of 3. Similarly, to find words ending with a known suffix, such as OLOGY, you would enter a pattern like "::::::::::OLOGY", select Suffix matching, and specify a minimum word length of 5.

9. Contacting the Author

I am always interested to hear bug reports, feature requests, and of novel uses for PalmWord (such as using it to solve puzzles in computer adventure games, substitution ciphers, and so on. Please mail any comments to gramster@bigfoot.com

I am also interested in (non-copyrighted) word lists and dictionaries in other language, provided they use the 26 letter latin alphabet .Thus far, Ruud van der Ham has contributed a Dutch dictionary to me (as well as some useful shortcuts in PalmWord++ 2.1/PalmWordPro 1.1 and PalmWord++ 2.2/PalmWordPro 1.2). If any registered users want a copy of the Dutch dictionary, please contact me.
 

Enjoy using PalmWord++/PalmWordPro!