BreezyGUI
application that maintains a dictionary.
The interface should have the following components:
Word
menu containing the options Add
Delete
Show
and
List
File
menu containing the options Load
Save
Quit
Quit
option entirely (just call System.exit()
, see API docs for details). After you
have this part working you can implement the menu options one by one. In addition the interface should also have
Here's what each of the menu options should do:
For this assignment you need to check the API for The second class should be of much more help to you.
File/Load
- Loads an existing dictionary from a file called
Dictionary
on the disk.
If the operation cannot be performed it should pop up a message box and display a message to that effect.
Word/Add
- Adds one entry (the word in the text field and the definition in the text area) to the dictionary.
Word/List
- List all the words in the dictionary. You should output only the words, and not their definitions, in a message box, one word per line).
File/Save
- Saves the current dictionary to a file called
Dictionary
.
Obviously the file is overwritten by this operation.
Word/Show
- Updates the text area with the definition of the word that is in the text field.
Word/Delete
- Deletes from the dictionary the entry corresponding to the word that is in the text field.
File/Quit
- Quits the program without saving.