EntryCell 類別
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
具有標籤和一行文字項目欄位的 Cell。
public ref class EntryCell : Microsoft::Maui::Controls::Cell, Microsoft::Maui::Controls::IEntryCellController, Microsoft::Maui::ITextAlignment
public class EntryCell : Microsoft.Maui.Controls.Cell, Microsoft.Maui.Controls.IEntryCellController, Microsoft.Maui.ITextAlignment
type EntryCell = class
inherit Cell
interface IEntryCellController
interface ITextAlignment
Public Class EntryCell
Inherits Cell
Implements IEntryCellController, ITextAlignment
- 繼承
- 實作
備註
下列範例示範基本用途。
using System;
using Microsoft.Maui.Controls;
namespace FormsGallery
{
class EntryCellDemoPage : ContentPage
{
public EntryCellDemoPage()
{
Label header = new Label
{
Text = "EntryCell",
FontSize = Device.GetNamedSize (NamedSize.Large, typeof(EntryCell)),
HorizontalOptions = LayoutOptions.Center
};
TableView tableView = new TableView
{
Intent = TableIntent.Form,
Root = new TableRoot
{
new TableSection
{
new EntryCell
{
Label = "EntryCell:",
Placeholder = "Type Text Here"
}
}
}
};
// Accomodate iPhone status bar.
this.Padding = new Thickness(10, Device.OnPlatform(20, 0, 0), 10, 5);
// Build the page.
this.Content = new StackLayout
{
Children =
{
header,
tableView
}
};
}
}
}
建構函式
EntryCell() |
具有標籤和一行文字項目欄位的 Cell。 |
欄位
DefaultCellHeight |
儲存格的預設高度。 (繼承來源 Cell) |
HorizontalTextAlignmentProperty |
的 HorizontalTextAlignment可系結屬性。 |
KeyboardProperty |
的 Keyboard可系結屬性。 |
LabelColorProperty |
的 LabelColor可系結屬性。 |
LabelProperty |
的 Label可系結屬性。 |
PlaceholderProperty |
的 PlaceholderBindable 屬性。 |
TextProperty |
的 TextBindable 屬性。 |
VerticalTextAlignmentProperty |
的 VerticalTextAlignmentBindable 屬性。 |
屬性
AutomationId |
取得或設定值,允許自動化架構尋找此項目並與之互動。 (繼承來源 Element) |
BindingContext |
取得或設定 對象,這個物件包含系結屬性所屬之系結屬性的目標屬性 BindableObject。 這是可繫結屬性。 (繼承來源 BindableObject) |
ClassId |
取得或設定值,用來識別語意類似項目的集合。 (繼承來源 Element) |
ContextActions |
取得當使用者在儲存格上執行裝置特定內容動作時,要顯示的功能表項目清單。 (繼承來源 Cell) |
Dispatcher |
取得建立這個可系結物件時可用的發送器,否則會嘗試尋找最接近的可用發送器, (可能是視窗/應用程式的) 。 (繼承來源 BindableObject) |
EffectControlProvider |
供 .NET MAUI 內部使用。 (繼承來源 Element) |
Effects |
取得或設定將在運行時間套用至 元素的樣式和屬性。 (繼承來源 Element) |
Handler |
取得或設定這個項目的相關聯處理程式。 (繼承來源 Element) |
HasContextActions |
取得值,這個值表示儲存格在其 ContextActions 清單屬性中是否至少有一個功能表項目。 (繼承來源 Cell) |
Height |
取得或設定儲存格的高度。 (繼承來源 Cell) |
HorizontalTextAlignment |
取得或設定 Text 屬性的水平對齊。 這是可繫結屬性。 |
Id |
取得值,這個值可用來在應用程式執行期間唯一識別專案。 (繼承來源 Element) |
IsContextActionsLegacyModeEnabled |
具有標籤和一行文字項目欄位的 Cell。 (繼承來源 Cell) |
IsEnabled |
取得或設定儲存格的 IsEnabled 狀態。 這是可繫結屬性。 (繼承來源 Cell) |
Keyboard |
取得或設定編輯 EntryCell 時所要顯示的 Keyboard。 這是可繫結屬性。 |
Label |
取得或設定顯示在 EntryCell 中 Entry 旁的固定文字。 這是可繫結屬性。 |
LabelColor |
取得或設定用於呈現 Label 屬性的 Color。 這是可繫結屬性。 |
LogicalChildren |
已淘汰.
供 Microsoft.Maui.Controls 平台內部使用。 (繼承來源 Element) |
Parent |
取得或設定這個專案的父代 Element 。 (繼承來源 Element) |
Placeholder |
取得或設定當 Text 為 Null 或空白時顯示於 Entry 中的預留位置文字。 這是可繫結屬性。 |
RealParent |
供 .NET MAUI 內部使用。 (繼承來源 Element) |
RenderHeight |
取得裝置上所呈現儲存格的高度。 (繼承來源 Cell) |
StyleId |
取得或設定使用者定義值來唯一識別項目。 (繼承來源 Element) |
Text |
取得或設定 EntryCell 的 Entry 內容。 這是可繫結屬性。 |
VerticalTextAlignment |
具有標籤和一行文字項目欄位的 Cell。 |
方法
事件
Appearing |
具有標籤和一行文字項目欄位的 Cell。 (繼承來源 Cell) |
BindingContextChanged |
發生於 BindingContext 屬性的值變更時。 (繼承來源 BindableObject) |
ChildAdded |
每當子專案加入至 元素時引發。 (繼承來源 Element) |
ChildRemoved |
每當從專案中移除子項目時引發。 (繼承來源 Element) |
Completed |
具有標籤和一行文字項目欄位的 Cell。 |
DescendantAdded |
每當子專案加入至專案的子樹時引發。 (繼承來源 Element) |
DescendantRemoved |
每當從專案子樹中移除子項目時引發。 (繼承來源 Element) |
Disappearing |
具有標籤和一行文字項目欄位的 Cell。 (繼承來源 Cell) |
ForceUpdateSizeRequested |
具有標籤和一行文字項目欄位的 Cell。 (繼承來源 Cell) |
HandlerChanged |
每當項目的處理程式變更時引發。 (繼承來源 Element) |
HandlerChanging |
每當項目的處理程序開始變更時引發。 (繼承來源 Element) |
ParentChanged |
每當專案的父代變更時引發。 (繼承來源 Element) |
ParentChanging |
每當項目的 開始變更時引發。 (繼承來源 Element) |
PropertyChanged |
當屬性值變更時發生。 (繼承來源 BindableObject) |
PropertyChanging |
當屬性值變更中時發生。 (繼承來源 BindableObject) |
Tapped |
具有標籤和一行文字項目欄位的 Cell。 (繼承來源 Cell) |
明確介面實作
IContextFlyoutElement.ContextFlyout |
ContextFlyout取得檢視的 。 功能表飛出視窗、功能表飛出視窗子專案和功能表飛出視窗分隔符可以新增至內容飛出視窗。 (繼承來源 Element) |
IDynamicResourceHandler.SetDynamicResource(BindableProperty, String) |
具有標籤和一行文字項目欄位的 Cell。 (繼承來源 BindableObject) |
IEffectControlProvider.RegisterEffect(Effect) |
具有標籤和一行文字項目欄位的 Cell。 (繼承來源 Element) |
IElement.Parent |
取得專案的父代。 (繼承來源 Element) |
IElementController.Descendants() |
供 .NET MAUI 內部使用。 (繼承來源 Element) |
IElementController.LogicalChildren |
供 .NET MAUI 內部使用。 (繼承來源 Element) |
IElementController.SetValueFromRenderer(BindableProperty, Object) |
供 .NET MAUI 內部使用。 (繼承來源 Element) |
INameScope.RegisterName(String, Object) |
供 .NET MAUI 內部使用。 (繼承來源 Element) |
INameScope.UnregisterName(String) |
供 .NET MAUI 內部使用。 (繼承來源 Element) |
IToolTipElement.ToolTip |
代表小型矩形彈出視窗,當使用者將指標放在檢視上時,會顯示檢視用途的簡短描述。 (繼承來源 Element) |
IVisualTreeElement.GetVisualChildren() |
具有標籤和一行文字項目欄位的 Cell。 (繼承來源 Cell) |
IVisualTreeElement.GetVisualParent() |
取得項目的視覺父代。 (繼承來源 Element) |
擴充方法
適用於
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應