C# Class Microsoft.Markdown.Editor.ContainedLanguage.MdContainedLanguageHost

Host for contained (embedded) language editors such as R editor inside ``` code ``` blocks in R Markdown.
Inheritance: IContainedLanguageHost
Afficher le fichier Open project: Microsoft/RTVS Class Usage Examples

Méthodes publiques

Méthode Description
CanFormatLine ( ITextView textView, ITextBuffer containedLanguageBuffer, int lineNumber ) : bool
IsInertRange ( ITextRange range ) : bool

Detemines if particular range should not be treated as contained language and instead should be ignored or 'skipped over'. Used by R parser to ignore 'R' in ```{R ... }

MdContainedLanguageHost ( IEditorDocument document, ITextBuffer textBuffer, ICoreShell coreShell ) : System

Creates contained language host with default settings.

RemoveContainedCommandTarget ( ITextView textView ) : void
SetContainedCommandTarget ( ITextView textView, ICommandTarget containedCommandTarget ) : ICommandTarget

Private Methods

Méthode Description
GetBaseCommandTarget ( ITextView textView ) : ICommandTarget

Retrieves base command target that is chained to the main controller attached to a given view. This is typically a core editor command target.

OnDocumentClosing ( object sender, EventArgs e ) : void

Method Details

CanFormatLine() public méthode

public CanFormatLine ( ITextView textView, ITextBuffer containedLanguageBuffer, int lineNumber ) : bool
textView ITextView
containedLanguageBuffer ITextBuffer
lineNumber int
Résultat bool

IsInertRange() public méthode

Detemines if particular range should not be treated as contained language and instead should be ignored or 'skipped over'. Used by R parser to ignore 'R' in ```{R ... }
public IsInertRange ( ITextRange range ) : bool
range ITextRange
Résultat bool

MdContainedLanguageHost() public méthode

Creates contained language host with default settings.
public MdContainedLanguageHost ( IEditorDocument document, ITextBuffer textBuffer, ICoreShell coreShell ) : System
document IEditorDocument Markdown editor document
textBuffer ITextBuffer Contained language text buffer
coreShell ICoreShell
Résultat System

RemoveContainedCommandTarget() public méthode

public RemoveContainedCommandTarget ( ITextView textView ) : void
textView ITextView
Résultat void

SetContainedCommandTarget() public méthode

public SetContainedCommandTarget ( ITextView textView, ICommandTarget containedCommandTarget ) : ICommandTarget
textView ITextView
containedCommandTarget ICommandTarget
Résultat ICommandTarget