Class Index | File Index

## Classes

- _global_
- Array
- Boolean
- Date
- Function
- Object
- orion.breadcrumbs.BreadCrumbs
- orion.browse.FileBrowser
- orion.browse.FileBrowserOptions
- orion.BrowseView
- orion.cm.Configuration
- orion.cm.ConfigurationAdmin
- orion.cm.ConfigurationProperties
- orion.cm.ManagedService
- orion.commandregistry.CommandRegistry
- orion.commandregistry.ParameterCollector
- orion.commands.Command
- orion.commands.CommandInvocation
- orion.commands.CommandParameter
- orion.commands.ParametersDescription
- orion.commands.URLBinding
- orion.compare.CompareCommandFactory
- orion.compare.CompareOptions
- orion.compare.CompareSyntaxHighlighter
- orion.compare.CompareView
- orion.compare.CompareViewOptions
- orion.compare.DiffProvider
- orion.compare.FileOptions
- orion.compare.rulers.CompareRuler
- orion.compare.rulers.LineNumberCompareRuler
- orion.compare.toggleableCompareView
- orion.compare.TwoWayCompareView
- orion.compareUtils
- orion.core.ContentType
- orion.core.ContentTypeRegistry
- orion.core.TypeDef
- orion.core.TypeDefProperties
- orion.core.TypeDefRegistry
- orion.Deferred
- orion.dialogs.DialogService
- orion.DiffTreeNavigator.DiffTreeNavigator
- orion.DiffTreeNavigator.inlineDiffBlockFeeder
- orion.DiffTreeNavigator.TwoWayDiffBlockFeeder
- orion.edit.Dispatcher
- orion.edit.EditorContext
- orion.editor.ActionDescription
- orion.editor.Annotation
- orion.editor.AnnotationIterator
- orion.editor.AnnotationModel
- orion.editor.AnnotationRuler
- orion.editor.AnnotationStyler
- orion.editor.AnnotationType
- orion.editor.AnnotationTypeList
- orion.editor.AsyncStyler
- orion.editor.BaseEditor
- orion.editor.BlurEvent
- orion.editor.ContentAssist
- orion.editor.ContentAssistMode
- orion.editor.ContentAssistProvider
- orion.editor.ContentAssistProvider.Context
- orion.editor.ContentAssistWidget
- orion.editor.ContextMenuEvent
- orion.editor.CssContentAssistProvider
- orion.editor.DestroyEvent
- orion.editor.EditOptions
- orion.editor.Editor
- orion.editor.EventTarget
- orion.editor.FindIterator
- orion.editor.FindOptions
- orion.editor.FocusEvent
- orion.editor.FoldingAnnotation
- orion.editor.HTMLContentAssistProvider
- orion.editor.InputManager
- orion.editor.JSTemplateContentAssistProvider
- orion.editor.KeyEvent
- orion.editor.LineNumberRuler
- orion.editor.LineStyleEvent
- orion.editor.ModelChangedEvent
- orion.editor.ModelChangingEvent
- orion.editor.ModifyEvent
- orion.editor.OverviewRuler
- orion.editor.Projection
- orion.editor.ProjectionTextModel
- orion.editor.Ruler
- orion.editor.ScrollEvent
- orion.editor.Selection
- orion.editor.SelectionEvent
- orion.editor.Style
- orion.editor.StyleRange
- orion.editor.StyleReadyEvent
- orion.editor.StyleReadyEvent#LineStyle
- orion.editor.TextChange
- orion.editor.TextMateStyler
- orion.editor.TextModel
- orion.editor.TextTheme
- orion.editor.TextView
- orion.editor.TextViewOptions
- orion.editor.ThemeChangedEvent
- orion.editor.ThemeStyleSheet
- orion.editor.UndoStack
- orion.editor.VerifyEvent
- orion.EditorView
- orion.EventTarget
- orion.explorer.Explorer
- orion.explorer.ExplorerFlatModel
- orion.explorer.ExplorerModel
- orion.explorer.FileExplorer
- orion.explorer.FileExplorer.ModelHandler
- orion.explorer.NavigatorRenderer
- orion.explorer.SelectionRenderer
- orion.explorerNavHandler.ExplorerNavDict
- orion.explorerNavHandler.ExplorerNavHandler
- orion.extensionCommands
- orion.fileClient.FileClient
- orion.fileCommands
- orion.fileUtils
- orion.FolderView
- orion.form
- orion.git.GitCommitExplorer
- orion.git.GitLogExplorer
- orion.git.GitRepositoryExplorer
- orion.git.GitReviewRequestExplorer
- orion.git.GitService
- orion.git.GitStatusExplorer
- orion.git.widgets.OpenCommitDialog
- orion.globalCommands
- orion.highlight.SyntaxHighlighter
- orion.KeyBinding
- orion.KeySequence
- orion.KeyStroke
- orion.links.TextLinkService
- orion.log.LogService
- orion.metatype.AttributeDefinition
- orion.metatype.MetaTypeRegistry
- orion.metatype.ObjectClassDefinition
- orion.mirror.CodeMirrorStyler
- orion.mirror.Mirror
- orion.mirror.MirrorLineStyle
- orion.mirror.ModeApplier
- orion.navoutliner.NavigationOutliner
- orion.objects
- orion.operation
- orion.outliner.Outliner
- orion.outliner.OutlineService
- orion.PageLinks
- orion.PageLinks.PageLinksInfo
- orion.parametercollectors.CommandParameterCollector
- orion.pluginregistry.Plugin
- orion.pluginregistry.PluginRegistry
- orion.preferences.Preferences
- orion.preferences.PreferencesService
- orion.problems.ProblemService
- orion.profile.usersClient.UsersClient
- orion.progress.ProgressService
- orion.projectClient.ProjectClient
- orion.Promise
- orion.ReadonlyEditorView
- orion.regex
- orion.search.AdvSearchOptRenderer
- orion.searchClient.Searcher
- orion.searches.SavedSearches
- orion.Searches.SearchBuilder
- orion.Searches.SearchList
- orion.searchResults.SearchResultsGenerator
- orion.searchUtils
- orion.searchUtils.SearchParams
- orion.selection.Selection
- orion.serviceregistry.ServiceEvent
- orion.serviceregistry.ServiceReference
- orion.serviceregistry.ServiceRegistration
- orion.serviceregistry.ServiceRegistry
- orion.ServiceTracker
- orion.settings.Setting
- orion.settings.SettingsRegistry
- orion.settings.ui.PropertyWidget
- orion.shell.Command
- orion.shell.Parameter
- orion.shell.ParameterType
- orion.shell.Shell
- orion.sidebar.MiniNavViewMode
- orion.sidebar.ProjectNavViewMode
- orion.sidebar.Sidebar
- orion.sidebar.ViewMode
- orion.sites.SiteClient
- orion.sites.SiteConfiguration
- orion.sites.SiteEditor
- orion.sites.SiteService
- orion.sites.ViewOnSiteTree
- orion.status.StatusReportingService
- orion.SyntaxChecker
- orion.tasks.TaskList
- orion.TreeModelIterator.TreeModelIterator
- orion.treetable.TableTree
- orion.uiUtils
- orion.URITemplate
- orion.webui.contextmenu.ContextMenu
- orion.webui.dialogs.OpenResourceDialog
- orion.webui.dialogs.OperationsDialog
- orion.webui.littlelib
- orion.webui.Splitter
- orion.widgets.browse.ResourceSelector
- orion.widgets.Filesystem.FilesystemSwitcher
- orion.widgets.Section
- orion.widgets.settings.SplitSelectionLayout
- orion.xhr
- orion.xhr.Result
- String

# Class orion.editor.Editor

Extends orion.editor.BaseEditor.
An `Editor` is a user interface for editing text that provides additional features over the basic orion.editor.TextView. Some of `Editor`'s features include:

- Additional actions and key bindings for editing text
- Content assist
- Find and Incremental Find
- Rulers for displaying line numbers and annotations
- Status reporting

Defined in: </shared/eclipse/e4/orion/I201402262325/plugins/org.eclipse.orion.client.editor/web/orion/editor/editor.js>.

Class Summary
Constructor Attributes | Constructor Name and Description
--- | ---
| orion.editor.Editor(options) Creates a new Editor with the given options.

Method Summary
Method Attributes | Method Name and Description
--- | ---
| destroy() Destroys the editor.
| focus() Gives focus to the text view.
| getAnnotationModel() Returns the annotation model of the editor.
| getAnnotationRuler() Returns the annotation ruler of the editor.
| getAnnotationStyler() Returns the annotation styler of the editor.
| getCaretOffset()
| getContentAssist() Returns the content assist of the editor.
| getFoldingRuler() Returns the folding ruler of the editor.
| getKeyModes() Returns the editor's key modes.
| getLineAtOffset(offset)
<static> | orion.editor.Editor.getLineAtOffset(offset) Returns the line number corresponding to the given offset in the source
| getLineNumberRuler() Returns the line number ruler of the editor.
| getLineStart(line)
| getLinkedMode() Returns the editor linked mode.
| getModel() Returns the base text model of this editor.
| getOverviewRuler() Returns the overview ruler of the editor.
| getSelection()
| getSourceCodeActions() Returns the editor source code actions.
| getTextActions() Returns the editor text actions.
| getTextView() Returns the underlying `TextView` used by this editor.
| install()
| installTextView() Creates the underlying TextView and installs the editor's features.
| mapOffset(offset, parent)
| onGotoLine(line, column, end, callback) Reveals a line in the editor, and optionally selects a portion of the line.
| resize() Resizes the text view.
| setAnnotationRulerVisible(visible, force) Sets whether the annotation ruler is visible.
| setCaretOffset(caretOffset, show, callback)
| setFoldingRulerVisible(visible, force) Sets whether the folding ruler is visible.
| setInput(title, message, contents, contentsSaved, noFocus) Sets the editor's contents.
| setLineNumberRulerVisible(visible, force) Sets whether the line numbering ruler is visible.
| setOverviewRulerVisible(visible, force) Sets whether the overview ruler is visible.
| setSelection(start, end, show, callback)
| setText(text, start, end)
| showAnnotations(annotations, types, createAnnotation, getType)
| showBlame(blameMarkers)
| showOccurrences(occurrences)
| showProblems(problems)
| showSelection(start, end, line, offset, length) Reveals and selects a portion of text.
| uninstall()
| uninstallTextView() Destroys the underlying TextView.

Methods borrowed from class orion.editor.BaseEditor:
  addEventListener, dispatchEvent, getText, getTitle, getUndoStack, isDirty, markClean, onChanged, onDirtyChanged, onInputChanged, removeEventListener, reportStatus, setDirty

Class Detail
orion.editor.Editor(options)
Creates a new Editor with the given options.

Parameters:
{Object} options
  Options controlling the features of this Editor.
{Object} options.annotationFactory
{Object} options.contentAssistFactory
{Object} options.domNode
{Object} options.keyBindingFactory
{Object} options.lineNumberRulerFactory
{Object} options.foldingRulerFactory
{Object} options.statusReporter
{Object} options.textViewFactory
{Object} options.undoStackFactory
{Object} options.textDNDFactory

Method Detail
destroy()
Destroys the editor.

focus()
Gives focus to the text view.

{orion.editor.AnnotationModel} getAnnotationModel()
Returns the annotation model of the editor.

Returns:
  {orion.editor.AnnotationModel}

{orion.editor.AnnotationRuler} getAnnotationRuler()
Returns the annotation ruler of the editor.

Returns:
  {orion.editor.AnnotationRuler}

{orion.editor.AnnotationStyler} getAnnotationStyler()
Returns the annotation styler of the editor.

Returns:
  {orion.editor.AnnotationStyler}

getCaretOffset()

{orion.editor.LineNumberRuler} getContentAssist()
Returns the content assist of the editor.

Returns:
  {orion.editor.LineNumberRuler}

{orion.editor.FoldingRuler} getFoldingRuler()
Returns the folding ruler of the editor.

Returns:
  {orion.editor.FoldingRuler}

{Array} getKeyModes()
Returns the editor's key modes.

Returns:
  {Array} the editor key modes.

getLineAtOffset(offset)

Parameters:
offset

<static> {Number} orion.editor.Editor.getLineAtOffset(offset)
Returns the line number corresponding to the given offset in the source

Parameters:
{Number} offset
  The offset into the source

Since:
  5.0

Returns:
  {Number} The line number corresponding to the given offset or `-1` if out of range

{orion.editor.LineNumberRuler} getLineNumberRuler()
Returns the line number ruler of the editor.

Returns:
  {orion.editor.LineNumberRuler}

getLineStart(line)

Parameters:
line

{orion.editor.LinkedMode} getLinkedMode()
Returns the editor linked mode.

Returns:
  {orion.editor.LinkedMode}

{orion.editor.TextModel} getModel()
Returns the base text model of this editor.

Returns:
  {orion.editor.TextModel}

{orion.editor.OverviewRuler} getOverviewRuler()
Returns the overview ruler of the editor.

Returns:
  {orion.editor.OverviewRuler}

getSelection()

{orion.editor.sourceCodeActions} getSourceCodeActions()
Returns the editor source code actions.

Returns:
  {orion.editor.sourceCodeActions}

{orion.editor.textActions} getTextActions()
Returns the editor text actions.

Returns:
  {orion.editor.textActions}

{orion.editor.TextView} getTextView()
Returns the underlying `TextView` used by this editor.

Returns:
  {orion.editor.TextView} the editor text view.

install()

installTextView()
Creates the underlying TextView and installs the editor's features.

mapOffset(offset, parent)

Parameters:
offset
parent

onGotoLine(line, column, end, callback)
Reveals a line in the editor, and optionally selects a portion of the line.

Parameters:
{Number} line
  - document base line index
{Number|String} column
{Number} end Optional
callback

resize()
Resizes the text view.

setAnnotationRulerVisible(visible, force)
Sets whether the annotation ruler is visible.

Parameters:
{Boolean} visible
  `true` to show ruler, `false` otherwise
force

setCaretOffset(caretOffset, show, callback)

Parameters:
caretOffset
show
callback

setFoldingRulerVisible(visible, force)
Sets whether the folding ruler is visible.

Parameters:
{Boolean} visible
  `true` to show ruler, `false` otherwise
force

setInput(title, message, contents, contentsSaved, noFocus)
Sets the editor's contents.

Parameters:
{String} title
{String} message
{String} contents
{Boolean} contentsSaved
{Boolean} noFocus

setLineNumberRulerVisible(visible, force)
Sets whether the line numbering ruler is visible.

Parameters:
{Boolean} visible
  `true` to show ruler, `false` otherwise
force

setOverviewRulerVisible(visible, force)
Sets whether the overview ruler is visible.

Parameters:
{Boolean} visible
  `true` to show ruler, `false` otherwise
force

setSelection(start, end, show, callback)

Parameters:
start
end
show
callback

setText(text, start, end)

Parameters:
text
start
end

showAnnotations(annotations, types, createAnnotation, getType)

Parameters:
annotations
types
createAnnotation
getType

showBlame(blameMarkers)

Parameters:
blameMarkers

showOccurrences(occurrences)

Parameters:
occurrences

showProblems(problems)

Parameters:
problems

showSelection(start, end, line, offset, length)
Reveals and selects a portion of text.

Parameters:
{Number} start
{Number} end
{Number} line
{Number} offset
{Number} length

uninstall()

uninstallTextView()
Destroys the underlying TextView.

Documentation generated by JsDoc Toolkit 2.4.0 on Wed Feb 26 2014 23:28:25 GMT-0500 (EST)