MainWindow.xaml 1.6 KB

12345678910111213141516171819202122232425262728293031
  1. <Window x:Class="RoslynPadReplSample.MainWindow"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  5. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  6. xmlns:editor="clr-namespace:RoslynPad.Editor;assembly=RoslynPad.Editor.Windows"
  7. mc:Ignorable="d"
  8. Title="RoslynPad REPL Sample"
  9. Height="350"
  10. Width="525">
  11. <ScrollViewer Background="#eee">
  12. <ItemsControl Name="Items">
  13. <ItemsControl.ItemTemplate>
  14. <DataTemplate>
  15. <StackPanel>
  16. <editor:RoslynCodeEditor Loaded="OnItemLoaded"
  17. Margin="5"
  18. ContextActionsIcon="{StaticResource Bulb}"
  19. PreviewKeyDown="OnEditorKeyDown"
  20. IsReadOnly="{Binding IsReadOnly}"
  21. HorizontalScrollBarVisibility="Disabled"
  22. VerticalScrollBarVisibility="Disabled"
  23. ShowLineNumbers="False" />
  24. <TextBlock Text="{Binding Result}"
  25. TextWrapping="Wrap" />
  26. </StackPanel>
  27. </DataTemplate>
  28. </ItemsControl.ItemTemplate>
  29. </ItemsControl>
  30. </ScrollViewer>
  31. </Window>