Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <Window x:Class="ShapeDrawingApp.MainWindow"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- Title="Shape Drawing App" Width="800" Height="600">
- <Grid>
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto"/>
- <RowDefinition Height="*"/>
- </Grid.RowDefinitions>
- <!-- Buttons for selecting shapes -->
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Grid.Row="0">
- <Button Name="btnEllipse" Content="Ellipse" Click="btnEllipse_Click"/>
- <Button Name="btnRectangle" Content="Rectangle" Click="btnRectangle_Click"/>
- <Button Name="btnCircle" Content="Circle" Click="btnCircle_Click"/>
- <Button Name="btnLine" Content="Line" Click="btnLine_Click"/>
- </StackPanel>
- <!-- Drawing Canvas -->
- <Canvas Name="drawingCanvas" Grid.Row="1" Background="White"
- MouseDown="drawingCanvas_MouseDown"
- MouseUp="drawingCanvas_MouseUp"
- MouseMove="drawingCanvas_MouseMove"/>
- </Grid>
- </Window>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement