I am working with WPF, Visual Studio 2015, in which I want to place buttons next to each other as well as this image.
I've only been able to achieve this.
This is the XAML code that I am occupying, what I did was put a Grid with two columns and a row in which in the first I put Select the Menu , and on the other side the buttons .
<Grid>
<StackPanel Orientation="Vertical">
<StackPanel>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition/>
</Grid.RowDefinitions>
<TextBlock Text="Seleccione el Menu" FontWeight="Bold" FontSize="13" Margin="20" Grid.Column="0" Grid.Row="0"/>
<Button Width="60" Height="20" HorizontalAlignment="Left" Grid.Column="1" Grid.Row="0" Content="Nuevo"/>
<Button Width="60" Height="20" Grid.Column="1" Grid.Row="0" Content="Guardar" HorizontalAlignment="Center" Margin="-50,0,0,0"/>
<Button Width="60" Height="20" Grid.Column="1" Grid.Row="0" Content="Eliminar" Margin="-195,0,0,0" HorizontalAlignment="Right"/>
</Grid>
</StackPanel>
<View:MyTabControl x:Name="currentTabControl" Margin="5"/>
</StackPanel>
</Grid>
How can I make it look like the buttons on the first image?
I have already managed to put the images and the text on the button, but the text can not be put under the image, I occupy the following code.
<Grid>
<StackPanel Orientation="Vertical">
<StackPanel>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition/>
</Grid.RowDefinitions>
<TextBlock Text="Seleccione el Menu" FontWeight="Bold" FontSize="13" Margin="20" Grid.Column="0" Grid.Row="0"/>
<StackPanel Orientation="Horizontal" Grid.Column="1" Grid.Row="0">
<Button x:Name="btnMNuevo" Width="60" Height="40" Grid.Column="1" Grid.Row="0">
<DockPanel>
<Image Source="/Imagenes/New.png"/>
<TextBlock Text="Nuevo" TextAlignment="Left"/>
</DockPanel>
</Button>
<Button x:Name="btnMGuardar" Width="60" Height="40" Grid.Column="1" Grid.Row="0">
<DockPanel>
<Image Source="/Imagenes/save.png"/>
<TextBlock Text="Guardar" Margin="0"/>
</DockPanel>
</Button>
<Button x:Name="btnMEliminar" Width="60" Height="40" Grid.Column="1" Grid.Row="0">
<DockPanel>
<Image Source="/Imagenes/delete.png"/>
<TextBlock Text="Eliminar"/>
</DockPanel>
</Button>
</StackPanel>
</Grid>
</StackPanel>
<View:MyTabControl x:Name="currentTabControl" Margin="5"/>
</StackPanel>
</Grid>