1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798 |
- <UserControl
- x:Class="PDF_Office.Views.HomeContent"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:cus="clr-namespace:PDF_Office.CustomControl"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:prism="http://prismlibrary.com/"
- xmlns:viewmodels="clr-namespace:PDF_Office.ViewModels"
- d:DesignHeight="450"
- d:DesignWidth="800"
- prism:ViewModelLocator.AutoWireViewModel="True"
- xmlns:customControl ="clr-namespace:PDF_Office.CustomControl"
- xmlns:homePanel="clr-namespace:PDF_Office.Views.HomePanel"
- mc:Ignorable="d">
- <UserControl.Resources>
- <ResourceDictionary>
- <ResourceDictionary.MergedDictionaries>
- <ResourceDictionary Source="../Styles/CustomBtnStyle.xaml"/>
- </ResourceDictionary.MergedDictionaries>
- <DataTemplate x:Key="PromotionDataTemplate">
- <StackPanel Background="White" Orientation="Horizontal" Cursor="Hand" Margin="0,10,0,10">
- <Image Width="16" Height="16" Source="{Binding ImagePath}" Margin="0,0,10,0"/>
- <TextBlock Text="{Binding Content}" FontSize="14" Foreground="#6B6F7D"/>
- </StackPanel>
- </DataTemplate>
- </ResourceDictionary>
- </UserControl.Resources>
- <Grid>
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto"/>
- <RowDefinition/>
- </Grid.RowDefinitions>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="270" />
- <ColumnDefinition Width="*" />
- </Grid.ColumnDefinitions>
- <!-- 左侧菜单栏 -->
- <StackPanel>
- <Button x:Name="BtnOpenPDF" Height="48" Margin="41,54,41,0" Foreground="#FFFFFF" Background="#19233B" BorderThickness="1"
- Command="{Binding OpenFileCommand}"
- Style="{StaticResource BlueBtnStyle}" >
- <StackPanel Orientation="Horizontal">
- <TextBlock x:Name="TxbOpenPDF" Text="Open File" VerticalAlignment="Center" FontFamily="Segoe UI" FontSize="16"/>
- </StackPanel>
- </Button>
- <Button x:Name="BtnCreatPDF" Height="48" Width="188" Margin="41,8,41,0" Background="White" BorderThickness="1" HorizontalContentAlignment="Left"
- Command="{Binding OpenFileCommand}"
- Style="{StaticResource BlueBtnStyle}" >
- <Grid Width="184" >
- <Grid.ColumnDefinitions>
- <ColumnDefinition />
- <ColumnDefinition Width="48"/>
- </Grid.ColumnDefinitions>
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Width="30" Height="30" Source="../Resources/HomeIcon/file_addition.png" Margin="18,0,12,0"/>
- <TextBlock x:Name="TxbCreatePDF" Text="Creat PDF" VerticalAlignment="Center" FontFamily="Segoe UI" Foreground="{StaticResource Common.ForGround.Blue}" FontSize="16"/>
- </StackPanel>
- <StackPanel Orientation="Horizontal" Grid.Column="1" HorizontalAlignment='Center'>
- <Rectangle Fill="#6B869C" Width="1" Height="48" Margin="0,0,8,0"/>
- <Path Data="M12.0001 6.00012L8 10.0002L3.99988 6.00012" HorizontalAlignment="Center" VerticalAlignment="Center" Stroke="#6B869C"/>
- </StackPanel>
- </Grid>
-
- </Button>
- <customControl:CustomIconToggleBtn x:Name="BtnGuid" Margin="0,24,0,0" Width="216" HorizontalContentAlignment="Left" Height="40" Tag="GridMode" Command="{Binding ShowToolCommand}" CommandParameter="Guid" Click="ToggleBtnSelect_Click"
- Style="{StaticResource ToggleBtnSelectStyle}">
- <StackPanel Orientation="Horizontal" Margin="8,0,8,0">
- <Path Fill="{Binding ElementName=BtnGuid,Path=Foreground}" Data="M3.8655 5.79653C3.32363 6.16977 3 6.78565 3 7.44363V15C3 16.1046 3.89543 17 5 17H9V13.1785C9 12.6262 9.44772 12.1785 10 12.1785C10.5523 12.1785 11 12.6262 11 13.1785V17H15C16.1046 17 17 16.1046 17 15V7.44363C17 6.78565 16.6764 6.16977 16.1345 5.79653L11.1345 2.3526C10.4514 1.88206 9.54865 1.88206 8.8655 2.3526L3.8655 5.79653Z"/>
- <TextBlock x:Name="TxbHome" Text="Home" VerticalAlignment="Center" Margin="8,0,0,0" FontFamily="SF Pro Text" FontSize="14"/>
- </StackPanel>
- </customControl:CustomIconToggleBtn>
- <customControl:CustomIconToggleBtn x:Name="BtnTool" Width="216" Height="40" HorizontalContentAlignment="Left" Tag="GridMode" Command="{Binding ShowToolCommand}" CommandParameter="Tools" Click="ToggleBtnSelect_Click"
- Style="{StaticResource ToggleBtnSelectStyle}">
- <StackPanel Orientation="Horizontal" Margin="8,0,8,0">
- <Path Fill="{Binding ElementName=BtnTool,Path=Foreground}" Data="M3.8655 5.79653C3.32363 6.16977 3 6.78565 3 7.44363V15C3 16.1046 3.89543 17 5 17H9V13.1785C9 12.6262 9.44772 12.1785 10 12.1785C10.5523 12.1785 11 12.6262 11 13.1785V17H15C16.1046 17 17 16.1046 17 15V7.44363C17 6.78565 16.6764 6.16977 16.1345 5.79653L11.1345 2.3526C10.4514 1.88206 9.54865 1.88206 8.8655 2.3526L3.8655 5.79653Z"/>
- <TextBlock x:Name="TxbTool" Text="Tool" VerticalAlignment="Center" Margin="8,0,0,0" FontFamily="SF Pro Text" FontSize="14"/>
- </StackPanel>
- </customControl:CustomIconToggleBtn>
- <customControl:CustomIconToggleBtn x:Name="BtnCloud" Width="216" HorizontalContentAlignment="Left" Height="40" Tag="GridMode" Command="{Binding ShowToolCommand}" CommandParameter="Cloud" Click="ToggleBtnSelect_Click"
- Style="{StaticResource ToggleBtnSelectStyle}">
- <StackPanel Orientation="Horizontal" Margin="8,0,8,0">
- <Path Fill="{Binding ElementName=BtnCloud,Path=Foreground}" Data="M14.95 16.5H5.5C3.01472 16.5 1 14.4853 1 12C1 9.51472 3.01472 7.5 5.5 7.5L5.52018 7.50004C5.74751 4.9771 7.86787 3 10.45 3C13.1838 3 15.4 5.21619 15.4 7.95C15.4 8.10931 15.3925 8.26686 15.3778 8.42232C17.4134 8.63601 19 10.3577 19 12.45C19 14.6701 17.2137 16.4729 15 16.4997V16.5H14.95Z"/>
- <TextBlock x:Name="TxbCloud" Text="Cloud" FontFamily="SF Pro Text" FontSize="14" VerticalAlignment="Center" Margin="8,0,0,0" />
- </StackPanel>
- </customControl:CustomIconToggleBtn>
- </StackPanel>
- <homePanel:PromotionContent Grid.Row="1"/>
- <!-- 右侧内容区域 -->
- <ContentControl Grid.Column="1" Grid.RowSpan="2" prism:RegionManager.RegionName="{Binding ToolRegionName}" />
- <cus:LoadingControl Grid.ColumnSpan="2" Grid.RowSpan="2" Visibility="{Binding IsLoading}" />
- </Grid>
- </UserControl>
|