jimmc.roots
Class ScrolledTextWriter

java.lang.Object
  |
  +--java.io.Writer
        |
        +--jimmc.roots.ScrolledTextWriter

public class ScrolledTextWriter
extends java.io.Writer

This class directs Writer output to a ScrolledText window.


Field Summary
protected  ScrolledText scrolledText
          Our output field.
 
Fields inherited from class java.io.Writer
lock
 
Constructor Summary
ScrolledTextWriter(ScrolledText f)
          Set up a writer for a ScrolledText field.
 
Method Summary
protected  void appendText(java.lang.String s)
          Append a string to the text field.
 void close()
          Nothing to do on a close.
 void flush()
          Nothing to do on a flush.
 void write(char[] b, int off, int len)
          Write a sub array of chars to the text field.
 void write(int b)
          Write a char to the text field.
 void write(java.lang.String s, int off, int len)
          Write a substring to the text field.
 
Methods inherited from class java.io.Writer
write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

scrolledText

protected ScrolledText scrolledText
Our output field.
Constructor Detail

ScrolledTextWriter

public ScrolledTextWriter(ScrolledText f)
Set up a writer for a ScrolledText field.
Method Detail

flush

public void flush()
Nothing to do on a flush.
Overrides:
flush in class java.io.Writer

close

public void close()
Nothing to do on a close.
Overrides:
close in class java.io.Writer

write

public void write(int b)
Write a char to the text field.
Overrides:
write in class java.io.Writer
Parameters:
b - the char

write

public void write(char[] b,
                  int off,
                  int len)
Write a sub array of chars to the text field.
Overrides:
write in class java.io.Writer
Parameters:
b - the data to be written
off - the start offset in the data
len - the number of chars to write

write

public void write(java.lang.String s,
                  int off,
                  int len)
Write a substring to the text field.
Overrides:
write in class java.io.Writer
Parameters:
s - the string to be written
off - the start offset in the string
len - the number of chars to write

appendText

protected void appendText(java.lang.String s)
Append a string to the text field.