public static int getFirstNonEmptyRow(BaseDocument doc, int offset, boolean downDir) throws BadLocationException { while (offset != -1 && isRowEmpty(doc, offset)) { offset = getRowStart(doc, offset, downDir ? +1 : -1); } return offset; }
public static int getFirstNonEmptyRow(BaseDocument doc, int offset, boolean downDir) throws BadLocationException { while (offset != -1 && isRowEmpty(doc, offset)) { offset = getRowStart(doc, offset, downDir ? +1 : -1); } return offset; }
if (actualPrevIndent != prevIndent) { if (!(Utilities.isRowEmpty(doc, prevOffset) || Utilities.isRowWhite(doc, prevOffset))) { indent = actualPrevIndent + (indent - prevIndent); if (indent < 0) {
selectionEnd = temp; boolean startLineIsEmpty = Utilities.isRowEmpty(doc, selectionBegin); boolean endLineIsEmpty = Utilities.isRowEmpty(doc, selectionEnd);
if (actualPrevIndent != prevIndent) { if (!(Utilities.isRowEmpty(doc, prevOffset) || Utilities.isRowWhite(doc, prevOffset))) { indent = actualPrevIndent + (indent-prevIndent);
if (!Utilities.isRowEmpty(baseDoc, offset) && !Utilities.isRowWhite(baseDoc, offset)) { break; if (Utilities.isRowEmpty(baseDoc, offset) || Utilities.isRowWhite(baseDoc, offset)) { if (!Utilities.isRowEmpty(baseDoc, offset) && !Utilities.isRowWhite(baseDoc, offset)) { break;
while (offset >= 0) { if (Utilities.isRowEmpty(doc, offset) || Utilities.isRowWhite(doc, offset)) { if (currentSectionOnly) { break; while (offset < length) { if (Utilities.isRowEmpty(doc, offset) || Utilities.isRowWhite(doc, offset)) { if (currentSectionOnly) { break;
int currentOffset = offset; while (currentOffset > 0) { if (!Utilities.isRowEmpty(doc, currentOffset) && !Utilities.isRowWhite(doc, currentOffset) && !LexUtilities.isCommentOnlyLine(doc, currentOffset)) { indent = GsfUtilities.getLineIndent(doc, currentOffset);
try { if (Utilities.isRowEmpty(doc, from)) { return;
private void comment(BaseDocument doc, int startOffset, int lineCount) throws BadLocationException { for (int offset = startOffset; lineCount > 0; lineCount--, offset = Utilities.getRowStart(doc, offset, +1)) { if (Utilities.isRowEmpty(doc, offset) || Utilities.isRowWhite(doc, offset)) { continue;
private void uncomment(BaseDocument doc, int startOffset, int lineCount) throws BadLocationException { for (int offset = startOffset; lineCount > 0; lineCount--, offset = Utilities.getRowStart(doc, offset, +1)) { if (Utilities.isRowEmpty(doc, offset) || Utilities.isRowWhite(doc, offset)) { continue;
if (Utilities.isRowEmpty(doc, next) || Utilities.isRowWhite(doc, next) || LexUtilities.isCommentOnlyLine(doc, next)) { continue;