Smrt.UI¶
Assembly:
Smrt.UI
Namespace: Smrt.UI¶
UiAssemblyMarker¶
Assembly marker used by dependency injection scans to locate Smrt.UI resources.
Namespace: Smrt.UI.Controls¶
SmrtSearchBox¶
Reusable search box control (UI only). Hosts a text input with a search icon. Intended for use in title bars, settings panels, and other surfaces.
Events¶
QuerySubmitted¶
Occurs when the user submits a query (for example, by pressing Enter).
QueryTextChanged¶
Occurs when the query text changes.
Fields¶
PlaceholderTextProperty¶
Identifies the Smrt.UI.Controls.SmrtSearchBox.PlaceholderText dependency property.
TextProperty¶
Identifies the Smrt.UI.Controls.SmrtSearchBox.Text dependency property.
Methods¶
FocusInput()¶
Focuses the internal text input and selects all text.
InitializeComponent()¶
InitializeComponent()
SmrtSearchBox()¶
Initializes a new instance of the Smrt.UI.Controls.SmrtSearchBox control.
Propertys¶
PlaceholderText¶
Gets or sets the placeholder text shown when the search box is empty.
Text¶
Gets or sets the current search text.
SmrtSearchBoxQuerySubmittedEventArgs¶
Event payload for Smrt.UI.Controls.SmrtSearchBox.QuerySubmitted.
Methods¶
SmrtSearchBoxQuerySubmittedEventArgs(string queryText)¶
Initializes a new instance of the Smrt.UI.Controls.SmrtSearchBoxQuerySubmittedEventArgs class.
Parameters
queryText— Submitted query text.
Propertys¶
QueryText¶
Gets the query text submitted by the user.
Namespace: Smrt.UI.Services¶
BusyState¶
Shared busy state for indeterminate UI indicators.
Remarks
Supports nested Smrt.UI.Services.BusyState.Begin(System.String) calls and enforces a minimum visible duration to avoid flashing.
This type is UI-binding friendly (System.ComponentModel.INotifyPropertyChanged) and can optionally marshal
updates onto a WinUI Microsoft.UI.Dispatching.DispatcherQueue.
Events¶
PropertyChanged¶
No summary provided.
Methods¶
AttachDispatcherQueue(Microsoft.UI.Dispatching.DispatcherQueue param0)¶
Associates a dispatcher queue for marshaling property changes.
Begin(string message)¶
Begins a busy scope.
Parameters
message— Optional busy reason shown via tooltip or diagnostics UI.
Returns: An System.IDisposable that ends the busy scope.
BusyState(Func delayAsync)¶
Creates a new busy state.
Parameters
delayAsync— Optional delay implementation (primarily for tests). When omitted, usesSystem.Threading.Tasks.Task.Delay(System.TimeSpan,System.Threading.CancellationToken).
End()¶
Ends one busy scope.
Propertys¶
IsBusy¶
True when at least one operation is marked busy.
Message¶
Optional human-readable busy reason (best-effort).
MinimumShowTime¶
Minimum time the busy indicator remains visible once shown.
ShowError¶
True when UI should display an error indicator.
ShowPaused¶
True when UI should display a paused indicator.
VisualState¶
Visual state for UI indicators.
BusyVisualState¶
Visual state for a busy indicator.
Fields¶
Error¶
Error state (UI may show system error visuals).
Paused¶
Paused state (UI may show system paused visuals).
Running¶
Normal busy/running state.
IThemeService¶
Exposes a platform-agnostic contract for selecting and enumerating SmrtHub UI themes. Consumers retrieve resource dictionary URIs and apply them to their WinUI application layer.
Events¶
ThemeChanged¶
Raised after Smrt.UI.Services.IThemeService.TrySetTheme(System.String) successfully applies a new theme.
Remarks
Event arguments publish both the previous theme and the newly applied theme.
Methods¶
GetAvailableThemes()¶
Returns all available theme names, normalized for display.
Returns: Collection of logical theme identifiers (case-insensitive).
GetCurrentThemeResourceUris()¶
Gets the resource dictionary URIs that should be merged for the current theme.
Returns: Ordered list of pack URIs that the caller merges into Application.Resources.
TrySetTheme(string themeName)¶
Attempts to switch to the provided theme name.
Parameters
themeName— Logical theme identifier supplied by the caller.
Returns: when the theme exists and is applied; otherwise .
Propertys¶
CurrentTheme¶
Logical name of the current theme (for example, Light, Dark, or HighContrast).
ThemeService¶
Registry-backed implementation that maps logical theme names to ResourceDictionary pack URIs.
Does not directly edit Application.Resources; consumers merge the returned URIs in their UI layer.
Events¶
ThemeChanged¶
No summary provided.
Methods¶
GetAvailableThemes()¶
No summary provided.
GetCurrentThemeResourceUris()¶
No summary provided.
ThemeService()¶
Initializes the theme registry with the canonical light, dark, and high contrast palettes.
TrySetTheme(string param0)¶
No summary provided.
Propertys¶
CurrentTheme¶
Gets the logical name of the currently active theme.
ThemeUris¶
Canonical source of ResourceDictionary pack URIs used by shared SmrtHub themes. Consolidating the URIs here prevents duplication and keeps renames manageable.
Fields¶
BaseTokens¶
Base token dictionary that every theme composes.
ControlsButtons¶
Shared control styles (buttons, toggles, etc) dictionary URI.
DarkThemeKey¶
Logical key for the dark theme.
HighContrastThemeKey¶
Logical key for the high contrast theme.
LightThemeKey¶
Logical key for the light theme.
PaletteDark¶
Dark palette resource dictionary URI.
PaletteHighContrast¶
High contrast palette resource dictionary URI.
PaletteLight¶
Light palette resource dictionary URI.
Typography¶
Shared typography dictionary URI.
Methods¶
ForTheme(string logicalTheme)¶
Returns the ordered list of ResourceDictionary URIs that compose the requested theme. Includes base tokens, palette-specific resources, and shared typography.
Parameters
logicalTheme— Logical theme key supplied by the caller.
Returns: Read-only, ordered sequence of pack URIs for the theme.