فهرست منبع

Merge remote-tracking branch 'origin/dev' into dev

chenrongqian@kdanmobile.com 2 سال پیش
والد
کامیت
b6b4a97e22

+ 49 - 0
PDF Office/Styles/ToggleButton.xaml

@@ -1,5 +1,54 @@
 <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
     <!--  Design Token for subtool  -->
+    <Style x:Key="LinkToolbarTgb" TargetType="{x:Type ToggleButton}">
+        <Setter Property="FocusVisualStyle" Value="{x:Null}" />
+        <Setter Property="Background" Value="Transparent" />
+        <Setter Property="BorderThickness" Value="0" />
+        <Setter Property="Template">
+            <Setter.Value>
+                <ControlTemplate TargetType="{x:Type ToggleButton}">
+                    <Border
+                        x:Name="border"
+                        Background="{TemplateBinding Panel.Background}"
+                        BorderBrush="{StaticResource color.field.border.norm}"
+                        BorderThickness="1"
+                        CornerRadius="{StaticResource border-radius.4}"
+                        SnapsToDevicePixels="True">
+                        <ContentPresenter
+                            x:Name="contentPresenter"
+                            Margin="{TemplateBinding Padding}"
+                            HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
+                            VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
+                            Content="{TemplateBinding Content}"
+                            ContentStringFormat="{TemplateBinding ContentStringFormat}"
+                            ContentTemplate="{TemplateBinding ContentTemplate}"
+                            Focusable="False"
+                            RecognizesAccessKey="True"
+                            SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
+                    </Border>
+                    <ControlTemplate.Triggers>
+                        <Trigger Property="IsMouseOver" Value="True">
+                            <Setter TargetName="border" Property="BorderBrush" Value="{StaticResource color.field.border.focus}" />
+                            <!--<Setter TargetName="border" Property="Panel.Background" Value="{StaticResource color.field.border.focus}" />-->
+                        </Trigger>
+
+                        <Trigger Property="IsPressed" Value="True">
+                            <Setter TargetName="border" Property="BorderBrush" Value="{StaticResource color.field.border.focus}" />
+                        </Trigger>
+                        <Trigger Property="IsChecked" Value="True">
+                            <Setter TargetName="border" Property="BorderBrush" Value="{StaticResource color.field.border.focus}" />
+                        </Trigger>
+                        <Trigger Property="IsChecked" Value="False">
+                            <Setter TargetName="border" Property="BorderBrush" Value="{StaticResource color.field.border.norm}" />
+                        </Trigger>
+                        <Trigger Property="IsEnabled" Value="False">
+                            <Setter TargetName="border" Property="Panel.Background" Value="Transparent" />
+                        </Trigger>
+                    </ControlTemplate.Triggers>
+                </ControlTemplate>
+            </Setter.Value>
+        </Setter>
+    </Style>
     <Style x:Key="SubToolbarTgb" TargetType="{x:Type ToggleButton}">
         <Setter Property="FocusVisualStyle" Value="{x:Null}" />
         <Setter Property="Background" Value="Transparent" />

+ 41 - 23
PDF Office/ViewModels/BOTA/BookmarkContentViewModel.cs

@@ -209,6 +209,7 @@ namespace PDF_Office.ViewModels.BOTA
                 {
                     Bookmarklist.Remove(bookmark);
                     isAddBookMark = true;
+                    PDFViewer.UndoManager.CanSave = true;
                 }
             }
         }
@@ -311,7 +312,7 @@ namespace PDF_Office.ViewModels.BOTA
                 DialogParameters value = new DialogParameters();
                 value.Add(ParameterNames.Bookmark, mark);
                 value.Add(ParameterNames.Title, "创建一个新的书签");
-                dialogs.ShowDialog(DialogNames.AddBookmarkDialog, value, async e =>
+                dialogs.ShowDialog(DialogNames.AddBookmarkDialog, value, e =>
                 {
                     if (e.Result == ButtonResult.OK && e.Parameters != null)
                     {
@@ -347,30 +348,44 @@ namespace PDF_Office.ViewModels.BOTA
         {
             if (listView.SelectedItem != bookmark)
             {
-                listView.SelectedItem = bookmark;
-                listView.ScrollIntoView(bookmark);
-                ListViewItem myListBoxItem = (ListViewItem)(listView.ItemContainerGenerator.ContainerFromItem(bookmark));
-                TextBox textBox = CommonHelper.FindVisualChild<TextBox>(myListBoxItem);
-                TextBlock textBlock = CommonHelper.FindVisualChild<TextBlock>(myListBoxItem);
-                textBlock.Visibility = Visibility.Collapsed;
-
-                textBox.Focus();
-                textBox.SelectAll();
+                //listView.SelectedItem = bookmark;
+                //listView.ScrollIntoView(bookmark);
+
+                //ListViewItem myListBoxItem = (ListViewItem)(listView.ItemContainerGenerator.ContainerFromItem(bookmark));
                 //if (myListBoxItem == null)
                 //{
-                //    await Task.Delay(3);
-                //    while (listView.RenderSize.Width <= 0 && listView.RenderSize.Height <= 0)
-                //    {
-                //        await Task.Delay(3);
-                //    }
+                //    listView.UpdateLayout();
+                //    listView.ScrollIntoView(bookmark);
                 //    myListBoxItem = (ListViewItem)(listView.ItemContainerGenerator.ContainerFromItem(bookmark));
-                //    TextBox textBox = CommonHelper.FindVisualChild<TextBox>(myListBoxItem);
-                //    TextBlock textBlock = CommonHelper.FindVisualChild<TextBlock>(myListBoxItem);
-                //    textBlock.Visibility = Visibility.Collapsed;
-
-                //    textBox.Focus();
-                //    textBox.SelectAll();
                 //}
+
+                listView.ItemContainerGenerator.StatusChanged += (sender, e) =>
+                {
+                    listView.Dispatcher.Invoke(() =>
+                    {
+                        if (listView.ItemContainerGenerator.Status == GeneratorStatus.ContainersGenerated)
+                        {
+                            ListViewItem myListBoxItem = (ListViewItem)(listView.ItemContainerGenerator.ContainerFromItem(bookmark));
+                            if (myListBoxItem != null)
+                            {
+                                myListBoxItem.IsSelected = true;
+
+                                if (myListBoxItem.RenderSize.Width < 0 && myListBoxItem.RenderSize.Height < 0)
+                                {
+                                    listView.UpdateLayout();
+                                    myListBoxItem.UpdateLayout();
+                                    listView.ScrollIntoView(bookmark);
+                                }
+                                TextBox textBox = CommonHelper.FindVisualChild<TextBox>(myListBoxItem);
+                                TextBlock textBlock = CommonHelper.FindVisualChild<TextBlock>(myListBoxItem);
+                                textBlock.Visibility = Visibility.Collapsed;
+
+                                textBox.Focus();
+                                textBox.SelectAll();
+                            }
+                        }
+                    });
+                };
             }
         }
 
@@ -378,6 +393,11 @@ namespace PDF_Office.ViewModels.BOTA
         {
             bool isExistBookmark = false;
             int index = PDFViewer.CurrentIndex;
+            if (PDFViewer.Document == null)
+            {
+                isExistBookmark = true;
+                return isExistBookmark;
+            }
             //检测是否已存在相同数据
             var list = PDFViewer.Document.GetBookmarkList().FindAll(q => q.PageIndex == index);
 
@@ -420,8 +440,6 @@ namespace PDF_Office.ViewModels.BOTA
 
         private ListViewItem selectListViewItem = null;
 
-
-
         public void OnNavigatedTo(NavigationContext navigationContext)
         {
             navigationContext.Parameters.TryGetValue<CPDFViewer>(ParameterNames.PDFViewer, out PDFViewer);

+ 13 - 12
PDF Office/ViewModels/Dialog/ToolsDialogs/MergeDialogViewModel.cs

@@ -244,31 +244,32 @@ namespace PDF_Office.ViewModels.Dialog.ToolsDialogs
                 case PageSizeType.kDefault:
                     break;
                 case PageSizeType.A4:
-                    rect.Width = 210;
-                    rect.Height = 297;
+
+                    rect.Width = CommonHelper.GetPageSizeFomrUnit(210);
+                    rect.Height = CommonHelper.GetPageSizeFomrUnit(297);
                     break;
                 case PageSizeType.A3:
-                    rect.Width = 297;
-                    rect.Height = 420;
+                    rect.Width = CommonHelper.GetPageSizeFomrUnit(297);
+                    rect.Height = CommonHelper.GetPageSizeFomrUnit(420);
                     break;
                 case PageSizeType.Letter:
-                    rect.Width = 216;
-                    rect.Height = 279;
+                    rect.Width = CommonHelper.GetPageSizeFomrUnit(216);
+                    rect.Height = CommonHelper.GetPageSizeFomrUnit(279);
                     break;
                 case PageSizeType.Legal:
-                    rect.Width = 216;
-                    rect.Height = 356;
+                    rect.Width = CommonHelper.GetPageSizeFomrUnit(216);
+                    rect.Height = CommonHelper.GetPageSizeFomrUnit(356);
                     break;
                 case PageSizeType.Customized:
                     if (!string.IsNullOrEmpty(InputWidth) && !string.IsNullOrEmpty(InputHeight))
                     {
-                        rect.Width = Convert.ToInt32(InputWidth);
-                        rect.Height = Convert.ToInt32(InputHeight);
+                        rect.Width = CommonHelper.GetPageSizeFomrUnit(Convert.ToInt32(InputWidth));
+                        rect.Height = CommonHelper.GetPageSizeFomrUnit(Convert.ToInt32(InputHeight));
                     }
                     else
                     {
-                        rect.Width = 595;
-                        rect.Height = 841;
+                        rect.Width = CommonHelper.GetPageSizeFomrUnit(595);
+                        rect.Height = CommonHelper.GetPageSizeFomrUnit(841);
                     }
                     break;
                 default:

+ 17 - 4
PDF Office/ViewModels/PropertyPanel/AnnotPanel/LinkAnnotPropertyViewModel.cs

@@ -97,6 +97,7 @@ namespace PDF_Office.ViewModels.PropertyPanel.AnnotPanel
                 {
                     ImagePreviewVisibility = Visibility.Collapsed;
                     BtnGOorBackVisibility = Visibility.Collapsed;
+                    BtnLocationIsEnabled = false;
                 }
                 return pageNumTextContent;
             }
@@ -314,6 +315,17 @@ namespace PDF_Office.ViewModels.PropertyPanel.AnnotPanel
             }
         }
 
+        private bool btnLocationIsChecked = false;
+
+        public bool BtnLocationIsChecked
+        {
+            get { return btnLocationIsChecked; }
+            set
+            {
+                SetProperty(ref btnLocationIsChecked, value);
+            }
+        }
+
         private WriteableBitmap previewImage;
 
         public WriteableBitmap PreviewImage
@@ -671,14 +683,14 @@ namespace PDF_Office.ViewModels.PropertyPanel.AnnotPanel
         /// <summary>
         /// 定位目标范围
         /// </summary>
-        /// <param name="obj"></param> 
+        /// <param name="obj"></param>
         private void LocationPage(object obj)
         {
             pdfViewer.EnableDrawSelectArea(true);
             historyPageIndex = pdfViewer.CurrentIndex;
             PageNumTextIsEnabled = false;
             isSelected = false;
-
+            BtnLocationIsChecked = true;
             bool isExist = false;
             if (region.Regions.ContainsRegionWithName(viewContentViewModel.TipContentRegionName))
             {
@@ -696,7 +708,7 @@ namespace PDF_Office.ViewModels.PropertyPanel.AnnotPanel
             {
                 region.RequestNavigate(viewContentViewModel.TipContentRegionName, "LinkAnnotTip");
             }
-            if(string.IsNullOrEmpty(PageNumTextContent))
+            //if(string.IsNullOrEmpty(PageNumTextContent))
             viewContentViewModel.ShowTip(true);
         }
 
@@ -953,7 +965,7 @@ namespace PDF_Office.ViewModels.PropertyPanel.AnnotPanel
         {
             ImagePreviewVisibility = Visibility.Visible;
             BtnGOorBackVisibility = Visibility.Visible;
-
+            BtnLocationIsEnabled = true;
             int dpiHeight = (int)ImagePreviewHeight;
             int dpiWidth = (int)ImagePreviewWidth;
             if (dpiHeight <= 0 || dpiWidth <= 0)
@@ -1107,6 +1119,7 @@ namespace PDF_Office.ViewModels.PropertyPanel.AnnotPanel
                         pdfViewer.GoToPage(historyPageIndex);
                         //viewContentViewModel.LinkAnnotTipVisibility = Visibility.Collapsed;
                         viewContentViewModel.TipVisible = Visibility.Collapsed;
+                        BtnLocationIsChecked = false;
                     }
                 }
             }

+ 8 - 7
PDF Office/ViewModels/Tools/AnnotToolContentViewModel.Command.cs

@@ -143,7 +143,6 @@ namespace PDF_Office.ViewModels.Tools
                         if (e.IsAnnotCreateReset == false)
                         {
                             GetSelectedAnnots(e);
-                            //PDFViewer.SetToolParam(annot);
                         }
                         else
                         {
@@ -211,13 +210,11 @@ namespace PDF_Office.ViewModels.Tools
                             }
                         }
 
-
                         if (isDifferentAnnotTyle)
                             viewContentViewModel.SelectedPrpoertyPanel("PropertyPanelContent", null);
                         else
                             GetSelectedAnnots(e);
                     }
-
                 }
 
                 //注释列表同步选中
@@ -244,10 +241,9 @@ namespace PDF_Office.ViewModels.Tools
             }
             else
             {
-
-                viewContentViewModel.SelectedPrpoertyPanel("PropertyPanelContent", null);
+                if (BtnLinkIsChecked == false)
+                    viewContentViewModel.SelectedPrpoertyPanel("PropertyPanelContent", null);
             }
-
         }
 
         private bool isShapAnnot(AnnotHandlerEventArgs annot)
@@ -383,23 +379,29 @@ namespace PDF_Office.ViewModels.Tools
                                     case AnnotArgsType.AnnotSquiggly:
                                         e.PopupMenu = SelectHightAnnotMenu(selectedAnnot);
                                         break;
+
                                     case AnnotArgsType.AnnotFreehand:
                                         e.PopupMenu = SelectFreeHandAnnotMenu(selectedAnnot);
                                         break;
+
                                     case AnnotArgsType.AnnotFreeText:
                                         e.PopupMenu = SelectFreeTextAnnotMenu(selectedAnnot);
                                         break;
+
                                     case AnnotArgsType.AnnotSticky:
                                         e.PopupMenu = SelectStrickNoteAnnotMenu(selectedAnnot);
                                         break;
+
                                     case AnnotArgsType.AnnotSquare:
                                     case AnnotArgsType.AnnotLine:
                                     case AnnotArgsType.AnnotCircle:
                                         e.PopupMenu = SelectShapeAnnotMenu(selectedAnnot);
                                         break;
+
                                     case AnnotArgsType.AnnotLink:
                                         e.PopupMenu = SelectHightAnnotMenu(selectedAnnot);
                                         break;
+
                                     case AnnotArgsType.AnnotStamp:
                                         e.PopupMenu = SelectHightAnnotMenu(selectedAnnot);
                                         break;
@@ -419,7 +421,6 @@ namespace PDF_Office.ViewModels.Tools
 
                                 e.PopupMenu = SelectMultiAnnotMenu(e.AnnotEventArgsList, isHigh);
                             }
-
                         }
                         if (e.PopupMenu != null)
                         {

+ 5 - 7
PDF Office/ViewModels/Tools/AnnotToolContentViewModel.Layout.cs

@@ -31,7 +31,6 @@ namespace PDF_Office.ViewModels.Tools
         /// <param name="annotAttribsList">更改注释属性的键值对,更改值后会自动记录undoRedo容器里</param>
         private void AddToPropertyPanel(string viewContent, string toolTag = null, List<AnnotHandlerEventArgs> annots = null, Dictionary<AnnotAttrib, object> annotAttribsList = null, AnnotAttribEvent annotAttribEvent = null)
         {
-
             if (annots != null)
             {
                 propertyPanel.annotlists = annots;
@@ -83,6 +82,7 @@ namespace PDF_Office.ViewModels.Tools
         #endregion 属性面板
 
         #region 阅读页 - 右键菜单
+
         private ContextMenu ViewerContextMenu()
         {
             ContextMenu contextMenu = App.Current.FindResource("ViewerContextMenu") as ContextMenu;
@@ -91,7 +91,6 @@ namespace PDF_Office.ViewModels.Tools
             return contextMenu;
         }
 
-
         private void ViewerContextMenu_Loaded(object sender, RoutedEventArgs e)
         {
             ContextMenu contextMenu = sender as ContextMenu;
@@ -159,8 +158,9 @@ namespace PDF_Office.ViewModels.Tools
                                 break;
 
                             case "AddBookMark":
-                                menuItem1.Click -= AddBookMark_Click;
-                                menuItem1.Click += AddBookMark_Click;
+                                //menuItem1.Click -= AddBookMark_Click;
+                                //menuItem1.Click += AddBookMark_Click;
+                                menuItem1.Command = AddBookMarkCommand;
                                 SetMenuItemVisibility(menuItem1, "DelBookMark", "AddBookMark", isAddBookMark);
                                 break;
 
@@ -575,8 +575,6 @@ namespace PDF_Office.ViewModels.Tools
             return popMenu;
         }
 
-
         #endregion 注释-右键菜单
-
     }
-}
+}

+ 4 - 6
PDF Office/ViewModels/Tools/AnnotToolContentViewModel.Properties.cs

@@ -48,13 +48,11 @@ namespace PDF_Office.ViewModels.Tools
             {
                 if (item > 0)
                 {
-
                     isSolid = false;
                     break;
                 }
             }
             return isSolid;
-
         }
 
         public static DashStyle GetLineDashStyle(bool isSolid)
@@ -76,7 +74,6 @@ namespace PDF_Office.ViewModels.Tools
         //单个属性更改
         public void UpdateAnnotAAttrib(AnnotAttrib annotAttrib, object obj)
         {
-
             if (annotlists != null && annotlists.Count > 1)
             {
                 foreach (var itemevent in AnnotEvents)
@@ -90,7 +87,6 @@ namespace PDF_Office.ViewModels.Tools
                 AnnotEvent?.UpdateAttrib(annotAttrib, obj);
                 AnnotEvent?.UpdateAnnot();
             }
-
         }
 
         //多个属性更改
@@ -117,11 +113,12 @@ namespace PDF_Office.ViewModels.Tools
 
                 AnnotEvent?.UpdateAnnot();
             }
-
         }
 
         //是否为多选
-        public bool IsMultiSelected { get { return (annotlists != null && annotlists.Count > 1); } }
+        public bool IsMultiSelected
+        { get { return (annotlists != null && annotlists.Count > 1); } }
+
         /// <summary>
         /// 更新多个属性,触发到工具栏注释工具,改变工具图标下的颜色值
         /// </summary>
@@ -258,6 +255,7 @@ namespace PDF_Office.ViewModels.Tools
         private SnapshotEditMenuViewModel snapshotEditMenuViewModel = new SnapshotEditMenuViewModel();
         public SnapshotEditMenuViewModel SnapshotEditMenuViewModel { get => snapshotEditMenuViewModel; set => snapshotEditMenuViewModel = value; }
         public DelegateCommand<object> SetAddAnnotationCommand { get; set; }
+        public DelegateCommand AddBookMarkCommand { get; set; }
 
         #region 注释 - 右键菜单
         //公共

+ 2 - 30
PDF Office/ViewModels/Tools/AnnotToolContentViewModel.cs

@@ -58,6 +58,7 @@ namespace PDF_Office.ViewModels.Tools
         {
             MyToolsCommand = new DelegateCommand<CustomIconToggleBtn>(BtnMyTools_Click);
             SetAddAnnotationCommand = new DelegateCommand<object>(AddAnnotation_Click);
+            AddBookMarkCommand = new DelegateCommand(AddBookMark_Click);
             PropertyRegionName = Guid.NewGuid().ToString();
 
             #region 注释 - 右键菜单
@@ -429,34 +430,6 @@ namespace PDF_Office.ViewModels.Tools
             }
         }
 
-        private void BookMark(MenuItem addBookMark, MenuItem delBookMark)
-        {
-            int index = PDFViewer.CurrentIndex;
-            //检测是否已存在相同数据
-            CPDFBookmark list = PDFViewer.Document.GetBookmarkList().FirstOrDefault(q => q.PageIndex == index);
-            if (list != null)
-            {
-                isAddBookMark = false;
-            }
-            else
-            {
-                isAddBookMark = true;
-            }
-
-            if (isAddBookMark)
-            {
-                addBookMark.Visibility = Visibility.Visible;
-                delBookMark.Visibility = Visibility.Collapsed;
-                addBookMark.Click += AddBookMark_Click;
-            }
-            else
-            {
-                delBookMark.Visibility = Visibility.Visible;
-                addBookMark.Visibility = Visibility.Collapsed;
-                delBookMark.Click += DelBookMark_Click;
-            }
-        }
-
         private void DelBookMark_Click(object sender, RoutedEventArgs e)
         {
             if (viewContentViewModel.OpenBOTA == false)
@@ -473,7 +446,6 @@ namespace PDF_Office.ViewModels.Tools
             int index = PDFViewer.CurrentIndex;
             //检测是否已存在相同数据
             CPDFBookmark list = PDFViewer.Document.GetBookmarkList().FirstOrDefault(q => q.PageIndex == index);
-
             if (bookmarkContentViewModel != null && bookmark != null && bOTAContent != null && list != null)
             {
                 bookmarkContentViewModel.DeleteCommand.Execute(list);
@@ -489,7 +461,7 @@ namespace PDF_Office.ViewModels.Tools
             //}
         }
 
-        private async void AddBookMark_Click(object sender, RoutedEventArgs e)
+        private void AddBookMark_Click()
         {
             if (viewContentViewModel.OpenBOTA == false)
             {

+ 2 - 3
PDF Office/Views/Dialog/SettingsDialog.xaml

@@ -311,12 +311,12 @@
                                         Height="30"
                                         ItemsSource="{Binding PageViewList}"
                                         SelectedIndex="{Binding PageViewSelctedIndex, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}">
-                                        <ComboBoxItem Content="单页" Foreground="{StaticResource color.field.text.act}" />
+                                        <!--<ComboBoxItem Content="单页" Foreground="{StaticResource color.field.text.act}" />
                                         <ComboBoxItem Content="单页连续" Foreground="{StaticResource color.field.text.act}" />
                                         <ComboBoxItem Content="双页" Foreground="{StaticResource color.field.text.act}" />
                                         <ComboBoxItem Content="双页连续" Foreground="{StaticResource color.field.text.act}" />
                                         <ComboBoxItem Content="书本" Foreground="{StaticResource color.field.text.act}" />
-                                        <ComboBoxItem Content="书本连续" Foreground="{StaticResource color.field.text.act}" />
+                                        <ComboBoxItem Content="书本连续" Foreground="{StaticResource color.field.text.act}" />-->
                                     </ComboBox>
                                 </WrapPanel>
                                 <WrapPanel Grid.Row="1" Margin="0,12">
@@ -329,7 +329,6 @@
                                         Height="30"
                                         ItemsSource="{Binding ZoomModeList}"
                                         SelectedIndex="{Binding ZoomModeSelectedIndex, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}">
-  
                                     </ComboBox>
                                 </WrapPanel>
                             </Grid>

+ 170 - 64
PDF Office/Views/Dialog/ToolsDialogs/MergeDialog.xaml

@@ -16,13 +16,68 @@
         <dataconvert:UnVisivleConvert x:Key="UnVisivleConvert" />
         <dataconvert:ListCountToVisible x:Key="ListCountToVisible"/>
         <dataconvert:UnVisibleToBoolConvert x:Key="UnVisibleToBoolConvert"/>
+        <PathGeometry x:Key="Ic_ClearButtonPath" Figures="M6 1.75H10V0.25H6V1.75ZM1 4.25H2.25V15C2.25 15.4142 2.58579 15.75 3 15.75H13C13.4142 15.75 13.75 15.4142 13.75 15V4.25H15V2.75H1V4.25ZM3.75 14.25V4.25H12.25V14.25H3.75ZM7.25 6.5V11.5H8.75V6.5H7.25Z" />
+        <PathGeometry x:Key="Ic_DeleteButtonPath" Figures="M8 15C11.866 15 15 11.866 15 8C15 4.13401 11.866 1 8 1C4.13401 1 1 4.13401 1 8C1 11.866 4.13401 15 8 15ZM11.5303 5.53038L9.06069 8L11.5303 10.4696L10.4697 11.5303L8.00002 9.06066L5.53033 11.5303L4.46967 10.4697L6.93936 8L4.46967 5.53033L5.53033 4.46967L8.00002 6.93934L10.4697 4.46971L11.5303 5.53038Z" />
+        <SolidColorBrush x:Key="Item.MouseOver.Background" Color="#1F26A0DA"/>
+        <SolidColorBrush x:Key="Item.MouseOver.Border" Color="#a826A0Da"/>
+        <SolidColorBrush x:Key="Item.SelectedInactive.Background" Color="#3DDADADA"/>
+        <SolidColorBrush x:Key="Item.SelectedInactive.Border" Color="#FFDADADA"/>
+        <SolidColorBrush x:Key="Item.SelectedActive.Background" Color="#3D26A0DA"/>
+        <SolidColorBrush x:Key="Item.SelectedActive.Border" Color="#FF26A0DA"/>
+        <Style x:Key="ListViewItemStyle1" TargetType="{x:Type ListViewItem}">
+            <Setter Property="SnapsToDevicePixels" Value="True"/>
+            <Setter Property="Padding" Value="0,2,0,0"/>
+            <Setter Property="HorizontalContentAlignment" Value="{Binding HorizontalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}"/>
+            <Setter Property="VerticalContentAlignment" Value="{Binding VerticalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}"/>
+            <Setter Property="Background" Value="Transparent"/>
+            <Setter Property="BorderBrush" Value="Transparent"/>
+            <Setter Property="BorderThickness" Value="0"/>
+            <Setter Property="FocusVisualStyle" Value="{StaticResource FocusVisual}"/>
+            <Setter Property="Template">
+                <Setter.Value>
+                    <ControlTemplate TargetType="{x:Type ListViewItem}">
+                        <Border Grid.Row="2" CornerRadius="8" x:Name="Bd" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Padding="{TemplateBinding Padding}" SnapsToDevicePixels="true">
+                                <ContentPresenter  HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
+                            </Border>
+                            <ControlTemplate.Triggers>
+                            <MultiTrigger>
+                                <MultiTrigger.Conditions>
+                                    <Condition Property="IsMouseOver" Value="True"/>
+                                </MultiTrigger.Conditions>
+                                <Setter Property="Background" TargetName="Bd" Value="{StaticResource color.item-state.hov.bg}"/>
+                                <Setter Property="BorderBrush" TargetName="Bd" Value="{StaticResource color.item-state.hov.bg}"/>
+                            </MultiTrigger>
+                            <MultiTrigger>
+                                <MultiTrigger.Conditions>
+                                    <Condition Property="Selector.IsSelectionActive" Value="False"/>
+                                    <Condition Property="IsSelected" Value="True"/>
+                                </MultiTrigger.Conditions>
+                                <Setter Property="Background" TargetName="Bd" Value="{StaticResource Item.SelectedInactive.Background}"/>
+                                <Setter Property="BorderBrush" TargetName="Bd" Value="{StaticResource Item.SelectedInactive.Border}"/>
+                            </MultiTrigger>
+                            <MultiTrigger>
+                                <MultiTrigger.Conditions>
+                                    <Condition Property="Selector.IsSelectionActive" Value="True"/>
+                                    <Condition Property="IsSelected" Value="True"/>
+                                </MultiTrigger.Conditions>
+                                <Setter Property="Background" TargetName="Bd" Value="{StaticResource color.item-state.hov.bg}"/>
+                                <Setter Property="BorderBrush" TargetName="Bd" Value="{StaticResource color.item-state.hov.bg}"/>
+                            </MultiTrigger>
+                            <Trigger Property="IsEnabled" Value="False">
+                                <Setter Property="TextElement.Foreground" TargetName="Bd" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
+                            </Trigger>
+                        </ControlTemplate.Triggers>
+                    </ControlTemplate>
+                </Setter.Value>
+            </Setter>
+        </Style>
     </UserControl.Resources>
     <Grid Background="{StaticResource color.sys.layout.anti}">
         <Grid.ColumnDefinitions>
             <ColumnDefinition Width="16"/>
-            <ColumnDefinition Width="558"/>
-            <ColumnDefinition Width="260"/>
+            <ColumnDefinition Width="526"/>
             <ColumnDefinition Width="16"/>
+            <ColumnDefinition Width="260"/>
         </Grid.ColumnDefinitions>
         <Grid.RowDefinitions>
             <RowDefinition Height="16"/>
@@ -33,6 +88,14 @@
             <RowDefinition Height="50"/>
             <RowDefinition Height="16"/>
         </Grid.RowDefinitions>
+
+        <Border Grid.Column="1" Grid.Row="1"  Grid.RowSpan="2" Padding="50,6,50,6" Visibility="{Binding Visibility, Converter={StaticResource UnVisivleConvert}, ElementName=NoFileStackPanel}">
+            <Grid>
+                <TextBlock Text="File Name" HorizontalAlignment="Left" FontFamily="Segoe UI" FontSize="12" FontWeight="Bold" Foreground="{StaticResource color.sys.text.neutral.lv1}"/>
+                <TextBlock Text="Page Range" HorizontalAlignment="Center" FontFamily="Segoe UI" FontSize="12" FontWeight="Bold" Foreground="{StaticResource color.sys.text.neutral.lv1}"/>
+                <TextBlock Text="Size" HorizontalAlignment="Right" FontFamily="Segoe UI" FontSize="12" FontWeight="Bold" Foreground="{StaticResource color.sys.text.neutral.lv1}"/>
+            </Grid>
+        </Border>
         <Border Grid.Column="1" Grid.Row="3">
             <Grid AllowDrop="True" Background="{StaticResource color.sys.layout.anti}"
                 PreviewDrop="Grid_Drop"
@@ -50,8 +113,10 @@
                     <TextBlock Text="Selected files" FontSize="14" FontFamily="Segoe UI" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                     <TextBlock Text="Drop files here or Click Add Files at bottom right button. You can drag files to reorder as you need." FontSize="14" FontFamily="Segoe UI" HorizontalAlignment="Center" TextAlignment="Center" VerticalAlignment="Center" TextWrapping="Wrap"/>
                 </StackPanel>
-                <ListView x:Name="MergeView" AllowDrop="True" 
-                Visibility="{Binding ElementName=NoFileStackPanel,Path=Visibility,Converter={StaticResource UnVisivleConvert}}"          
+                    <ListView x:Name="MergeView" AllowDrop="True"
+                ItemContainerStyle="{StaticResource ListViewItemStyle1}"
+                BorderThickness="0"
+                Visibility="{Binding Visibility, Converter={StaticResource UnVisivleConvert}, ElementName=NoFileStackPanel}"          
                 Drop="MergeView_Drop"
                 DragEnter="MergeView_DragEnter"
                 DragOver="MergeView_DragOver"
@@ -60,107 +125,134 @@
                 ItemsSource="{Binding MergeObjectlist}"
                 ScrollViewer.HorizontalScrollBarVisibility="Disabled"
                 HorizontalContentAlignment="Stretch">
-                    <ListView.ItemTemplate>
-                        <DataTemplate  >
-                            <Grid x:Name="ContentPanel" >
-                                <Grid.ColumnDefinitions>
-                                    <ColumnDefinition Width="Auto"/>
-                                    <ColumnDefinition Width="*"/>
-                                    <ColumnDefinition Width="*"/>
-                                    <ColumnDefinition Width="*"/>
-                                    <ColumnDefinition Width="*"/>
-                                    <ColumnDefinition Width="*"/>
-                                </Grid.ColumnDefinitions>
-                                <TextBlock Text="{Binding RelativeSource={RelativeSource FindAncestor, 
-                                         AncestorType={x:Type ListViewItem}}, 
-                                         Converter={StaticResource IndexConverter}}"
-                                 VerticalAlignment="Center"  HorizontalAlignment="Center"/>
-                                <Image Grid.Column="1" Width="50" Height="50" HorizontalAlignment="Center" VerticalAlignment="Center" Source="{Binding DocThumbnail}"  Stretch="Uniform"  />
-                                <StackPanel Grid.Column="2" HorizontalAlignment="Center" VerticalAlignment="Center">
-                                    <TextBlock Text="{Binding DocName}" TextTrimming="CharacterEllipsis"/>
-                                    <TextBlock Text="{Binding DocPageCount}" />
-                                </StackPanel>
-                                <StackPanel Grid.Column="3" HorizontalAlignment="Center" VerticalAlignment="Center">
-                                    <customcontrol:WritableComboBox SelectedIndex="0" MaxPageRange="{Binding SDKPageCount}" Text="{Binding SetPageRange,Mode=TwoWay}"/>
-                                </StackPanel>
-                                <TextBlock Grid.Column="4" Text="{Binding DocSize}"  HorizontalAlignment="Center" VerticalAlignment="Center"/>
-                                <StackPanel Grid.Column="5" VerticalAlignment="Center">
-                                    <Button Content="删除" Click="Delete_Click"/>
-                                </StackPanel>
+                        <ListView.ItemTemplate>
+                            <DataTemplate  >
+                                <StackPanel>
+                                    <Line  X1="0"  X2="{Binding ActualWidth, ElementName=ContentPanel}" HorizontalAlignment="Stretch" StrokeThickness="1" Stroke="{StaticResource color.item-state.hov.bg}" VerticalAlignment="Bottom"/>
+                                    <Grid x:Name="ContentPanel" Height="76" >
+                                        <Grid.ColumnDefinitions>
+                                            <ColumnDefinition Width="40"/>
+                                            <ColumnDefinition Width="60"/>
+                                            <ColumnDefinition Width="141"/>
+                                            <ColumnDefinition Width="auto"/>
+                                            <ColumnDefinition Width="*"/>
+                                            <ColumnDefinition Width="16"/>
+                                            <ColumnDefinition Width="16"/>
+                                        </Grid.ColumnDefinitions>
+                                        <Line   Margin="0,0,0,0" Grid.ColumnSpan="6" Visibility="{Binding IsForward, Converter={StaticResource BoolToVisible}}" X1="0"  X2="{Binding ActualWidth, ElementName=ContentPanel}" HorizontalAlignment="Stretch" VerticalAlignment="Bottom" StrokeThickness="1" Stroke="{StaticResource color.sys.layout.accent}" />
 
-                                <StackPanel Grid.ColumnSpan="5" Visibility="{Binding IsForward, Converter={StaticResource BoolToVisible}}" Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Bottom">
-                                    <Line  Margin="0,0,0,0" X1="0"  X2="{Binding ElementName=ContentPanel,Path=ActualWidth}" HorizontalAlignment="Stretch" StrokeThickness="1.5" Stroke="#FF0078D7" VerticalAlignment="Bottom"/>
-                                </StackPanel>
+                                        <Line Margin="0,0,0,0" Grid.ColumnSpan="6" Visibility="{Binding IsBackwards, Converter={StaticResource BoolToVisible}}"  X1="0"  X2="{Binding ActualWidth, ElementName=ContentPanel}" HorizontalAlignment="Stretch" VerticalAlignment="Top" StrokeThickness="1" Stroke="{StaticResource color.sys.layout.accent}" />
 
-                                <StackPanel Grid.ColumnSpan="5" Visibility="{Binding IsBackwards, Converter={StaticResource BoolToVisible}}" Orientation="Horizontal" HorizontalAlignment="Stretch" VerticalAlignment="Top">
-                                    <Line  X1="0"  X2="{Binding ElementName=ContentPanel,Path=ActualWidth}" HorizontalAlignment="Stretch" StrokeThickness="1.5" Stroke="Red" VerticalAlignment="Bottom"/>
+                                        <TextBlock Text="{Binding Converter={StaticResource IndexConverter}, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type ListViewItem}}}"
+                                 VerticalAlignment="Center"  HorizontalAlignment="Center"/>
+                                        <Image Margin="8" Grid.Column="1"  HorizontalAlignment="Stretch" VerticalAlignment="Center" Source="{Binding DocThumbnail}"  Stretch="Uniform"  />
+                                        <StackPanel Grid.Column="2" Margin="16,0,0,0" HorizontalAlignment="Stretch" VerticalAlignment="Center">
+                                            <TextBlock Text="{Binding DocName}" FontFamily="Segoe UI" FontSize="14" FontWeight="Regular" Foreground="{StaticResource color.sys.text.neutral.lv1}"  TextTrimming="CharacterEllipsis"/>
+                                            <TextBlock Text="{Binding DocPageCount}"  FontFamily="Segoe UI" FontSize="14" FontWeight="Regular" Foreground="{StaticResource color.sys.text.neutral.lv3}"/>
+                                        </StackPanel>
+                                        <StackPanel Grid.Column="3" HorizontalAlignment="Stretch" VerticalAlignment="Center" Margin="16,0,0,0">
+                                            <customcontrol:WritableComboBox SelectedIndex="0" Width="150" Height="30" MaxPageRange="{Binding SDKPageCount}" Text="{Binding SetPageRange, Mode=TwoWay}"/>
+                                        </StackPanel>
+                                        <TextBlock Grid.Column="4" Text="{Binding DocSize}"  HorizontalAlignment="Stretch" VerticalAlignment="Center" Margin="16,0,0,0"/>
+                                        <StackPanel Grid.Column="5" VerticalAlignment="Center" HorizontalAlignment="Stretch" Margin="0,0">
+
+                                            <customcontrol:PathButton
+            Visibility="Collapsed"
+            HorizontalAlignment="Center"
+            VerticalAlignment="Center"
+            VerticalContentAlignment="Center"
+            x:Name="DeleteIcon"
+            Width="16" Height="16"
+           Click="Delete_Click"
+            Icon="{StaticResource Ic_DeleteButtonPath}" IconFill="#616469"
+            IconHeight="16" IconWidth="16"
+            IconMouseOver="{StaticResource Ic_DeleteButtonPath}" IconMouseOverFill="#616469"
+            IconPress="{StaticResource Ic_DeleteButtonPath}" IconPressFill="#616469"
+            CornerRadius="4"  HorizontalContentAlignment="Center"
+            MouseOverBackground="{StaticResource color.item-state.hov.bg}"
+            MouseDownBackground="{StaticResource color.item-state.sel.bg.lv3}"                          
+            MouseDownBorderBrush="{StaticResource color.item-state.sel.border.lv3}"
+                    />
+                                        </StackPanel>
+                                    </Grid>
                                 </StackPanel>
-                            </Grid>
+                            <DataTemplate.Triggers>
+                                <Trigger Property="IsMouseOver" Value="True">
+                                    <Setter TargetName="DeleteIcon" Property="Visibility" Value="Visible" />
+                                </Trigger>
+                            </DataTemplate.Triggers>
                         </DataTemplate>
-                    </ListView.ItemTemplate>
-                </ListView>
+                        </ListView.ItemTemplate>
+                    </ListView>
             </Grid>
         </Border>
-        <Border Grid.Column="2" Grid.Row="3">
+        <Border Grid.Column="3" Grid.RowSpan="7" Background="{StaticResource color.sys.layout.mg}">
             <Grid>
                 <Grid.RowDefinitions>
-                    <RowDefinition Height="20"/>
+                    <RowDefinition Height="14"/>
                     <RowDefinition Height="*"/>
+                    <RowDefinition Height="auto"/>
+                    <RowDefinition Height="16"/>
                 </Grid.RowDefinitions>
-                <TextBlock Text=" Page Size"/>
-                <StackPanel Grid.Row="1">
-                    <RadioButton Content="Original page size" Tag="0">
+                <Grid.ColumnDefinitions>
+                    <ColumnDefinition Width="16"/>
+                    <ColumnDefinition Width="*"/>
+                    <ColumnDefinition Width="16"/>
+                </Grid.ColumnDefinitions>
+                <StackPanel Grid.Row="1" Grid.Column="1">
+                    <TextBlock Text=" Page Size" VerticalAlignment="Center" FontSize="14" FontFamily="Segoe UI" FontWeight="Bold"/>
+                    <RadioButton Content="Original page size" FontWeight="Regular" FontSize="14" FontFamily="Segoe UI" Tag="0" Margin="0,14,0,0">
                         <i:Interaction.Triggers>
                             <i:EventTrigger EventName="Checked">
                                 <i:InvokeCommandAction Command="{Binding SetPageSizeTypeCommand}" CommandParameter="{Binding RelativeSource={RelativeSource AncestorType=RadioButton}}" PassEventArgsToCommand="True" />
                             </i:EventTrigger>
                         </i:Interaction.Triggers>
                     </RadioButton>
-                    <RadioButton Content="A4" Tag="1">
+                    <RadioButton Content="A4" Tag="1" FontWeight="Regular" FontSize="14" FontFamily="Segoe UI" Margin="0,8,0,0">
                         <i:Interaction.Triggers>
                             <i:EventTrigger EventName="Checked">
                                 <i:InvokeCommandAction Command="{Binding SetPageSizeTypeCommand}" CommandParameter="{Binding RelativeSource={RelativeSource AncestorType=RadioButton}}" PassEventArgsToCommand="True" />
                             </i:EventTrigger>
                         </i:Interaction.Triggers>
                     </RadioButton>
-                    <RadioButton Content="A3" Tag="2">
+                    <RadioButton Content="A3" Tag="2" FontWeight="Regular" FontSize="14" FontFamily="Segoe UI" Margin="0,8,0,0">
                         <i:Interaction.Triggers>
                             <i:EventTrigger EventName="Checked">
                                 <i:InvokeCommandAction Command="{Binding SetPageSizeTypeCommand}" CommandParameter="{Binding RelativeSource={RelativeSource AncestorType=RadioButton}}" PassEventArgsToCommand="True" />
                             </i:EventTrigger>
                         </i:Interaction.Triggers>
                     </RadioButton>
-                    <RadioButton Content="U.S.Letter" Tag="3">
+                    <RadioButton Content="U.S.Letter" Tag="3" FontWeight="Regular" FontSize="14" FontFamily="Segoe UI" Margin="0,8,0,0">
                         <i:Interaction.Triggers>
                             <i:EventTrigger EventName="Checked">
                                 <i:InvokeCommandAction Command="{Binding SetPageSizeTypeCommand}" CommandParameter="{Binding RelativeSource={RelativeSource AncestorType=RadioButton}}" PassEventArgsToCommand="True" />
                             </i:EventTrigger>
                         </i:Interaction.Triggers>
                     </RadioButton>
-                    <RadioButton Content="U.S.Legal" Tag="4">
+                    <RadioButton Content="U.S.Legal" Tag="4" FontWeight="Regular" FontSize="14" FontFamily="Segoe UI" Margin="0,8,0,0">
                         <i:Interaction.Triggers>
                             <i:EventTrigger EventName="Checked">
                                 <i:InvokeCommandAction Command="{Binding SetPageSizeTypeCommand}" CommandParameter="{Binding RelativeSource={RelativeSource AncestorType=RadioButton}}" PassEventArgsToCommand="True" />
                             </i:EventTrigger>
                         </i:Interaction.Triggers>
                     </RadioButton>
-                    <RadioButton x:Name="Customized" Content="Customized" Tag="5">
+                    <RadioButton x:Name="Customized" Content="Customized" Tag="5" FontWeight="Regular" FontSize="14" FontFamily="Segoe UI" Margin="0,8,0,0">
                         <i:Interaction.Triggers>
                             <i:EventTrigger EventName="Checked">
                                 <i:InvokeCommandAction Command="{Binding SetPageSizeTypeCommand}" CommandParameter="{Binding RelativeSource={RelativeSource AncestorType=RadioButton}}" PassEventArgsToCommand="True" />
                             </i:EventTrigger>
                         </i:Interaction.Triggers>
                     </RadioButton>
-                    <Grid IsEnabled="{Binding ElementName=Customized, Path=IsChecked}">
-                        <Grid.ColumnDefinitions>
-                            <ColumnDefinition Width="*"/>
-                            <ColumnDefinition Width="20"/>
-                            <ColumnDefinition Width="*"/>
-                        </Grid.ColumnDefinitions>
-                        <customcontrol:TextBoxEx PreviewKeyDown="TextBoxEx_PreviewKeyDown" x:Name="TextWidth" PlaceholderText="595" Text="{Binding InputWidth,Mode=TwoWay}"  PreviewTextInput="TextBox_PreviewTextInput" LostFocus="TextBoxEx_LostFocus"/>
-                        <TextBlock Text="X" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center"/>
-                        <customcontrol:TextBoxEx PreviewKeyDown="TextBoxEx_PreviewKeyDown" x:Name="TextHeight" PlaceholderText="841" Grid.Column="2" Text="{Binding InputHeight,Mode=TwoWay}" PreviewTextInput="TextBox_PreviewTextInput" LostFocus="TextBoxEx_LostFocus"/>
-                    </Grid>
+                    <StackPanel IsEnabled="{Binding ElementName=Customized, Path=IsChecked}" Margin="0,8,0,0" Orientation="Horizontal" HorizontalAlignment="Stretch">
+                        <customcontrol:TextBoxEx Width="85" PreviewKeyDown="TextBoxEx_PreviewKeyDown" x:Name="TextWidth" PlaceholderText="595" Text="{Binding InputWidth,Mode=TwoWay}"  PreviewTextInput="TextBox_PreviewTextInput" LostFocus="TextBoxEx_LostFocus"/>
+                        <TextBlock Text="X" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="8,0"/>
+                        <customcontrol:TextBoxEx Width="85" PreviewKeyDown="TextBoxEx_PreviewKeyDown" x:Name="TextHeight" PlaceholderText="841" Grid.Column="2" Text="{Binding InputHeight,Mode=TwoWay}" PreviewTextInput="TextBox_PreviewTextInput" LostFocus="TextBoxEx_LostFocus"/>
+                        <TextBlock Text="mm" VerticalAlignment="Center" FontWeight="Regular" FontSize="14" FontFamily="Segoe UI" Margin="8,0,0,0"/>
+                    </StackPanel>
+                </StackPanel>
+                <StackPanel Grid.Column="1" Grid.Row="2"  HorizontalAlignment="Center" VerticalAlignment="Bottom">
+                    <Button x:Name="BtnMerge" Width="228" Content="Merge"  Height="32" Style="{StaticResource Btn.cta}" Command="{Binding MergeCommand}" IsEnabled="{Binding ElementName=NoFileStackPanel,Path=Visibility,Converter={StaticResource UnVisibleToBoolConvert}}"/>
+                    <Button Margin="0,16,0,0" Width="228" Content="Cancel" Height="32" Style="{StaticResource btn.sec}" Command="{Binding CancelCommand}"/>
                 </StackPanel>
             </Grid>
         </Border>
@@ -201,10 +293,24 @@
 
             </ComboBoxItem>
         </ComboBox>
-        <Button Grid.Column="1" Grid.Row="5"  Content="Clear"  HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="80" Height="32" Style="{StaticResource btn.sec}" Command="{Binding ClearCommand}"/>
-        <StackPanel Grid.Column="2" Grid.RowSpan="2" Grid.Row="4"  HorizontalAlignment="Center" VerticalAlignment="Bottom">
-            <Button x:Name="BtnMerge" Content="Merge" Width="80" Height="32" Style="{StaticResource Btn.cta}" Command="{Binding MergeCommand}" IsEnabled="{Binding ElementName=NoFileStackPanel,Path=Visibility,Converter={StaticResource UnVisibleToBoolConvert}}"/>
-            <Button Content="Cancel" Width="80" Height="32" Style="{StaticResource btn.sec}" Command="{Binding CancelCommand}"/>
-        </StackPanel>
+        <Border BorderThickness="1" Width="32" Height="32" Grid.Column="1" Grid.Row="5" BorderBrush="{StaticResource color.btn.sec.border-color}" 
+            HorizontalAlignment="Right" VerticalAlignment="Bottom" CornerRadius="4">
+            <customcontrol:PathButton
+            HorizontalAlignment="Center"
+            VerticalAlignment="Center"
+            VerticalContentAlignment="Center"
+            x:Name="BtnAdd"
+            Width="32" Height="32"
+            Command="{Binding ClearCommand}"
+            Icon="{StaticResource Ic_ClearButtonPath}" IconFill="#616469"
+            IconHeight="16" IconWidth="16"
+            IconMouseOver="{StaticResource Ic_ClearButtonPath}" IconMouseOverFill="#616469"
+            IconPress="{StaticResource Ic_ClearButtonPath}" IconPressFill="#616469"
+            CornerRadius="4"  HorizontalContentAlignment="Center"
+            MouseOverBackground="{StaticResource color.item-state.hov.bg}"
+            MouseDownBackground="{StaticResource color.item-state.sel.bg.lv3}"                          
+            MouseDownBorderBrush="{StaticResource color.item-state.sel.border.lv3}"
+                    />
+        </Border>
     </Grid>
 </UserControl>

+ 22 - 13
PDF Office/Views/PropertyPanel/AnnotPanel/LinkAnnotProperty.xaml

@@ -35,10 +35,10 @@
         <StackPanel Background="White" Orientation="Vertical">
             <TextBlock
                 Name="AnnotTypeTitle"
-                Margin="0,12,0,12"
+                Margin="16,14,0,16"
                 HorizontalAlignment="Left"
                 FontFamily="Segoe UI"
-                FontSize="18"
+                FontSize="14"
                 FontWeight="Bold"
                 LineHeight="24">
                 Link
@@ -57,7 +57,8 @@
                     GroupName="LinkTab"
                     IsChecked="{Binding BtnLinkPageIsChecked}"
                     Style="{StaticResource PageViewRadioBtn}"
-                    Tag="Page">
+                    Tag="Page"
+                    Visibility="Collapsed">
                     <StackPanel>
                         <Path
                             Margin="8,8,8,8"
@@ -94,7 +95,8 @@
                     GroupName="LinkTab"
                     IsChecked="{Binding BtnLinkWebIsChecked}"
                     Style="{StaticResource PageViewRadioBtn}"
-                    Tag="Web">
+                    Tag="Web"
+                    Visibility="Collapsed">
                     <StackPanel>
                         <Path
                             Margin="8,8,8,8"
@@ -136,7 +138,8 @@
                     GroupName="LinkTab"
                     IsChecked="{Binding BtnLinkMailIsChecked}"
                     Style="{StaticResource PageViewRadioBtn}"
-                    Tag="Mail">
+                    Tag="Mail"
+                    Visibility="Collapsed">
                     <StackPanel>
                         <Path
                             Margin="8,8,8,8"
@@ -163,14 +166,16 @@
             Y1="0"
             Y2="0" />-->
             <Grid MinWidth="260">
-                <StackPanel Name="LinkPagePanel" Visibility="{Binding ElementName=BtnLinkPage, Path=IsChecked, Converter={StaticResource BoolToVisible}, Mode=OneWay}">
+                <!--<StackPanel Name="LinkPagePanel" Visibility="{Binding ElementName=BtnLinkPage, Path=IsChecked, Converter={StaticResource BoolToVisible}, Mode=OneWay}">-->
+                <StackPanel Name="LinkPagePanel">
                     <TextBlock
                         x:Name="TxtPage"
                         Height="20"
-                        Margin="16,12,0,4"
+                        Margin="16,0,0,4"
                         FontFamily="Segoe UI"
                         FontSize="12"
-                        Foreground="#616469"
+                        FontWeight="Bold"
+                        Foreground="{StaticResource color.sys.text.neutral.lv2}"
                         LineHeight="20"
                         Text="Page" />
                     <StackPanel Orientation="Horizontal">
@@ -195,15 +200,19 @@
                             </i:Interaction.Triggers>
                         </CustomControl:TextBoxWithTip>
                     </StackPanel>
-                    <Button
+                    <ToggleButton
                         Name="BtnLocation"
                         Width="228"
                         Height="32"
                         Margin="16,30,16,0"
+                        Background="Transparent"
+                        BorderBrush="Transparent"
+                        BorderThickness="0"
                         Command="{Binding LocationCommand}"
+                        IsChecked="{Binding BtnLocationIsChecked}"
                         IsEnabled="{Binding BtnLocationIsEnabled, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
-                        Style="{StaticResource btn.sec-icon}">
-                        <Button.Content>
+                        Style="{StaticResource LinkToolbarTgb}">
+                        <ToggleButton.Content>
                             <StackPanel Orientation="Horizontal">
                                 <Path
                                     Name="PathLocation"
@@ -213,8 +222,8 @@
                                     Fill=" #616469" />
                                 <TextBlock Margin="10,0" Text="定位目标区域" />
                             </StackPanel>
-                        </Button.Content>
-                    </Button>
+                        </ToggleButton.Content>
+                    </ToggleButton>
                     <Image
                         Name="ImagePreview"
                         Width="{Binding ImagePreviewWidth}"

+ 15 - 15
PDF Office/Views/TipContent/LinkAnnotTip.xaml

@@ -2,26 +2,24 @@
     x:Class="PDF_Office.Views.TipContent.LinkAnnotTip"
     xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
     xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+    xmlns:TipContent="clr-namespace:PDF_Office.ViewModels.TipContent"
     xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
     xmlns:local="clr-namespace:PDF_Office.Views.TipContent"
     xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
     xmlns:prism="http://prismlibrary.com/"
-    prism:ViewModelLocator.AutoWireViewModel="True"
-    xmlns:TipContent="clr-namespace:PDF_Office.ViewModels.TipContent"
     d:DataContext="{d:DesignInstance Type=TipContent:LinkAnnotTipViewModel}"
-    d:DesignHeight="450"
-    d:DesignWidth="800"
+    d:DesignHeight="50"
+    d:DesignWidth="760"
+    prism:ViewModelLocator.AutoWireViewModel="True"
     mc:Ignorable="d">
-    <Border
-        Name="LinkAnnotTip1"
-        Width="{Binding ElementName=PDFViewerContent, Path=Width}"
-        Margin="0,0,17,0"
-        HorizontalAlignment="Stretch"
-        VerticalAlignment="Top"
-        Background=" #BDDFFD"
-        Visibility="{Binding LinkAnnotTipVisibility}">
-        <WrapPanel Orientation="Horizontal">
+    <Border Margin="0,0,17,0" Background=" #BDDFFD">
+        <Grid>
+            <Grid.ColumnDefinitions>
+                <ColumnDefinition Width="35" />
+                <ColumnDefinition Width="*" />
+            </Grid.ColumnDefinitions>
             <Grid
+                Grid.Column="0"
                 Width="16"
                 Height="16"
                 Margin="9,4">
@@ -34,11 +32,13 @@
 
             <TextBlock
                 x:Name="DrawTipsText"
+                Grid.Column="1"
                 Margin="0,4,12,4"
                 Padding="4,2,4,2"
                 FontSize="14"
                 Foreground="#252629"
-                Text="Please use the scroll bar, thumbnail tool to locate the target page, click or box the area to select the target range" />
-        </WrapPanel>
+                Text="Please use the scroll bar, thumbnail tool to locate the target page, click or box the area to select the target range"
+                TextWrapping="Wrap" />
+        </Grid>
     </Border>
 </UserControl>

+ 2 - 1
PDF Office/Views/ViewContent.xaml

@@ -301,7 +301,7 @@
                 </ColumnDefinition>
             </Grid.ColumnDefinitions>
 
-            <ContentControl prism:RegionManager.RegionName="{Binding BOTARegionName}" SizeChanged="ContentControl_SizeChanged"/>
+            <ContentControl prism:RegionManager.RegionName="{Binding BOTARegionName}" SizeChanged="ContentControl_SizeChanged" />
             <GridSplitter
                 Name="BOTASplitter"
                 Grid.Column="1"
@@ -371,6 +371,7 @@
             <ContentControl
                 Grid.Column="2"
                 VerticalAlignment="Top"
+                Width="{Binding ElementName=PDFViewerContent, Path=Width}"
                 prism:RegionManager.RegionName="{Binding TipContentRegionName}"
                 Visibility="{Binding TipVisible}" />
             <!--  阅读页顶部侧面提示区域  -->