/** */ private void updateStateAfterNotFound() { lastFoundIndex = -1; lastMatchResult = null; lastRegEx = null; setCaretPosition(getSelectionEnd()); }
/** */ private void updateStateAfterNotFound() { lastFoundIndex = -1; lastMatchResult = null; lastRegEx = null; setCaretPosition(getSelectionEnd()); }
/** */ private void updateStateAfterNotFound() { lastFoundIndex = -1; lastMatchResult = null; lastRegEx = null; setCaretPosition(getSelectionEnd()); }
/** */ private void updateStateAfterNotFound() { lastFoundIndex = -1; lastMatchResult = null; lastRegEx = null; setCaretPosition(getSelectionEnd()); }
/** */ private void updateStateAfterNotFound() { lastFoundIndex = -1; lastMatchResult = null; lastRegEx = null; setCaretPosition(getSelectionEnd()); }
boolean selectedText = getSelectionEnd() - getSelectionStart() > 0; if (ACTION_CUT.equals(name)) {
boolean selectedText = getSelectionEnd() - getSelectionStart() > 0; if (ACTION_CUT.equals(name)) {
boolean selectedText = getSelectionEnd() - getSelectionStart() > 0; if (ACTION_CUT.equals(name)) {
boolean selectedText = getSelectionEnd() - getSelectionStart() > 0; if (ACTION_CUT.equals(name)) {
boolean selectedText = getSelectionEnd() - getSelectionStart() > 0; if (ACTION_CUT.equals(name)) {
/** * Applys the tag to the current selection */ protected void applyTag(HTML.Tag tag) { Document doc = getDocument(); if (!(doc instanceof HTMLDocument)) { return; } HTMLDocument hdoc = (HTMLDocument)doc; int start = getSelectionStart(); int end = getSelectionEnd(); Element element = hdoc.getParagraphElement(start); MutableAttributeSet newAttrs = new SimpleAttributeSet(element.getAttributes()); newAttrs.addAttribute(StyleConstants.NameAttribute, tag); hdoc.setParagraphAttributes(start, end - start, newAttrs, true); }
/** * Applys the tag to the current selection */ protected void applyTag(HTML.Tag tag) { Document doc = getDocument(); if (!(doc instanceof HTMLDocument)) { return; } HTMLDocument hdoc = (HTMLDocument)doc; int start = getSelectionStart(); int end = getSelectionEnd(); Element element = hdoc.getParagraphElement(start); MutableAttributeSet newAttrs = new SimpleAttributeSet(element.getAttributes()); newAttrs.addAttribute(StyleConstants.NameAttribute, tag); hdoc.setParagraphAttributes(start, end - start, newAttrs, true); }
/** * Applys the tag to the current selection */ protected void applyTag(HTML.Tag tag) { Document doc = getDocument(); if (!(doc instanceof HTMLDocument)) { return; } HTMLDocument hdoc = (HTMLDocument)doc; int start = getSelectionStart(); int end = getSelectionEnd(); Element element = hdoc.getParagraphElement(start); MutableAttributeSet newAttrs = new SimpleAttributeSet(element.getAttributes()); newAttrs.addAttribute(StyleConstants.NameAttribute, tag); hdoc.setParagraphAttributes(start, end - start, newAttrs, true); }
/** * Applys the tag to the current selection */ protected void applyTag(HTML.Tag tag) { Document doc = getDocument(); if (!(doc instanceof HTMLDocument)) { return; } HTMLDocument hdoc = (HTMLDocument)doc; int start = getSelectionStart(); int end = getSelectionEnd(); Element element = hdoc.getParagraphElement(start); MutableAttributeSet newAttrs = new SimpleAttributeSet(element.getAttributes()); newAttrs.addAttribute(StyleConstants.NameAttribute, tag); hdoc.setParagraphAttributes(start, end - start, newAttrs, true); }
/** * Applys the tag to the current selection */ protected void applyTag(HTML.Tag tag) { Document doc = getDocument(); if (!(doc instanceof HTMLDocument)) { return; } HTMLDocument hdoc = (HTMLDocument)doc; int start = getSelectionStart(); int end = getSelectionEnd(); Element element = hdoc.getParagraphElement(start); MutableAttributeSet newAttrs = new SimpleAttributeSet(element.getAttributes()); newAttrs.addAttribute(StyleConstants.NameAttribute, tag); hdoc.setParagraphAttributes(start, end - start, newAttrs, true); }