語言

SearchHandler 類別

定義

提供應用程式中的 Shell 搜尋功能。

public ref class SearchHandler : Microsoft::Maui::Controls::BindableObject, Microsoft::Maui::Controls::Internals::IFontElement, Microsoft::Maui::Controls::ISearchHandlerController, Microsoft::Maui::Controls::ITextAlignmentElement, Microsoft::Maui::Controls::ITextElement
public ref class SearchHandler : Microsoft::Maui::Controls::BindableObject, Microsoft::Maui::Controls::Internals::IFontElement, Microsoft::Maui::Controls::ISearchHandlerController
public class SearchHandler : Microsoft.Maui.Controls.BindableObject, Microsoft.Maui.Controls.Internals.IFontElement, Microsoft.Maui.Controls.ISearchHandlerController, Microsoft.Maui.Controls.ITextAlignmentElement, Microsoft.Maui.Controls.ITextElement
public class SearchHandler : Microsoft.Maui.Controls.BindableObject, Microsoft.Maui.Controls.Internals.IFontElement, Microsoft.Maui.Controls.ISearchHandlerController
type SearchHandler = class
    inherit BindableObject
    interface ISearchHandlerController
    interface IFontElement
    interface ITextElement
    interface ITextAlignmentElement
type SearchHandler = class
    inherit BindableObject
    interface ISearchHandlerController
    interface IFontElement
Public Class SearchHandler
Inherits BindableObject
Implements IFontElement, ISearchHandlerController, ITextAlignmentElement, ITextElement
Public Class SearchHandler
Inherits BindableObject
Implements IFontElement, ISearchHandlerController
繼承
SearchHandler
實作

建構函式

名稱 Description
SearchHandler()

提供應用程式中的 Shell 搜尋功能。

欄位

名稱 Description
AutomationIdProperty

的 AutomationIdBindable 屬性。

BackgroundColorProperty

的 BackgroundColorBindable 屬性。

CancelButtonColorProperty

的 CancelButtonColorBindable 屬性。

CharacterSpacingProperty

的 CharacterSpacingBindable 屬性。

ClearIconHelpTextProperty

的 ClearIconHelpTextBindable 屬性。

ClearIconNameProperty

的 ClearIconNameBindable 屬性。

ClearIconProperty

的 ClearIconBindable 屬性。

ClearPlaceholderCommandParameterProperty

的 ClearPlaceholderCommandParameterBindable 屬性。

ClearPlaceholderCommandProperty

的 ClearPlaceholderCommandBindable 屬性。

ClearPlaceholderEnabledProperty

的 ClearPlaceholderEnabledBindable 屬性。

ClearPlaceholderHelpTextProperty

的 ClearPlaceholderHelpTextBindable 屬性。

ClearPlaceholderIconProperty

的 ClearPlaceholderIconBindable 屬性。

ClearPlaceholderNameProperty

的 ClearPlaceholderNameBindable 屬性。

CommandParameterProperty

的 CommandParameterBindable 屬性。

CommandProperty

的 CommandBindable 屬性。

DisplayMemberNameProperty

的 DisplayMemberNameBindable 屬性。

FontAttributesProperty

的 FontAttributesBindable 屬性。

FontAutoScalingEnabledProperty

的 FontAutoScalingEnabledBindable 屬性。

FontFamilyProperty

的 FontFamilyBindable 屬性。

FontSizeProperty

的 FontSizeBindable 屬性。

HorizontalTextAlignmentProperty

的 HorizontalTextAlignmentBindable 屬性。

IsFocusedProperty

的 IsFocusedBindable 屬性。

IsFocusedPropertyKey

可綁定的屬性鍵。IsFocused

IsSearchEnabledProperty

的 IsSearchEnabledBindable 屬性。

ItemsSourceProperty

的 ItemsSourceBindable 屬性。

ItemTemplateProperty

的 ItemTemplateBindable 屬性。

KeyboardProperty

的 KeyboardBindable 屬性。

PlaceholderColorProperty

的 PlaceholderColorBindable 屬性。

PlaceholderProperty

的 PlaceholderBindable 屬性。

QueryIconHelpTextProperty

的 QueryIconHelpTextBindable 屬性。

QueryIconNameProperty

的 QueryIconNameBindable 屬性。

QueryIconProperty

的 QueryIconBindable 屬性。

QueryProperty

的 QueryBindable 屬性。

SearchBoxVisibilityProperty

的 SearchBoxVisibilityBindable 屬性。

SelectedItemProperty

的 SelectedItemBindable 屬性。

ShowsResultsProperty

的 ShowsResultsBindable 屬性。

TextColorProperty

的 TextColorBindable 屬性。

TextTransformProperty

的 TextTransformBindable 屬性。

VerticalTextAlignmentProperty

的 VerticalTextAlignmentBindable 屬性。

屬性

名稱 Description
AutomationId

提供應用程式中的 Shell 搜尋功能。

BackgroundColor

取得或設定搜尋框的背景色。 這是可繫結屬性。

BindingContext

取得或設定 物件,其中包含屬於這個 BindableObject之系結屬性的目標屬性。 這是可繫結屬性。

(繼承來源 BindableObject)
CancelButtonColor

設定取消按鈕的顏色。 這是可繫結屬性。

CharacterSpacing

取得或設定搜尋文字的字元間距。 這是可繫結屬性。

ClearIcon

取得或設定顯示的清除按鈕圖示。 這是可繫結屬性。

ClearIconHelpText

取得或設定透明圖示的無障礙說明文字。 這是可繫結屬性。

ClearIconName

取得或設定透明圖示的無障礙名稱。 這是可繫結屬性。

ClearPlaceholderCommand

當按下清除佔位符按鈕時,會接收或設定所呼叫的指令。 這是可繫結屬性。

ClearPlaceholderCommandParameter

取得或設定傳遞給 ClearPlaceholderCommand的參數。 這是可繫結屬性。

ClearPlaceholderEnabled

會取得或設定一個值,指示是否啟用了清除佔位符按鈕。 這是可繫結屬性。

ClearPlaceholderHelpText

取得或設定透明佔位圖示的無障礙說明文字。 這是可繫結屬性。

ClearPlaceholderIcon

取得或設定顯示的圖示,用於清除佔位按鈕。 這是可繫結屬性。

ClearPlaceholderName

取得或設定透明佔位圖示的無障礙名稱。 這是可繫結屬性。

Command

當搜尋查詢被確認時,會接收或設定所呼叫的指令。 這是可繫結屬性。

CommandParameter

取得或設定傳遞給 Command的參數。 這是可繫結屬性。

Dispatcher

取得建立這個可系結物件時可用的發送器,否則會嘗試尋找最接近的可用發送器(可能是視窗的/應用程式)。

(繼承來源 BindableObject)
DisplayMemberName
已淘汰.

取得或設定物件名稱以供搜尋結果使用。 這是可繫結屬性。

FontAttributes

取得或設定搜尋文字的字型屬性。 這是可繫結屬性。

FontAutoScalingEnabled

提供應用程式中的 Shell 搜尋功能。

FontFamily

取得或設定搜尋文字的字型家族。 這是可繫結屬性。

FontSize

它會取得或設定搜尋文字的字體大小。 這是可繫結屬性。

HorizontalTextAlignment

取得或設定搜尋文字的水平對齊。 這是可繫結屬性。

IsFocused

會獲得一個值,表示此搜尋處理器目前是否有焦點。 這是可繫結屬性。

IsSearchEnabled

取得或設定一個值,表示搜尋是否啟用。 這是可繫結屬性。

ItemsSource

取得或設定一組項目,作為搜尋建議顯示。 這是可繫結屬性。

ItemTemplate

取得或設定顯示搜尋結果項目的範本。 這是可繫結屬性。

Keyboard

它會取得或設定搜尋輸入的鍵盤類型。 這是可繫結屬性。

Placeholder

當搜尋框為空時,會接收或設定顯示的文字。 這是可繫結屬性。

PlaceholderColor

取得或設定佔位文字的顏色。 這是可繫結屬性。

Query

取得或設定目前的搜尋查詢文字。 這是可繫結屬性。

QueryIcon

取得或設定搜尋查詢顯示的圖示。 這是可繫結屬性。

QueryIconHelpText

取得或設定查詢圖示的無障礙說明文字。 這是可繫結屬性。

QueryIconName

取得或設定查詢圖示的無障礙名稱。 這是可繫結屬性。

SearchBoxVisibility

取得或設定搜尋框的可見模式。 這是可繫結屬性。

SelectedItem

取得目前選取的搜尋結果項目。 這是可繫結屬性。

ShowsResults

取得或設定一個值,表示搜尋結果是否被顯示。 這是可繫結屬性。

TextColor

取得或設定搜尋文字的顏色。 這是可繫結屬性。

TextTransform

取得或設定對搜尋文字套用的文字轉換。 這是可繫結屬性。

VerticalTextAlignment

取得或設定搜尋文字的垂直對齊。 這是可繫結屬性。

方法

名稱 Description
ApplyBindings()

將所有目前的系結套用至 BindingContext。

(繼承來源 BindableObject)
ClearValue(BindableProperty)

清除先前為可系結屬性設定的任何值。

(繼承來源 BindableObject)
ClearValue(BindablePropertyKey)

清除先前為其索引鍵所識別之可系結屬性設定的任何值。

(繼承來源 BindableObject)
CoerceValue(BindableProperty)

強制指定可系結屬性的值。 這是藉由叫用 BindableProperty.CoerceValueDelegate 指定的可系結屬性來完成。

(繼承來源 BindableObject)
CoerceValue(BindablePropertyKey)

強制指定可系結屬性的值。 這是藉由叫用 BindableProperty.CoerceValueDelegate 指定的可系結屬性來完成。

(繼承來源 BindableObject)
Focus()

將焦點設定到搜尋處理器,使輸入欄位成為目前的焦點。

GetValue(BindableProperty)

傳回指定可系結屬性中包含的值。

(繼承來源 BindableObject)
HideSoftInputAsync()

提供應用程式中的 Shell 搜尋功能。

IsSet(BindableProperty)

判斷可系結屬性是否存在,並且已設定值。

(繼承來源 BindableObject)
OnBindingContextChanged()

引發 BindingContextChanged 事件。

(繼承來源 BindableObject)
OnClearPlaceholderClicked()

提供應用程式中的 Shell 搜尋功能。

OnFocused()

提供應用程式中的 Shell 搜尋功能。

OnItemSelected(Object)

提供應用程式中的 Shell 搜尋功能。

OnPropertyChanged(String)

引發 PropertyChanged 事件。

(繼承來源 BindableObject)
OnPropertyChanging(String)

引發 PropertyChanging 事件。

(繼承來源 BindableObject)
OnQueryChanged(String, String)

提供應用程式中的 Shell 搜尋功能。

OnQueryConfirmed()

提供應用程式中的 Shell 搜尋功能。

OnUnfocus()

提供應用程式中的 Shell 搜尋功能。

RemoveBinding(BindableProperty)

從可系結屬性中移除先前設定的系結。

(繼承來源 BindableObject)
SetBinding(BindableProperty, BindingBase)

將系結指派給可系結屬性。

(繼承來源 BindableObject)
SetIsFocused(Boolean)

設定房產價值 IsFocused 。 供平台渲染器內部使用。

SetValue(BindableProperty, Object)

設定指定之可系結屬性的值。

(繼承來源 BindableObject)
SetValue(BindablePropertyKey, Object)

設定指定之可系結屬性的值。

(繼承來源 BindableObject)
ShowSoftInputAsync()

提供應用程式中的 Shell 搜尋功能。

UnapplyBindings()

從目前內容中移除所有目前的系結。

(繼承來源 BindableObject)
Unfocus()

這樣可以移除搜尋處理器的焦點。

UpdateFormsText(String, TextTransform)

回傳轉換後的文字,使用指定的 TextTransform。

事件

名稱 Description
BindingContextChanged

發生於 BindingContext 屬性的值變更時。

(繼承來源 BindableObject)
FocusChangeRequested

提供應用程式中的 Shell 搜尋功能。

Focused

提供應用程式中的 Shell 搜尋功能。

PropertyChanged

當屬性值變更時發生。

(繼承來源 BindableObject)
PropertyChanging

屬性值正在變更時發生。

(繼承來源 BindableObject)
Unfocused

提供應用程式中的 Shell 搜尋功能。

明確介面實作

名稱 Description
IDynamicResourceHandler.SetDynamicResource(BindableProperty, String)

提供應用程式中的 Shell 搜尋功能。

(繼承來源 BindableObject)
IFontElement.FontSizeDefaultValueCreator()

提供應用程式中的 Shell 搜尋功能。

IFontElement.OnFontAttributesChanged(FontAttributes, FontAttributes)

提供應用程式中的 Shell 搜尋功能。

IFontElement.OnFontAutoScalingEnabledChanged(Boolean, Boolean)

提供應用程式中的 Shell 搜尋功能。

IFontElement.OnFontFamilyChanged(String, String)

提供應用程式中的 Shell 搜尋功能。

IFontElement.OnFontSizeChanged(Double, Double)

提供應用程式中的 Shell 搜尋功能。

ISearchHandlerController.ClearPlaceholderClicked()

提供應用程式中的 Shell 搜尋功能。

ISearchHandlerController.ItemSelected(Object)

提供應用程式中的 Shell 搜尋功能。

ISearchHandlerController.ListProxy

提供應用程式中的 Shell 搜尋功能。

ISearchHandlerController.ListProxyChanged

提供應用程式中的 Shell 搜尋功能。

ISearchHandlerController.QueryConfirmed()

提供應用程式中的 Shell 搜尋功能。

ITextAlignmentElement.OnHorizontalTextAlignmentPropertyChanged(TextAlignment, TextAlignment)

提供應用程式中的 Shell 搜尋功能。

ITextElement.OnCharacterSpacingPropertyChanged(Double, Double)

提供應用程式中的 Shell 搜尋功能。

ITextElement.OnTextColorPropertyChanged(Color, Color)

提供應用程式中的 Shell 搜尋功能。

ITextElement.OnTextTransformChanged(TextTransform, TextTransform)

提供應用程式中的 Shell 搜尋功能。

擴充方法

名稱 Description
GetPropertyIfSet<T>(BindableObject, BindableProperty, T)

提供應用程式中的 Shell 搜尋功能。

SetAppTheme<T>(BindableObject, BindableProperty, T, T)

提供應用程式中的 Shell 搜尋功能。

SetAppThemeColor(BindableObject, BindableProperty, Color, Color)

提供應用程式中的 Shell 搜尋功能。

SetBinding(BindableObject, BindableProperty, String, BindingMode, IValueConverter, String)

建立並將繫結套用至屬性。

SetBinding<TSource,TProperty>(BindableObject, BindableProperty, Func<TSource,TProperty>, BindingMode, IValueConverter, Object, String, Object, Object, Object)

在來源物件上的 屬性與目標物件上的屬性之間建立系結。

ToFont(IFontElement, Nullable<Double>)

提供應用程式中的 Shell 搜尋功能。

適用於