|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.darwinsys.notepad.Notepad
public class Notepad
Simple text editor, making Swing do the work. Is it MVC? Well, the JTextArea is the Model, the Actions are Controllers, and the rest is View.
Constructor Summary | |
---|---|
Notepad()
|
|
Notepad(boolean isStandalone)
|
Method Summary | |
---|---|
void |
doLoad(java.io.File file)
|
void |
doLoad(java.lang.String fileName)
|
void |
doPrint()
Print a file by name |
void |
doSave(java.io.File file)
Save the file to disk, in such a way as to map the UNIX line-endings used inside JTextArea to the correct platform-specific line endings as generated by println(). |
void |
doSave(java.lang.String fileName)
Thin wrapper for doSave(File). |
javax.swing.JMenu |
getEditMenu()
|
javax.swing.JMenu |
getFileMenu()
|
javax.swing.JMenu |
getHelpMenu()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Notepad()
public Notepad(boolean isStandalone)
Method Detail |
---|
public final void doPrint() throws java.io.IOException, javax.print.PrintException
java.io.IOException
javax.print.PrintException
public final void doLoad(java.io.File file) throws java.io.IOException
java.io.IOException
public final void doLoad(java.lang.String fileName) throws java.io.IOException
java.io.IOException
public final void doSave(java.lang.String fileName) throws java.io.IOException
fileName
-
java.io.IOException
public final void doSave(java.io.File file) throws java.io.IOException
file
-
java.io.IOException
public javax.swing.JMenu getEditMenu()
public javax.swing.JMenu getFileMenu()
public javax.swing.JMenu getHelpMenu()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |