Removes leading empty lines.

@return <code>true</code> if an empty line was removed.
503902
public boolean removeLeadingEmptyLines()
    {
        boolean wasEmpty = false;
        Line line = this.lines;
        while (line != null && line.isEmpty)
        {
            this.removeLine(line);
            line = this.lines;
            wasEmpty = true;
        }
        return wasEmpty;
    }
794844
public boolean hasNext() {
		if(next != null) {
			return true;
		}
		// find lowest next:
		PeekableIterator<E> nextSource = null;
		for(int i = 0; i < components.size(); i++) {
			PeekableIterator<E> pi = components.get(i);
			if(pi.hasNext()) {
				E piNext = pi.peekNext();
				if((next == null) || (comparator.compare(next,piNext) > 0)) {
					nextSource = pi;
					next = piNext;
				}
			}
		}
		if(nextSource != null) {
			nextSource.next();
		}
		return next != null;
	}
1068730
public boolean isLineOfCode(final String line) {
        if (line.length() < getIndicatorAreaPos() + 1) {
            return false;
        }

        /* Remove white space lines */
        if (line.trim().length() == 0) {
            return false;
        }

        /* Remove comments and special lines */
        if (isComment(line)) {
            return false;
        }

        /*
         * If there is a single token on this line, make sure it is not a
         * compiler directive.
         */
        String[] tokens = line.trim().split("[\\s\\.]+");
        if (tokens.length == 1
                && COMPILER_DIRECTIVES.contains(tokens[0].toUpperCase(Locale
                        .getDefault()))) {
            return false;
        }

        return true;
    }
1202821
def __remove_leading_empty_lines(lines):
        
        tmp = list()
        empty = True
        for i in range(0, len(lines)):
            empty = empty and lines[i] == ''
            if not empty:
                tmp.append(lines[i])

        return tmp
413990
public boolean isEmpty() {
		return (content.toString().trim().length() == 0)
				&& (content.toString().indexOf("\n") == -1)
				&& (attributes == null);
	}
540904
def IsDeletedOrDefault(clean_lines, linenum):
  
  open_paren = clean_lines.elided[linenum].find('(')
  if open_paren < 0:
    return False
  (close_line, _, close_paren) = CloseExpression(
      clean_lines, linenum, open_paren)
  if close_paren < 0:
    return False
  return Match(r'\s*=\s*(?:delete|default)\b', close_line[close_paren:])
940008
def remove_empty_head_lines(text)
      return "" unless text
      lines = text.split("\n")
      header = true
      lines.delete_if{ |line|
        header = false if /\S/ =~ line
        header && /^\s*?$/ =~ line
      }
      lines.join("\n")
    end
359226
public boolean isEmpty()
    {
        if (m_filter != null)
            return false;   // Not empty
        if (m_mapNameValue != null)
            if (m_mapNameValue.size() != 0)
                return false;   // Not empty;
        return true;
    }
244633
public void removeTrailingEmptyLines()
    {
        Line line = this.lineTail;
        while (line != null && line.isEmpty)
        {
            this.removeLine(line);
            line = this.lineTail;
        }
    }
356169
public boolean supports(final String line) {
        final List<String> splits = new ArrayList<String>();
        int depth = 0;
        int textDepth = 0;
        boolean escape = false;
        StringBuffer split = new StringBuffer();
        for (char c : line.toCharArray()) {
            if (depth == 0 && c == '.') {
                splits.add(split.toString());
                split = new StringBuffer();
                depth = 0;
                textDepth = 0;
                escape = false;
                continue;
            } else if (c == '\\') {
                escape = true;
                split.append(c);
                continue;
            } else if (textDepth == 0 && c == '"') {
                textDepth++;
            } else if (!escape && textDepth > 0 && c == '"') {
                textDepth--;
            } else if (textDepth == 0 && c == '(') {
                depth++;
            } else if (textDepth == 0 && c == ')') {
                depth--;
            }
            split.append(c);
            escape = false;
        }
        splits.add(split.toString());
        return splits.size() == 2;
    }
806865
function isPreviousLineEmpty(text, node, locStart) {
  let idx = locStart(node) - 1;
  idx = skipSpaces(text, idx, { backwards: true });
  idx = skipNewline(text, idx, { backwards: true });
  idx = skipSpaces(text, idx, { backwards: true });
  const idx2 = skipNewline(text, idx, { backwards: true });
  return idx !== idx2;
}
902719
public static boolean isEmpty(String str) {
        if (str == null)
            return true;
        if ("".equals(str.trim()))
            return true;
        return str.isEmpty();
    }
77515
private static String cleanLine(String line) {
        return line.replace("/**", EMPTY_STRING).replace("/*", EMPTY_STRING)
                .replace("*", EMPTY_STRING).replace("#", EMPTY_STRING)
                .replace("/", EMPTY_STRING).replace("\\t", EMPTY_STRING)
                .replace("\\n", EMPTY_STRING).trim();
    }
497929
protected boolean isLevelLine(String line) {
        final Matcher matcher = LEVEL_PATTERN.matcher(line.trim().toUpperCase(Locale.ENGLISH));
        return matcher.find();
    }
357012
public static String removeIndentation(String rawValue) {
        String[] lines = rawValue.split("\\n");
        Integer commonIndent = null;
        for (int i = 0; i < lines.length; i++) {
            if (i == 0) continue;
            String line = lines[i];
            int length = line.length();
            int indent = leadingWhitespace(line);
            if (indent < length) {
                if (commonIndent == null || indent < commonIndent) {
                    commonIndent = indent;
                }
            }
        }
        List<String> lineList = new ArrayList<>(Arrays.asList(lines));
        if (commonIndent != null) {
            for (int i = 0; i < lineList.size(); i++) {
                String line = lineList.get(i);
                if (i == 0) continue;
                if (line.length() > commonIndent) {
                    line = line.substring(commonIndent);
                    lineList.set(i, line);
                }
            }
        }
        while (!lineList.isEmpty()) {
            String line = lineList.get(0);
            if (containsOnlyWhiteSpace(line)) {
                lineList.remove(0);
            } else {
                break;
            }
        }
        while (!lineList.isEmpty()) {
            int endIndex = lineList.size() - 1;
            String line = lineList.get(endIndex);
            if (containsOnlyWhiteSpace(line)) {
                lineList.remove(endIndex);
            } else {
                break;
            }
        }
        StringBuilder formatted = new StringBuilder();
        for (int i = 0; i < lineList.size(); i++) {
            String line = lineList.get(i);
            if (i == 0) {
                formatted.append(line);
            } else {
                formatted.append("\n");
                formatted.append(line);
            }
        }
        return formatted.toString();
    }
1160308
def delete_lines(self):
        

        cursor = self.textCursor()
        self.__select_text_under_cursor_blocks(cursor)
        cursor.removeSelectedText()
        cursor.deleteChar()
        return True
325112
public boolean isLastHeaderLine(String line) {
        return lastLineDetectionPattern != null && line != null && lastLineDetectionPattern.matcher(line).matches();
    }