| 78 | 78 | // paragraph, instead. |
| 79 | 79 | if( text.isBlank() ) { |
| 80 | | paraId++; |
| 80 | final var paragraphs = editor.getParagraphs().size(); |
| 81 | |
| 82 | paraId = Math.min( paraId + 1, paragraphs - 1 ); |
| 81 | 83 | paragraph = editor.getParagraph( paraId ); |
| 82 | 84 | text = paragraph.getText(); |
| ... |
| 94 | 96 | * @param editor The document (or portions thereof) to spellcheck. |
| 95 | 97 | * @param text Look up words for this text in the lexicon. |
| 96 | | * @param paraId Set to -1 to apply resulting style spans to the entire |
| 97 | | * text. |
| 98 | * @param paraId Set to -1 to apply resulting style spans to the entire text. |
| 98 | 99 | */ |
| 99 | 100 | private void spellcheck( |