IIntelliPromptSession Interface
Provides the base requirements for an object that represents an IntelliPrompt session.
public interface IIntelliPromptSession : IServiceLocator
Properties
Bounds
The view-relative bounds of the session's open popup, if available.
ClosesOnLostFocus
Indicates whether this session auto-closes when the editor or any IntelliPrompt popups lose focus.
bool ClosesOnLostFocus { get; }
Property Value
- bool:
trueif this session auto-closes when the editor or any IntelliPrompt popups lose focus; otherwise,false.
IsOpen
Indicates whether the session is currently open.
SessionType
The IIntelliPromptSessionType that identifies the type of session.
SnapshotRange
The TextSnapshotRange containing the original TextRange in the ITextSnapshot that triggered the session.
TextSnapshotRange? SnapshotRange { get; }
Property Value
Remarks
This member should only be used while the session is open.
View
The IEditorView in which the session is opened.
IEditorView? View { get; }
Property Value
Remarks
This member should only be used while the session is open.
Methods
Close(bool)
Closes the session.
void Close(bool cancelled)
| Parameter | Type | Description |
|---|---|---|
| cancelled | bool | Whether the session was closed due to a cancellation. |
Open(IEditorView, TextRange?)
Opens the session, attaching to the specified IEditorView.
void Open(IEditorView view, TextRange? textRange)
| Parameter | Type | Description |
|---|---|---|
| view | IEditorView | The IEditorView in which the session is opened. |
| textRange | TextRange? | The source TextRange in the view's current ITextSnapshot. |
Reposition()
Notifies the session that it should reposition its user interface.
void Reposition()
Events
Closed
Occurs when the session is closed, with the Cancel flag on the event arguments indicating whether
the close was due to a cancellation.
Opened
Occurs when the session is opened.
Inherited Members
- IServiceLocator.GetAllServiceTypes()
- IServiceLocator.GetService<T>()
- IServiceLocator.GetService(object)
- IServiceLocator.RegisterService<T>(T)
- IServiceLocator.RegisterService(object, object)
- IServiceLocator.UnregisterService<T>()
- IServiceLocator.UnregisterService(object)
- IServiceLocator.SyncRoot
- IServiceLocator.ServiceAdded
- IServiceLocator.ServiceRemoved