Lines Matching defs:line
128 int lineCmp = start2.line - start1.line;
140 String line = lines.get(endTagPosition.line);
141 String newLine = line.substring(0, endTagPosition.charIndex) + " " + tag +
142 line.substring(endTagPosition.charIndex);
143 lines.set(endTagPosition.line, newLine);
245 if (start.line != end.line) {
246 String startLine = lines.get(start.line);
248 lines.set(start.line, newStartLine);
249 for (int i = start.line + 1; i < end.line; i++) {
250 String line = lines.get(i);
251 lines.set(i, replaceWithSpaces(line, 0, line.length() - 1));
253 String endLine = lines.get(end.line);
255 lines.set(end.line, newEndLine);
258 String line = lines.get(start.line);
260 String replacedText = replaceRange(line, start.charIndex, endTextIndex, text);
262 lines.set(start.line, spacedText);
265 String line = lines.get(start.line);
266 String newLine = replaceWithSpaces(line, start.charIndex, end.charIndex - 1);
267 lines.set(start.line, newLine);
272 private static String replaceRange(String line, int start, int end, String newText) {
273 return line.substring(0, start) + newText + line.substring(end);
388 index = lines.get(startPosition.line).lastIndexOf("</");
389 startPosition.line--;
391 startPosition.line++;
397 private static String replaceWithSpaces(String line, int start, int end) {
398 StringBuilder lineBuilder = new StringBuilder(line);
406 String line = lines.get(pos.line);
407 while (pos.charIndex > line.length()) {
414 int line;
417 public Position(int line, int charIndex) {
418 this.line = line;