Class SingleFontChooserDialog
A dialog for choosing a font and its size.
Assembly: Dalamud.dll
View Source
public sealed class SingleFontChooserDialog : IDisposable
Implements:
System.IDisposable
Properties
Title
Gets or sets the title of this font chooser dialog popup.
View Source
public string Title { get; set; }
PreviewText
Gets or sets the preview text. A text too long may be truncated on assignment.
View Source
public string PreviewText { get; set; }
ResultTask
Gets the task that resolves upon choosing a font or cancellation.
View Source
public Task<SingleFontSpec> ResultTask { get; }
SelectedFont
Gets or sets the selected family and font.
View Source
public SingleFontSpec SelectedFont { get; set; }
FontFamilyExcludeFilter
Gets or sets the font family exclusion filter predicate.
View Source
public Predicate<IFontFamilyId>? FontFamilyExcludeFilter { get; set; }
IgnorePreviewGlobalScale
Gets or sets a value indicating whether to ignore the global scale on preview text input.
View Source
public bool IgnorePreviewGlobalScale { get; set; }
IsModal
Gets or sets a value indicating whether this popup should be modal, blocking everything behind from being interacted.
View Source
public bool IsModal { get; set; }
WindowFlags
Gets or sets the window flags.
View Source
public ImGuiWindowFlags WindowFlags { get; set; }
PopupPosition
Gets or sets the popup window position.
View Source
public Vector2 PopupPosition { get; set; }
PopupSize
Gets or sets the popup window size.
View Source
public Vector2 PopupSize { get; set; }
Methods
CreateAuto(UiBuilder)
Creates a new instance of Dalamud.Interface.ImGuiFontChooserDialog.SingleFontChooserDialog that will automatically draw and dispose itself as needed; calling Dalamud.Interface.ImGuiFontChooserDialog.SingleFontChooserDialog.Draw() and Dalamud.Interface.ImGuiFontChooserDialog.SingleFontChooserDialog.Dispose() are handled automatically.
View Source
public static SingleFontChooserDialog CreateAuto(UiBuilder uiBuilder)
Returns
Dalamud.Interface.ImGuiFontChooserDialog.SingleFontChooserDialog: The new instance of Dalamud.Interface.ImGuiFontChooserDialog.SingleFontChooserDialog.
Parameters
Type | Name | Description |
---|---|---|
Dalamud.Interface.UiBuilder | uiBuilder | An instance of Dalamud.Interface.UiBuilder. |
GetDefaultPopupSizeNonClamped()
Gets the default popup size before clamping to monitor work area.
View Source
public static Vector2 GetDefaultPopupSizeNonClamped()
Returns
System.Numerics.Vector2
: The default popup size.
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
View Source
public void Dispose()
Cancel()
Cancels this dialog.
View Source
public void Cancel()
SetPopupPositionAndSizeToCurrentWindowCenter(Vector2)
Sets Dalamud.Interface.ImGuiFontChooserDialog.SingleFontChooserDialog.PopupSize and Dalamud.Interface.ImGuiFontChooserDialog.SingleFontChooserDialog.PopupPosition to be at the center of the current window being drawn.
View Source
public void SetPopupPositionAndSizeToCurrentWindowCenter(Vector2 preferredPopupSize)
Parameters
Type | Name | Description |
---|---|---|
System.Numerics.Vector2 | preferredPopupSize | The preferred popup size. |
SetPopupPositionAndSizeToCurrentWindowCenter()
Sets Dalamud.Interface.ImGuiFontChooserDialog.SingleFontChooserDialog.PopupSize and Dalamud.Interface.ImGuiFontChooserDialog.SingleFontChooserDialog.PopupPosition to be at the center of the current window being drawn.
View Source
public void SetPopupPositionAndSizeToCurrentWindowCenter()