fun actionPerformed(e: java.awt.event.ActionEvent?) { val target: javax.swing.text.JTextComponent = getTextComponent(e) if (target != null && e != null) { if (!target.isEditable() || !target.isEnabled()) { javax.swing.UIManager.getLookAndFeel().provideErrorFeedback(target) return } var content: String = target.getText() if (content != null && target.getSelectionStart() > 0) { content = content.substring(0, target.getSelectionStart()) } if (content != null) { target.setText(getNextMatch(content)) adaptor.markText(content.length) } } }
Shows the next match .