Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.1.0)

E17493-02

oracle.ide.editor
Interface TextEditor

All Known Implementing Classes:
CodeEditor

public interface TextEditor

The text editor interface is implemented by any editor in the IDE which provides a plain text view. It provides operations which are common to plain text views.

For example, to open the default editor on a URL then jump to the fifth line of the file if the default editor is a text editor, you might use:

   Editor editor = EditorUtil.openDefaultEditorInFrame( url );
   if ( editor instanceof TextEditor )
   {
     ((TextEditor)editor).gotoLine( 5, 1, true );
   }
 

Since:
10.1.3

Method Summary
 boolean gotoLine(int line, int column, boolean highlightLine)
          Moves the current cursor position to indicated location, and optionally highlight the line.
 

Method Detail

gotoLine

boolean gotoLine(int line,
                 int column,
                 boolean highlightLine)
Moves the current cursor position to indicated location, and optionally highlight the line. If the line specified is invalid, attempts to move to the closest position and return false. The line and column offset are both one-based.

Parameters:
line - the line to go to (one-based)
column - the column to go to (one-based)
highlightLine - whether to highlight the specified line
Returns:
true if the line specified is valid

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.1.0)

E17493-02

Copyright © 1997, 2011, Oracle. All rights reserved.