|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--javax.swing.text.View
|
+--javax.swing.text.PlainView
|
+--kawigi.editor.GenericView
Ok, this is me just glorifying myself a little bit.
| Field Summary | |
protected static java.lang.Object |
highlightKey1
|
protected static java.lang.Object |
highlightKey2
|
protected int |
lineIndex
Set parseIndex to 0 and lineIndex to 1 before calling findIntervals. |
protected int |
parseIndex
Set parseIndex to 0 and lineIndex to 1 before calling findIntervals. |
| Fields inherited from class javax.swing.text.PlainView |
metrics |
| Fields inherited from class javax.swing.text.View |
BadBreakWeight, ExcellentBreakWeight, ForcedBreakWeight, GoodBreakWeight, X_AXIS, Y_AXIS |
| Fields inherited from interface javax.swing.SwingConstants |
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST |
| Constructor Summary | |
GenericView(javax.swing.text.Element e)
Just forwards that Element on down. |
|
| Method Summary | |
protected void |
findIntervals(java.util.ArrayList list,
java.lang.String text,
java.lang.String[] startEnd,
boolean block)
Helper function to help with getIntervals. |
protected kawigi.editor.Interval |
findName(java.lang.String text,
int index,
int startline,
int endline,
int endindex,
java.lang.String[] startEnd,
boolean block)
Searches for a String identifier for a block in the text before the block May or may not be particularly useful in many situations. |
java.util.ArrayList |
getIntervals()
Returns an ArrayList of Interval objects representing code block intervals
in the document. |
protected int |
getTabSize()
Programmers don't like 8-space tabstops. |
void |
paint(java.awt.Graphics g,
java.awt.Shape a)
A little hack to put a "TopCoder-ish" logo and a copycat logo for KawigiEdit in the background of the text pane. |
static void |
resetTabStop()
Checks the property kawigi.editor.tabstop and sets the tabstop used in GenericView and derivatives to its value. |
protected void |
updateDamage(javax.swing.event.DocumentEvent changes,
java.awt.Shape a,
javax.swing.text.ViewFactory f)
NOTHING BUT A HACK (and a weird, dirty one at that). |
| Methods inherited from class javax.swing.text.PlainView |
changedUpdate, damageLineRange, drawLine, drawSelectedText, drawUnselectedText, getLineBuffer, getPreferredSpan, insertUpdate, lineToRect, modelToView, nextTabStop, removeUpdate, setSize, updateMetrics, viewToModel |
| Methods inherited from class javax.swing.text.View |
append, breakView, createFragment, forwardUpdate, forwardUpdateToView, getAlignment, getAttributes, getBreakWeight, getChildAllocation, getContainer, getDocument, getElement, getEndOffset, getGraphics, getMaximumSpan, getMinimumSpan, getNextVisualPositionFrom, getParent, getResizeWeight, getStartOffset, getToolTipText, getView, getViewCount, getViewFactory, getViewIndex, getViewIndex, insert, isVisible, modelToView, modelToView, preferenceChanged, remove, removeAll, replace, setParent, updateChildren, updateLayout, viewToModel |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected static java.lang.Object highlightKey1
protected static java.lang.Object highlightKey2
protected int parseIndex
protected int lineIndex
| Constructor Detail |
public GenericView(javax.swing.text.Element e)
| Method Detail |
public static void resetTabStop()
public void paint(java.awt.Graphics g,
java.awt.Shape a)
paint in class javax.swing.text.PlainViewprotected int getTabSize()
getTabSize in class javax.swing.text.PlainViewpublic java.util.ArrayList getIntervals()
ArrayList of Interval objects representing code block intervals
in the document.
This default implementation matches curly braces, square brackets and parentheses.
protected void findIntervals(java.util.ArrayList list,
java.lang.String text,
java.lang.String[] startEnd,
boolean block)
getIntervals.
Puts the intervals into the list in an in-order traversal of curly braces.
protected kawigi.editor.Interval findName(java.lang.String text,
int index,
int startline,
int endline,
int endindex,
java.lang.String[] startEnd,
boolean block)
protected void updateDamage(javax.swing.event.DocumentEvent changes,
java.awt.Shape a,
javax.swing.text.ViewFactory f)
updateDamage in class javax.swing.text.PlainView
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||