一.button控件上的模板

<Button Content="Button" Height="25" HorizontalAlignment="Left" Margin="23,30,0,0" Width ="150" VerticalAlignment="Top" Click="button1_Click" Tag="Full Dental Charting">
<Button.Template>
<ControlTemplate>
<Border CornerRadius="5" BorderBrush="black" BorderThickness="2">
<TextBlock Text="Full Dental Charting" FontSize="16" HorizontalAlignment="center" VerticalAlignment="center" ></TextBlock>
</Border>
</ControlTemplate>
</Button.Template>
</Button>

二.button模板(Text="{TemplateBinding  Content}"得到是button) 

<ControlTemplate x:Key="buttonTemplate" TargetType="Button" >

<BulletDecorator Background="Transparent">
<Border CornerRadius="5" BorderBrush="black" BorderThickness="2">
<TextBlock Text="{Binding RelativeSource={RelativeSource Self},Path=DataContext}" FontSize="16" HorizontalAlignment="center" VerticalAlignment="center" ></TextBlock>
</Border>

</BulletDecorator>
</ControlTemplate>

<Button Content="Button" Height="25" HorizontalAlignment="Left" Margin="23,30,0,0" Width ="150" Template="{StaticResource buttonTemplate}" DataContext="Full Dental Charting">

三.button样式

<Style TargetType="Button" x:Key="ButtonStyle">
<Setter Property="Height" Value="25"></Setter>
<Setter Property="Width" Value="150"></Setter>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button" >
<Border CornerRadius="5" BorderBrush="black" BorderThickness="2">
<TextBlock Text="{Binding RelativeSource={RelativeSource Self},Path=DataContext}" FontSize="16" HorizontalAlignment="center" VerticalAlignment="center" ></TextBlock>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>

<Button Content="Button" HorizontalAlignment="Left" Margin="23,30,0,0" Style="{StaticResource ButtonStyle}" Click="button1_Click" DataContext="Full Dental Charting" />