LocalizationCategory 列舉

定義

為二進位 XAML (BAML) 類別或類別成員指定 LocalizabilityAttribute 的分類值。

public enum class LocalizationCategory
public enum LocalizationCategory
type LocalizationCategory = 
Public Enum LocalizationCategory
繼承
LocalizationCategory

欄位

Button 4

Button 或相關的控制項。

CheckBox 5

CheckBox 或相關的控制項。

ComboBox 6

ComboBox 或相關的控制項,例如 ComboBoxItem

Font 14

字型相關資料,例如字型的名稱、樣式或大小。

11

Hyperlink 或相關的控制項。

Ignore 16

請勿將此資源當地語系化。 這個資源不適用於任何可能存在的子節點。

Inherit 15

從父節點繼承其分類。

Label 3

Label 或相關的控制項。

ListBox 7

ListBox 或相關的控制項,例如 ListBoxItem

Menu 8

Menu 或相關的控制項,例如 MenuItem

NeverLocalize 17

請勿將此資源或任何分類設定為 Inherit 的子節點當地語系化。

None 0

資源不屬於標準分類。

RadioButton 9

RadioButton 或相關的控制項。

Text 1

適用於冗長的文字。

TextFlow 12

適用於可以包含文字的面板。

Title 2

適用於單一文字行,例如標題使用的文字。

ToolTip 10

ToolTip 或相關的控制項。

XmlData 13

XML 資料。

範例

下列程式碼範例顯示為按鈕定義的 類別值 LocalizabilityAttribute

<!-- Define localization attributes for the button.
      - The content is visible to the localizer and can be changed.
      - The font family property is visible to the localizer but cannot be changed. -->
  <Button
    FontFamily="Microsoft San Serif"
    Localization.Attributes=
      "$Content(Button Readable Modifiable) FontFamily(Font Readable Unmodifiable)" >
    your company name here
  </Button>

備註

LocalizabilityAttribute屬性可以套用至類別、屬性或方法。

如需如何使用當地語系化屬性的詳細資訊,請參閱 當地語系化屬性和批註

適用於

另請參閱