ParameterInfoSession Class
Represents an IntelliPrompt parameter info session.
public class ParameterInfoSession : IntelliPromptSessionBase, IParameterInfoSession, IIntelliPromptSession, IServiceLocator, IEditorViewKeyInputEventSink, IEditorViewPointerInputEventSink, IEditorViewSelectionChangeEventSink
- Inheritance:
- object IntelliPromptSessionBase object
- Implements:
- IParameterInfoSession IIntelliPromptSession IServiceLocator IEditorViewKeyInputEventSink IEditorViewPointerInputEventSink IEditorViewSelectionChangeEventSink
Constructors
ParameterInfoSession()
Initializes an instance of the class.
public ParameterInfoSession()
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.
public override bool ClosesOnLostFocus { get; }
Property Value
- bool:
trueif this session auto-closes when the editor or any IntelliPrompt popups lose focus; otherwise,false.
Content
The content to display in the parameter info popup.
ControlKeyDownOpacity
The opacity of the popup while the control key is pressed.
public double ControlKeyDownOpacity { get; set; }
Property Value
- double:
The default value is
0.25.
Remarks
Set the value to 1.0 to prevent opacity changes when the control key is pressed.
DisplaySelectedIndex
The one-based index of the Selection.
HasSelectionChanged
Indicates whether the selection has changed since the session opened.
public bool HasSelectionChanged { get; }
Property Value
- bool:
trueif the selection has changed since the session opened; otherwise,false.
IsArrowKeySelectionEnabled
Indicates whether the up and down arrow keys can be used to change the Selection.
public bool IsArrowKeySelectionEnabled { get; set; }
Property Value
Items
The collection of ISignatureItem objects within the parameter info.
MaxWidth
The quick info popup's maximum width.
public int MaxWidth { get; set; }
Property Value
- int:
The quick info popup's maximum width, or
NaNto indicate no constraint. The default value is1000.
SelectNextCommand
The ICommand that selects the next item.
SelectPreviousCommand
The ICommand that selects the previous item.
Selection
A ISignatureItem indicating the current selection within the parameter info.
SessionType
The IIntelliPromptSessionType that identifies the type of session.
public override IIntelliPromptSessionType SessionType { get; }
Property Value
Methods
CreatePopupContent()
Creates an IntelliPromptParameterInfo that is to be displayed in a popup.
protected virtual IntelliPromptParameterInfo CreatePopupContent()
Returns
OnClosed(CancelEventArgs)
Raises the Closed event.
protected override void OnClosed(CancelEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | CancelEventArgs | The event data. |
OnOpened(EventArgs)
Raises the Opened event.
protected override void OnOpened(EventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | EventArgs | The event data. |
OnPropertyChanged(PropertyChangedEventArgs)
Raises the PropertyChanged event.
protected virtual void OnPropertyChanged(PropertyChangedEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | PropertyChangedEventArgs | The event data. |
OnPropertyChanged(string?)
Raises the PropertyChanged event.
protected void OnPropertyChanged(string? propertyName = null)
| Parameter | Type | Description |
|---|---|---|
| propertyName | string | (Optional) The name of the property that changed. |
OnSelectionChanged(EventArgs)
Raises the SelectionChanged event.
protected virtual void OnSelectionChanged(EventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | EventArgs | The event data. |
OnViewKeyDown(IEditorView, KeyEventArgs)
Occurs when a key is pressed down while focus is in the specified IEditorView.
protected virtual void OnViewKeyDown(IEditorView view, KeyEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| view | IEditorView | The IEditorView that received the event. |
| e | KeyEventArgs | The event data. |
OnViewKeyUp(IEditorView, KeyEventArgs)
Occurs when a key is released while focus is in the specified IEditorView.
protected virtual void OnViewKeyUp(IEditorView view, KeyEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| view | IEditorView | The IEditorView that received the event. |
| e | KeyEventArgs | The event data. |
OnViewPointerPressed(IEditorView, InputPointerButtonEventArgs)
Occurs when a pointer button is pressed over the specified IEditorView.
protected virtual void OnViewPointerPressed(IEditorView view, InputPointerButtonEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| view | IEditorView | The IEditorView that received the event. |
| e | InputPointerButtonEventArgs | The event data. |
OnViewSelectionChanged(IEditorView, EditorViewSelectionEventArgs)
Occurs when the selection is changed in the specified IEditorView.
protected virtual void OnViewSelectionChanged(IEditorView view, EditorViewSelectionEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| view | IEditorView | The IEditorView that received the event. |
| e | EditorViewSelectionEventArgs | The event data. |
Refresh()
Refreshes the displayed content from the selected item's content provider, and repositions the popup.
public void Refresh()
Reposition()
Notifies the session that it should reposition its user interface.
public override void Reposition()
SelectNext()
Selects the next item.
public void SelectNext()
SelectPrevious()
Selects the previous item.
public void SelectPrevious()
SetProperty<T>(ref T, T, string?)
Called from a property setter to change the backing field's value and raise PropertyChanged notification events if the new value is not equal to the current value.
protected bool SetProperty<T>(ref T field, T newValue, string? propertyName = null)
- Type Parameters:
-
T-The type of the property that changed.
| Parameter | Type | Description |
|---|---|---|
| field | T | The backing field that holds the property's value, which may be updated. |
| newValue | T | The new property value. |
| propertyName | string | (Optional) The name of the property that changed. |
Returns
- bool:
trueif the property was changed; otherwise,false.
Events
PropertyChanged
Occurs when a property value changes.
SelectionChanged
Occurs after the Selection has changed.
Inherited Members
- IntelliPromptSessionBase.GetAllServiceTypes()
- IntelliPromptSessionBase.GetService<T>()
- IntelliPromptSessionBase.GetService(object)
- IntelliPromptSessionBase.RegisterService<T>(T)
- IntelliPromptSessionBase.RegisterService(object, object)
- IntelliPromptSessionBase.UnregisterService<T>()
- IntelliPromptSessionBase.UnregisterService(object)
- IntelliPromptSessionBase.Close(bool)
- IntelliPromptSessionBase.OnServiceAdded(CollectionChangeEventArgs<object>)
- IntelliPromptSessionBase.OnServiceRemoved(CollectionChangeEventArgs<object>)
- IntelliPromptSessionBase.Open(IEditorView, TextRange?)
- IntelliPromptSessionBase.GetPopupBounds(PopupControl)
- IntelliPromptSessionBase.CanOpenForReadOnlyTextRanges
- IntelliPromptSessionBase.IsOpen
- IntelliPromptSessionBase.SnapshotRange
- IntelliPromptSessionBase.SyncRoot
- IntelliPromptSessionBase.View
- IntelliPromptSessionBase.Closed
- IntelliPromptSessionBase.Opened
- IntelliPromptSessionBase.ServiceAdded
- IntelliPromptSessionBase.ServiceRemoved
- object.GetType()
- object.MemberwiseClone()
- object.ToString()
- object.Equals(object)
- object.Equals(object, object)
- object.ReferenceEquals(object, object)
- object.GetHashCode()