|
144 | 144 | </DataTemplate>
|
145 | 145 |
|
146 | 146 | <DataTemplate DataType="vm:DatObjectEditorViewModel">
|
147 |
| - <StackPanel DataContext="{Binding}" Margin="10" Orientation="Vertical"> |
148 |
| - <StackPanel Orientation="Horizontal"> |
| 147 | + <DockPanel DataContext="{Binding}" Margin="10"> |
| 148 | + <StackPanel Orientation="Horizontal" DockPanel.Dock="Top"> |
149 | 149 | <Button Grid.Row="3" Command="{Binding ReloadObjectCommand}" HorizontalAlignment="Stretch" Margin="2" Padding="2">
|
150 | 150 | <DockPanel>
|
151 | 151 | <materialIcons:MaterialIcon Kind="{Binding ReloadIcon}" Width="24" Height="24" Margin="2" />
|
|
175 | 175 | </Border>
|
176 | 176 | </TabItem>
|
177 | 177 | <TabItem Header="Object">
|
178 |
| - <pgc:PropertyGrid x:Name="propertyGrid_Object" Margin="2" DataContext="{Binding CurrentObject.LocoObject.Object}" ShowTitle="False" AllowFilter="False" AllowQuickFilter="False"></pgc:PropertyGrid> |
| 178 | + <ScrollViewer> |
| 179 | + <pgc:PropertyGrid x:Name="propertyGrid_Object" Margin="2" DataContext="{Binding CurrentObject.LocoObject.Object}" ShowTitle="False" AllowFilter="False" AllowQuickFilter="False"></pgc:PropertyGrid> |
| 180 | + </ScrollViewer> |
179 | 181 | </TabItem>
|
180 | 182 | <TabItem Header="String Table">
|
181 | 183 | <StackPanel Orientation="Horizontal" Spacing="16">
|
|
303 | 305 | </TabItem>
|
304 | 306 | <TabItem Header="Hex Dump">
|
305 | 307 | <DockPanel>
|
306 |
| - <TreeView ItemsSource="{Binding CurrentHexAnnotations}" SelectedItem="{Binding CurrentlySelectedHexAnnotation}" Margin="4" DockPanel.Dock="Left" > |
307 |
| - <TreeView.ItemTemplate> |
308 |
| - <TreeDataTemplate ItemsSource="{Binding Nodes}"> |
309 |
| - <Grid> |
310 |
| - <Grid.ColumnDefinitions> |
311 |
| - <ColumnDefinition Width="Auto"/> |
312 |
| - <ColumnDefinition Width="*"/> |
313 |
| - </Grid.ColumnDefinitions> |
314 |
| - <TextBlock Grid.Column="0" VerticalAlignment="Center" Text="{Binding Title}" Margin="2"/> |
315 |
| - <TextBlock Grid.Column="1" VerticalAlignment="Center" HorizontalAlignment="Right" Text="{Binding OffsetText}" Margin="2" FontFamily="Courier New" /> |
316 |
| - </Grid> |
317 |
| - </TreeDataTemplate> |
318 |
| - </TreeView.ItemTemplate> |
319 |
| - </TreeView> |
320 |
| - <ItemsRepeater ItemsSource="{Binding CurrentHexDumpLines}" Background="{DynamicResource ButtonBackground}"> |
321 |
| - <ItemsRepeater.ItemTemplate> |
322 |
| - <DataTemplate> |
323 |
| - <Grid DockPanel.Dock="Left" Margin="4" x:DataType="vm:HexAnnotationLine"> |
324 |
| - <Grid.ColumnDefinitions> |
325 |
| - <ColumnDefinition Width="Auto"/> |
326 |
| - <ColumnDefinition Width="*"/> |
327 |
| - </Grid.ColumnDefinitions> |
328 |
| - <Border Grid.Column="0" Grid.ColumnSpan="1" Background="{DynamicResource ButtonBackgroundPointerOver}"> |
329 |
| - <TextBlock Text="{Binding Address}" VerticalAlignment="Center" Margin="4" FontFamily="Courier New" FontWeight="Bold" /> |
330 |
| - |
331 |
| - </Border> |
332 |
| - <SelectableTextBlock Grid.Column="1" Margin="4" Text="{Binding Data}" VerticalAlignment="Center" FontFamily="Courier New" SelectionStart="{Binding SelectionStart}" SelectionEnd="{Binding SelectionEnd}" /> |
333 |
| - </Grid> |
334 |
| - </DataTemplate> |
335 |
| - </ItemsRepeater.ItemTemplate> |
336 |
| - </ItemsRepeater> |
| 308 | + <ScrollViewer> |
| 309 | + <TreeView ItemsSource="{Binding CurrentHexAnnotations}" SelectedItem="{Binding CurrentlySelectedHexAnnotation}" Margin="4" DockPanel.Dock="Left" > |
| 310 | + <TreeView.ItemTemplate> |
| 311 | + <TreeDataTemplate ItemsSource="{Binding Nodes}"> |
| 312 | + <Grid> |
| 313 | + <Grid.ColumnDefinitions> |
| 314 | + <ColumnDefinition Width="Auto"/> |
| 315 | + <ColumnDefinition Width="*"/> |
| 316 | + </Grid.ColumnDefinitions> |
| 317 | + <TextBlock Grid.Column="0" VerticalAlignment="Center" Text="{Binding Title}" Margin="2"/> |
| 318 | + <TextBlock Grid.Column="1" VerticalAlignment="Center" HorizontalAlignment="Right" Text="{Binding OffsetText}" Margin="2" FontFamily="Courier New" /> |
| 319 | + </Grid> |
| 320 | + </TreeDataTemplate> |
| 321 | + </TreeView.ItemTemplate> |
| 322 | + </TreeView> |
| 323 | + </ScrollViewer> |
| 324 | + <ScrollViewer> |
| 325 | + <ItemsRepeater ItemsSource="{Binding CurrentHexDumpLines}" Background="{DynamicResource ButtonBackground}"> |
| 326 | + <ItemsRepeater.ItemTemplate> |
| 327 | + <DataTemplate> |
| 328 | + <Grid DockPanel.Dock="Left" Margin="4" x:DataType="vm:HexAnnotationLine"> |
| 329 | + <Grid.ColumnDefinitions> |
| 330 | + <ColumnDefinition Width="Auto"/> |
| 331 | + <ColumnDefinition Width="*"/> |
| 332 | + </Grid.ColumnDefinitions> |
| 333 | + <Border Grid.Column="0" Grid.ColumnSpan="1" Background="{DynamicResource ButtonBackgroundPointerOver}"> |
| 334 | + <TextBlock Text="{Binding Address}" VerticalAlignment="Center" Margin="4" FontFamily="Courier New" FontWeight="Bold" /> |
| 335 | + |
| 336 | + </Border> |
| 337 | + <SelectableTextBlock Grid.Column="1" Margin="4" Text="{Binding Data}" VerticalAlignment="Center" FontFamily="Courier New" SelectionStart="{Binding SelectionStart}" SelectionEnd="{Binding SelectionEnd}" /> |
| 338 | + </Grid> |
| 339 | + </DataTemplate> |
| 340 | + </ItemsRepeater.ItemTemplate> |
| 341 | + </ItemsRepeater> |
| 342 | + </ScrollViewer> |
337 | 343 | </DockPanel>
|
338 | 344 | </TabItem>
|
339 | 345 | </TabControl>
|
340 |
| - </StackPanel> |
| 346 | + </DockPanel> |
341 | 347 | </DataTemplate>
|
342 | 348 |
|
343 | 349 | <DataTemplate DataType="vm:SCV5ViewModel">
|
|
381 | 387 | <pgc:PropertyGrid x:Name="propertyGrid_imageProps" MinWidth="256" Margin="2" IsEnabled="False" DataContext="{Binding SelectedG1Element, Mode=OneWay}" DockPanel.Dock="Right" ShowTitle="False" AllowFilter="False" AllowQuickFilter="False" ShowStyle="Builtin"></pgc:PropertyGrid>
|
382 | 388 | </StackPanel>
|
383 | 389 | </Border>
|
384 |
| - <Border BorderThickness="1"> |
385 |
| - <ListBox ItemsSource="{Binding Bitmaps}" SelectedIndex="{Binding SelectedImageIndex}" Background="{Binding #ImageBackgroundColorView.Color, ConverterParameter={x:Static Brushes.Transparent}, Converter={StaticResource ColorToBrushConverter}}"> |
386 |
| - <ListBox.ItemsPanel> |
387 |
| - <ItemsPanelTemplate> |
388 |
| - <WrapPanel/> |
389 |
| - </ItemsPanelTemplate> |
390 |
| - </ListBox.ItemsPanel> |
391 |
| - <ListBox.ItemTemplate> |
392 |
| - <DataTemplate> |
393 |
| - <Image Source="{Binding}" Stretch="None" Margin="0"> |
394 |
| - <!--<Image.RenderTransform> |
| 390 | + <ScrollViewer> |
| 391 | + <Border BorderThickness="1"> |
| 392 | + <ListBox ItemsSource="{Binding Bitmaps}" SelectedIndex="{Binding SelectedImageIndex}" Background="{Binding #ImageBackgroundColorView.Color, ConverterParameter={x:Static Brushes.Transparent}, Converter={StaticResource ColorToBrushConverter}}"> |
| 393 | + <ListBox.ItemsPanel> |
| 394 | + <ItemsPanelTemplate> |
| 395 | + <WrapPanel/> |
| 396 | + </ItemsPanelTemplate> |
| 397 | + </ListBox.ItemsPanel> |
| 398 | + <ListBox.ItemTemplate> |
| 399 | + <DataTemplate> |
| 400 | + <Image Source="{Binding}" Stretch="None" Margin="0"> |
| 401 | + <!--<Image.RenderTransform> |
395 | 402 | <ScaleTransform ScaleX="{Binding Zoom}" ScaleY="{Binding Zoom}" />
|
396 | 403 | </Image.RenderTransform>-->
|
397 |
| - </Image> |
398 |
| - </DataTemplate> |
399 |
| - </ListBox.ItemTemplate> |
400 |
| - </ListBox> |
401 |
| - </Border> |
| 404 | + </Image> |
| 405 | + </DataTemplate> |
| 406 | + </ListBox.ItemTemplate> |
| 407 | + </ListBox> |
| 408 | + </Border> |
| 409 | + </ScrollViewer> |
402 | 410 | </DockPanel>
|
403 | 411 | </DataTemplate>
|
404 | 412 |
|
|
542 | 550 | </Grid>
|
543 | 551 | </DockPanel>
|
544 | 552 | <Border Margin="8" BorderThickness="1">
|
545 |
| - <ScrollViewer> |
546 |
| - <ContentControl Content="{Binding CurrentEditorModel}"/> |
547 |
| - </ScrollViewer> |
| 553 | + <ContentControl Content="{Binding CurrentEditorModel}"/> |
548 | 554 | </Border>
|
549 | 555 | </DockPanel>
|
550 | 556 | </Window>
|
0 commit comments