MahApps / MahApps.Metro

A framework that allows developers to cobble together a better UI for their own WPF applications with minimal effort.
https://mahapps.com
MIT License
9.28k stars 2.45k forks source link

I dont understand the demo of the binding method #3422

Closed zeroyjk closed 5 years ago

zeroyjk commented 5 years ago
        <Controls:MetroAnimatedSingleRowTabControl x:Name="MainTabControl" Grid.Row="1">
            <TabItem Header="buttons">
                <exampleViews:ButtonsExample DataContext="{Binding}" />
            </TabItem>
            <TabItem Header="text">
                <exampleViews:TextExamples DataContext="{Binding}" />
            </TabItem>

How it binding to

MahApps.Metro.Demo > folder (ExampleViews) > ButtonsExample.xaml

punker76 commented 5 years ago

@zeroyjk The DataContext of the ButtonsExample binds to the DataContext of the main window -> DataContext="{Binding}"

zeroyjk commented 5 years ago

I have google and bing it, but i dont understand it MVVM you using..

punker76 commented 5 years ago

Here are some help about that