Какова функция пространства имен здесь?
Я бы подумал, что в этом простом примере я мог бы поставить «Ключ» и «XData» вместо «x: Key» и «x: XData», но когда я это сделаю, будет сказано, что «Key» не найден в XmlDataProvider .
<Window x:Class="DataBindingWPF.XmlBinding"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="DataBindingWPF" Height="300" Width="300"
>
<StackPanel>
<StackPanel.Resources>
<XmlDataProvider x:Key="Colors" Source="Colors.xml" XPath="/colors"></XmlDataProvider>
<XmlDataProvider x:Key="MoreColors" XPath="/colors">
<x:XData>
...