|
|||||||||
| Home >> All >> org >> mitre >> [ cvw overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.mitre.cvw
Class RoomScrollback

java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.text.JTextComponent
javax.swing.JEditorPane
javax.swing.JTextPane
org.mitre.cvw.RoomScrollback
- All Implemented Interfaces:
- javax.accessibility.Accessible, java.awt.image.ImageObserver, java.awt.MenuContainer, javax.swing.Scrollable, java.io.Serializable
- public class RoomScrollback
- extends javax.swing.JTextPane
This is the class that represents the room scrollback. It knows which window it belongs to, how to launch urls, and how to print various messages.
- Version:
- 1.0
| Nested Class Summary |
| Nested classes inherited from class javax.swing.JEditorPane |
javax.swing.JEditorPane.AccessibleJEditorPane, javax.swing.JEditorPane.AccessibleJEditorPaneHTML, javax.swing.JEditorPane.JEditorPaneAccessibleHypertextSupport |
| Nested classes inherited from class javax.swing.text.JTextComponent |
javax.swing.text.JTextComponent.AccessibleJTextComponent, javax.swing.text.JTextComponent.KeyBinding |
| Nested classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
| Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
| Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
| Field Summary | |
(package private) int |
areaWidth
|
(package private) int |
charCount
|
private static org.mitre.cvw.search.TextSearcher |
currentSearch
|
(package private) TextStyle |
currStyle
|
(package private) boolean |
delete
|
(package private) boolean |
dragging
|
(package private) CVWCoordinator |
jcvw
|
(package private) int |
lineCount
|
(package private) int |
maxLineLen
|
(package private) RoomScrollbackClient |
myApp
|
(package private) java.util.Vector |
pastScrollback
|
(package private) boolean |
scrollLock
|
(package private) javax.swing.JScrollPane |
scrollPane
|
(package private) boolean |
warning
|
| Fields inherited from class javax.swing.JEditorPane |
|
| Fields inherited from class javax.swing.text.JTextComponent |
DEFAULT_KEYMAP, FOCUS_ACCELERATOR_KEY |
| Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Container |
|
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
RoomScrollback(RoomScrollbackClient app)
Constructor |
|
RoomScrollback(RoomScrollbackClient app,
boolean b)
|
|
| Method Summary | |
void |
addMinimizeButton(javax.swing.JButton btn)
|
void |
append(java.lang.String str)
Appends some text with the current style. |
void |
append(java.lang.String str,
java.awt.Color color)
Appends some text in a particular color. |
void |
append(java.lang.String str,
javax.swing.text.Style style)
Appends some text to the scrollback with a particular style. |
void |
appendBold(java.lang.String str)
Appends some text with the current style bolded. |
void |
clearScrollback()
Clears all the text from the scrollback. |
int |
containsURL(java.lang.String str)
Returns the starting position of a url in a string. |
protected void |
createPopup(java.awt.Point p)
Creates and shows the "standard" edit menu. |
void |
displayMudText(java.lang.String theLine)
Display the text to the scrollback, scanning for items to be highlighted. |
void |
displayPrvCommMsg(java.lang.String messageString)
Displays a private communication message to the current user that no one else in the room sees |
void |
displayPrvSysMsg(java.lang.String messageString)
Displays a private system message to the current user that no one else sees. |
void |
displayPrvURL(java.lang.String messageString,
java.lang.String url)
Displays a private url to the current user that no one else in the room sees. |
void |
displayPubCommMsg(java.lang.String messageString)
Displays a public communication message that everyone in the room sees. |
void |
displayPubSysMsg(java.lang.String messageString)
Displays a public system message to the current user everyone in the room sees |
void |
displayPubURL(java.lang.String messageString,
java.lang.String url)
Displays a public url that everyone in the room sees. |
void |
displayScrollbackError(java.lang.String errorString)
Displays an error to the scrollback. |
void |
displayURL(java.lang.String messageString,
java.lang.String url)
Displays a url with some additional text. |
static org.mitre.cvw.search.TextSearcher |
getCurrentSearch(RoomScrollback anInstance)
|
javax.swing.text.Style |
getCurrentStyle()
Returns the current style of the scrollback. |
javax.swing.JScrollPane |
getScrollPane()
|
javax.swing.text.Document |
getTextObject()
|
boolean |
isScrollAtBottom()
|
void |
processDoubleClick()
Processes the double clicking on a URL in the scrollback. |
void |
resetFonts()
5/7/00 dage - this is because, if the ui font is different, the document doesnt know about the new font, and therefore used the default monospaced font. |
void |
saveScrollback()
Starts the process of saving of the entire scrollback. |
void |
saveSelectedText()
Starts the process of saving of the selected text in the scrollback. |
void |
saveText(java.lang.String title,
java.lang.String text)
Saves text to a local file on users workstation. |
void |
searchAgain()
|
void |
selectAll()
Selects the whole content of the text component. |
protected void |
setCurrentStyle(javax.swing.text.Style s)
|
void |
setFixedFont(boolean b)
Sets the font to be fixed (Courier) if true is sent as parameter. |
void |
setScrollLock(boolean b)
|
void |
setScrollPane(javax.swing.JScrollPane scroll)
|
void |
setScrollToBottom()
|
private void |
setupHotKeys()
Sets up all hot keys known to this component ctrl+shift+l clear scrollback |
void |
startSearch()
|
java.lang.String |
toString()
Returns a string representation of this component and its values. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
jcvw
CVWCoordinator jcvw
myApp
RoomScrollbackClient myApp
maxLineLen
int maxLineLen
areaWidth
int areaWidth
lineCount
int lineCount
charCount
int charCount
warning
boolean warning
delete
boolean delete
pastScrollback
java.util.Vector pastScrollback
currStyle
TextStyle currStyle
scrollPane
javax.swing.JScrollPane scrollPane
scrollLock
boolean scrollLock
dragging
boolean dragging
currentSearch
private static org.mitre.cvw.search.TextSearcher currentSearch
| Constructor Detail |
RoomScrollback
public RoomScrollback(RoomScrollbackClient app)
- Constructor
RoomScrollback
public RoomScrollback(RoomScrollbackClient app, boolean b)
| Method Detail |
getCurrentSearch
public static org.mitre.cvw.search.TextSearcher getCurrentSearch(RoomScrollback anInstance)
resetFonts
public void resetFonts()
- 5/7/00 dage - this is because, if the ui font is different,
the document doesnt know about the new font, and therefore used the
default monospaced font.
this bug is not in JTextArea which is the mudEntry and tjt.Notepad
setupHotKeys
private void setupHotKeys()
- Sets up all hot keys known to this component
ctrl+shift+l clear scrollback
addMinimizeButton
public void addMinimizeButton(javax.swing.JButton btn)
getScrollPane
public javax.swing.JScrollPane getScrollPane()
setScrollPane
public void setScrollPane(javax.swing.JScrollPane scroll)
setScrollLock
public void setScrollLock(boolean b)
isScrollAtBottom
public boolean isScrollAtBottom()
setScrollToBottom
public void setScrollToBottom()
selectAll
public void selectAll()
- Description copied from class:
javax.swing.text.JTextComponent - Selects the whole content of the text component.
searchAgain
public void searchAgain()
startSearch
public void startSearch()
createPopup
protected void createPopup(java.awt.Point p)
- Creates and shows the "standard" edit menu.
append
public void append(java.lang.String str, javax.swing.text.Style style)
- Appends some text to the scrollback with a particular style. Checks for urls
within the text and bolds them.
containsURL
public int containsURL(java.lang.String str)
- Returns the starting position of a url in a string.
append
public void append(java.lang.String str, java.awt.Color color)
- Appends some text in a particular color.
append
public void append(java.lang.String str)
- Appends some text with the current style.
appendBold
public void appendBold(java.lang.String str)
- Appends some text with the current style bolded.
getTextObject
public javax.swing.text.Document getTextObject()
getCurrentStyle
public javax.swing.text.Style getCurrentStyle()
- Returns the current style of the scrollback.
setCurrentStyle
protected void setCurrentStyle(javax.swing.text.Style s)
setFixedFont
public void setFixedFont(boolean b)
- Sets the font to be fixed (Courier) if
trueis sent as parameter.
displayMudText
public void displayMudText(java.lang.String theLine)
- Display the text to the scrollback, scanning for items to be highlighted.
displayScrollbackError
public void displayScrollbackError(java.lang.String errorString)
- Displays an error to the scrollback.
displayPrvSysMsg
public void displayPrvSysMsg(java.lang.String messageString)
- Displays a private system message to the current user that no one else sees.
displayPubSysMsg
public void displayPubSysMsg(java.lang.String messageString)
- Displays a public system message to the current user everyone in the room sees
displayPubCommMsg
public void displayPubCommMsg(java.lang.String messageString)
- Displays a public communication message that everyone in the room sees.
displayPrvCommMsg
public void displayPrvCommMsg(java.lang.String messageString)
- Displays a private communication message to the current user that no one else
in the room sees
displayPrvURL
public void displayPrvURL(java.lang.String messageString, java.lang.String url)
- Displays a private url to the current user that no one else in the room sees.
displayPubURL
public void displayPubURL(java.lang.String messageString, java.lang.String url)
- Displays a public url that everyone in the room sees.
displayURL
public void displayURL(java.lang.String messageString, java.lang.String url)
- Displays a url with some additional text.
processDoubleClick
public void processDoubleClick()
- Processes the double clicking on a URL in the scrollback.
saveScrollback
public void saveScrollback()
- Starts the process of saving of the entire scrollback.
saveSelectedText
public void saveSelectedText()
- Starts the process of saving of the selected text in the scrollback.
saveText
public void saveText(java.lang.String title, java.lang.String text)
- Saves text to a local file on users workstation.
clearScrollback
public void clearScrollback()
- Clears all the text from the scrollback.
toString
public java.lang.String toString()
- Returns a string representation of this component and its values.
|
|||||||||
| Home >> All >> org >> mitre >> [ cvw overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC