groovy.ui.text
Class FindReplaceUtility
java.lang.Object
groovy.ui.text.FindReplaceUtility
public final class FindReplaceUtility
- extends java.lang.Object
- Author:
- Evan "Hippy" Slatis
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
FIND_ACTION_COMMAND
public static final java.lang.String FIND_ACTION_COMMAND
- See Also:
- Constant Field Values
REPLACE_ACTION_COMMAND
public static final java.lang.String REPLACE_ACTION_COMMAND
- See Also:
- Constant Field Values
REPLACE_ALL_ACTION_COMMAND
public static final java.lang.String REPLACE_ALL_ACTION_COMMAND
- See Also:
- Constant Field Values
CLOSE_ACTION_COMMAND
public static final java.lang.String CLOSE_ACTION_COMMAND
- See Also:
- Constant Field Values
FIND_ACTION
public static final javax.swing.Action FIND_ACTION
FIND_REPLACE_DIALOG
private static final javax.swing.JDialog FIND_REPLACE_DIALOG
TEXT_FIELD_PANEL
private static final javax.swing.JPanel TEXT_FIELD_PANEL
ENTRY_PANEL
private static final javax.swing.JPanel ENTRY_PANEL
FIND_PANEL
private static final javax.swing.JPanel FIND_PANEL
FIND_LABEL
private static final javax.swing.JLabel FIND_LABEL
FIND_FIELD
private static final javax.swing.JComboBox FIND_FIELD
REPLACE_PANEL
private static final javax.swing.JPanel REPLACE_PANEL
REPLACE_LABEL
private static final javax.swing.JLabel REPLACE_LABEL
REPLACE_FIELD
private static final javax.swing.JComboBox REPLACE_FIELD
BUTTON_PANEL
private static final javax.swing.JPanel BUTTON_PANEL
FIND_BUTTON
private static final javax.swing.JButton FIND_BUTTON
REPLACE_BUTTON
private static final javax.swing.JButton REPLACE_BUTTON
REPLACE_ALL_BUTTON
private static final javax.swing.JButton REPLACE_ALL_BUTTON
CLOSE_BUTTON
private static final javax.swing.JButton CLOSE_BUTTON
CLOSE_ACTION
private static final javax.swing.Action CLOSE_ACTION
REPLACE_ACTION
private static final javax.swing.Action REPLACE_ACTION
CHECK_BOX_PANEL
private static final javax.swing.JPanel CHECK_BOX_PANEL
MATCH_CASE_CHECKBOX
private static final javax.swing.JCheckBox MATCH_CASE_CHECKBOX
IS_BACKWARDS_CHECKBOX
private static final javax.swing.JCheckBox IS_BACKWARDS_CHECKBOX
WRAP_SEARCH_CHECKBOX
private static final javax.swing.JCheckBox WRAP_SEARCH_CHECKBOX
textComponent
private static javax.swing.text.JTextComponent textComponent
attributeSet
private static javax.swing.text.AttributeSet attributeSet
findReplaceCount
private static int findReplaceCount
lastAction
private static java.lang.String lastAction
EVENT_LISTENER_LIST
private static final javax.swing.event.EventListenerList EVENT_LISTENER_LIST
SEGMENT
private static final javax.swing.text.Segment SEGMENT
TEXT_FOCUS_LISTENER
private static final java.awt.event.FocusAdapter TEXT_FOCUS_LISTENER
FindReplaceUtility
private FindReplaceUtility()
addTextListener
public static void addTextListener(java.awt.event.TextListener tl)
fireTextEvent
private static void fireTextEvent()
getLastAction
public static java.lang.String getLastAction()
- Returns:
- the last action
getReplacementCount
public static int getReplacementCount()
- Returns:
- the replacement count
getSearchText
public static java.lang.String getSearchText()
- Returns:
- the search text
registerTextComponent
public static void registerTextComponent(javax.swing.text.JTextComponent textComponent)
- Parameters:
textComponent
- the text component to listen to
removeTextListener
public static void removeTextListener(java.awt.event.TextListener tl)
findNext
private static int findNext(boolean reverse,
int pos)
- Find and select the next searchable matching text.
- Parameters:
reverse
- look forwards or backwardspos
- the starting index to start finding from
- Returns:
- the location of the next selected, or -1 if not found
setListStrings
private static void setListStrings()
showDialog
public static void showDialog()
showDialog
public static void showDialog(boolean isReplace)
- Parameters:
isReplace
- show a replace dialog rather than a find dialog if true
unregisterTextComponent
public static void unregisterTextComponent(javax.swing.text.JTextComponent textComponent)
- Parameters:
textComponent
- the text component to stop listening to
dispose
public static void dispose()
Copyright © ${year} The Codehaus. All Rights Reserved.