浏览代码

文案-大纲,缩略图

zhuyi 2 年之前
父节点
当前提交
a12738e227

+ 82 - 0
PDF Office/MultilingualResources/PDF Office.en.xlf

@@ -574,6 +574,88 @@ Drag files to reorder as you need.</target>
           <source>Underline</source>
           <target state="new">Underline</target>
         </trans-unit>
+        <trans-unit id="ViewRightMenu_ActualSize" translate="yes" xml:space="preserve">
+          <source>Actual Size</source>
+          <target state="new">Actual Size</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_BookMode" translate="yes" xml:space="preserve">
+          <source>Book Mode</source>
+          <target state="new">Book Mode</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_FitPage" translate="yes" xml:space="preserve">
+          <source>Fit Page</source>
+          <target state="new">Fit Page</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_FitWidth" translate="yes" xml:space="preserve">
+          <source>Fit Width</source>
+          <target state="new">Fit Width</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_PageDisplay" translate="yes" xml:space="preserve">
+          <source>Page Display</source>
+          <target state="new">Page Display</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_Print" translate="yes" xml:space="preserve">
+          <source>Print</source>
+          <target state="new">Print</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_Search" translate="yes" xml:space="preserve">
+          <source>Search</source>
+          <target state="new">Search</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_SinglePage" translate="yes" xml:space="preserve">
+          <source>Single Page</source>
+          <target state="new">Single Page</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_SinglePageContinuous" translate="yes" xml:space="preserve">
+          <source>Single Page Continuous</source>
+          <target state="new">Single Page Continuous</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_TwoPages" translate="yes" xml:space="preserve">
+          <source>Two Pages</source>
+          <target state="new">Two Pages</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_TwoPagesContinuous" translate="yes" xml:space="preserve">
+          <source>Two Pages Continuous</source>
+          <target state="new">Two Pages Continuous</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_Zoom" translate="yes" xml:space="preserve">
+          <source>Zoom</source>
+          <target state="new">Zoom</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_ZoomIn" translate="yes" xml:space="preserve">
+          <source>Zoom In</source>
+          <target state="new">Zoom In</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_ZoomOut" translate="yes" xml:space="preserve">
+          <source>Zoom Out</source>
+          <target state="new">Zoom Out</target>
+        </trans-unit>
+        <trans-unit id="Thumbnails_Title" translate="yes" xml:space="preserve">
+          <source>Thumbnails</source>
+          <target state="new">Thumbnails</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Title" translate="yes" xml:space="preserve">
+          <source>Bookmark</source>
+          <target state="new">Bookmark</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Delete" translate="yes" xml:space="preserve">
+          <source>Delete</source>
+          <target state="new">Delete</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Rename" translate="yes" xml:space="preserve">
+          <source>Rename</source>
+          <target state="new">Rename</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Change" translate="yes" xml:space="preserve">
+          <source>Change Target Location</source>
+          <target state="new">Change Target Location</target>
+          <note from="MultilingualBuild" annotates="source" priority="2">更改目标位置</note>
+        </trans-unit>
+        <trans-unit id="Bookmark_PageN" translate="yes" xml:space="preserve">
+          <source>Page {0}</source>
+          <target state="new">Page {0}</target>
+          <note from="MultilingualBuild" annotates="source" priority="2">第N页</note>
+        </trans-unit>
       </group>
     </body>
   </file>

+ 82 - 0
PDF Office/MultilingualResources/PDF Office.zh-Hans.xlf

@@ -574,6 +574,88 @@ Drag files to reorder as you need.</target>
           <source>Underline</source>
           <target state="new">Underline</target>
         </trans-unit>
+        <trans-unit id="ViewRightMenu_ActualSize" translate="yes" xml:space="preserve">
+          <source>Actual Size</source>
+          <target state="new">Actual Size</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_BookMode" translate="yes" xml:space="preserve">
+          <source>Book Mode</source>
+          <target state="new">Book Mode</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_FitPage" translate="yes" xml:space="preserve">
+          <source>Fit Page</source>
+          <target state="new">Fit Page</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_FitWidth" translate="yes" xml:space="preserve">
+          <source>Fit Width</source>
+          <target state="new">Fit Width</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_PageDisplay" translate="yes" xml:space="preserve">
+          <source>Page Display</source>
+          <target state="new">Page Display</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_Print" translate="yes" xml:space="preserve">
+          <source>Print</source>
+          <target state="new">Print</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_Search" translate="yes" xml:space="preserve">
+          <source>Search</source>
+          <target state="new">Search</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_SinglePage" translate="yes" xml:space="preserve">
+          <source>Single Page</source>
+          <target state="new">Single Page</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_SinglePageContinuous" translate="yes" xml:space="preserve">
+          <source>Single Page Continuous</source>
+          <target state="new">Single Page Continuous</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_TwoPages" translate="yes" xml:space="preserve">
+          <source>Two Pages</source>
+          <target state="new">Two Pages</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_TwoPagesContinuous" translate="yes" xml:space="preserve">
+          <source>Two Pages Continuous</source>
+          <target state="new">Two Pages Continuous</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_Zoom" translate="yes" xml:space="preserve">
+          <source>Zoom</source>
+          <target state="new">Zoom</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_ZoomIn" translate="yes" xml:space="preserve">
+          <source>Zoom In</source>
+          <target state="new">Zoom In</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_ZoomOut" translate="yes" xml:space="preserve">
+          <source>Zoom Out</source>
+          <target state="new">Zoom Out</target>
+        </trans-unit>
+        <trans-unit id="Thumbnails_Title" translate="yes" xml:space="preserve">
+          <source>Thumbnails</source>
+          <target state="new">Thumbnails</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Title" translate="yes" xml:space="preserve">
+          <source>Bookmark</source>
+          <target state="new">Bookmark</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Delete" translate="yes" xml:space="preserve">
+          <source>Delete</source>
+          <target state="new">Delete</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Rename" translate="yes" xml:space="preserve">
+          <source>Rename</source>
+          <target state="new">Rename</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Change" translate="yes" xml:space="preserve">
+          <source>Change Target Location</source>
+          <target state="new">Change Target Location</target>
+          <note from="MultilingualBuild" annotates="source" priority="2">更改目标位置</note>
+        </trans-unit>
+        <trans-unit id="Bookmark_PageN" translate="yes" xml:space="preserve">
+          <source>Page {0}</source>
+          <target state="new">Page {0}</target>
+          <note from="MultilingualBuild" annotates="source" priority="2">第N页</note>
+        </trans-unit>
       </group>
     </body>
   </file>

+ 82 - 0
PDF Office/MultilingualResources/PDF Office.zh-Hant.xlf

@@ -574,6 +574,88 @@ Drag files to reorder as you need.</target>
           <source>Underline</source>
           <target state="new">Underline</target>
         </trans-unit>
+        <trans-unit id="ViewRightMenu_ActualSize" translate="yes" xml:space="preserve">
+          <source>Actual Size</source>
+          <target state="new">Actual Size</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_BookMode" translate="yes" xml:space="preserve">
+          <source>Book Mode</source>
+          <target state="new">Book Mode</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_FitPage" translate="yes" xml:space="preserve">
+          <source>Fit Page</source>
+          <target state="new">Fit Page</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_FitWidth" translate="yes" xml:space="preserve">
+          <source>Fit Width</source>
+          <target state="new">Fit Width</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_PageDisplay" translate="yes" xml:space="preserve">
+          <source>Page Display</source>
+          <target state="new">Page Display</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_Print" translate="yes" xml:space="preserve">
+          <source>Print</source>
+          <target state="new">Print</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_Search" translate="yes" xml:space="preserve">
+          <source>Search</source>
+          <target state="new">Search</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_SinglePage" translate="yes" xml:space="preserve">
+          <source>Single Page</source>
+          <target state="new">Single Page</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_SinglePageContinuous" translate="yes" xml:space="preserve">
+          <source>Single Page Continuous</source>
+          <target state="new">Single Page Continuous</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_TwoPages" translate="yes" xml:space="preserve">
+          <source>Two Pages</source>
+          <target state="new">Two Pages</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_TwoPagesContinuous" translate="yes" xml:space="preserve">
+          <source>Two Pages Continuous</source>
+          <target state="new">Two Pages Continuous</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_Zoom" translate="yes" xml:space="preserve">
+          <source>Zoom</source>
+          <target state="new">Zoom</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_ZoomIn" translate="yes" xml:space="preserve">
+          <source>Zoom In</source>
+          <target state="new">Zoom In</target>
+        </trans-unit>
+        <trans-unit id="ViewRightMenu_ZoomOut" translate="yes" xml:space="preserve">
+          <source>Zoom Out</source>
+          <target state="new">Zoom Out</target>
+        </trans-unit>
+        <trans-unit id="Thumbnails_Title" translate="yes" xml:space="preserve">
+          <source>Thumbnails</source>
+          <target state="new">Thumbnails</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Title" translate="yes" xml:space="preserve">
+          <source>Bookmark</source>
+          <target state="new">Bookmark</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Delete" translate="yes" xml:space="preserve">
+          <source>Delete</source>
+          <target state="new">Delete</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Rename" translate="yes" xml:space="preserve">
+          <source>Rename</source>
+          <target state="new">Rename</target>
+        </trans-unit>
+        <trans-unit id="Bookmark_Change" translate="yes" xml:space="preserve">
+          <source>Change Target Location</source>
+          <target state="new">Change Target Location</target>
+          <note from="MultilingualBuild" annotates="source" priority="2">更改目标位置</note>
+        </trans-unit>
+        <trans-unit id="Bookmark_PageN" translate="yes" xml:space="preserve">
+          <source>Page {0}</source>
+          <target state="new">Page {0}</target>
+          <note from="MultilingualBuild" annotates="source" priority="2">第N页</note>
+        </trans-unit>
       </group>
     </body>
   </file>

+ 54 - 0
PDF Office/Strings/MainPage/MainPage.Designer.cs

@@ -60,6 +60,51 @@ namespace PDF_Office.Strings.MainPage {
             }
         }
         
+        /// <summary>
+        ///   查找类似 Change Target Location 的本地化字符串。
+        /// </summary>
+        public static string Bookmark_Change {
+            get {
+                return ResourceManager.GetString("Bookmark_Change", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   查找类似 Delete 的本地化字符串。
+        /// </summary>
+        public static string Bookmark_Delete {
+            get {
+                return ResourceManager.GetString("Bookmark_Delete", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   查找类似 Page {0} 的本地化字符串。
+        /// </summary>
+        public static string Bookmark_PageN {
+            get {
+                return ResourceManager.GetString("Bookmark_PageN", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   查找类似 Rename 的本地化字符串。
+        /// </summary>
+        public static string Bookmark_Rename {
+            get {
+                return ResourceManager.GetString("Bookmark_Rename", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   查找类似 Bookmark 的本地化字符串。
+        /// </summary>
+        public static string Bookmark_Title {
+            get {
+                return ResourceManager.GetString("Bookmark_Title", resourceCulture);
+            }
+        }
+        
         /// <summary>
         ///   查找类似 Enter Read Mode, tap ESC to exit 的本地化字符串。
         /// </summary>
@@ -485,6 +530,15 @@ namespace PDF_Office.Strings.MainPage {
             }
         }
         
+        /// <summary>
+        ///   查找类似 Thumbnails 的本地化字符串。
+        /// </summary>
+        public static string Thumbnails_Title {
+            get {
+                return ResourceManager.GetString("Thumbnails_Title", resourceCulture);
+            }
+        }
+        
         /// <summary>
         ///   查找类似 Book Mode 的本地化字符串。
         /// </summary>

+ 20 - 0
PDF Office/Strings/MainPage/MainPage.resx

@@ -117,6 +117,23 @@
   <resheader name="writer">
     <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
   </resheader>
+  <data name="Bookmark_Change" xml:space="preserve">
+    <value>Change Target Location</value>
+    <comment>更改目标位置</comment>
+  </data>
+  <data name="Bookmark_Delete" xml:space="preserve">
+    <value>Delete</value>
+  </data>
+  <data name="Bookmark_PageN" xml:space="preserve">
+    <value>Page {0}</value>
+    <comment>第N页</comment>
+  </data>
+  <data name="Bookmark_Rename" xml:space="preserve">
+    <value>Rename</value>
+  </data>
+  <data name="Bookmark_Title" xml:space="preserve">
+    <value>Bookmark</value>
+  </data>
   <data name="GlobalTip_ESCReadMode" xml:space="preserve">
     <value>Enter Read Mode, tap ESC to exit</value>
     <comment>进入阅读模式,提示可以按ESC退出</comment>
@@ -270,6 +287,9 @@ Drag files to reorder as you need.</value>
   <data name="Stamp_Title" xml:space="preserve">
     <value>Stamp</value>
   </data>
+  <data name="Thumbnails_Title" xml:space="preserve">
+    <value>Thumbnails</value>
+  </data>
   <data name="ViewProperties_Book" xml:space="preserve">
     <value>Book Mode</value>
     <comment>书本模式</comment>

+ 58 - 0
PDF Office/ViewModels/BOTA/OutLineControlViewModel.cs

@@ -22,6 +22,63 @@ namespace PDF_Office.ViewModels.BOTA
 {
     class OutLineControlViewModel : BindableBase, INavigationAware
     {
+        #region 文案
+
+        private string T_title;
+
+        public string T_Title
+        {
+            get { return T_title; }
+            set
+            {
+                SetProperty(ref T_title, value);
+            }
+        }
+
+        private string T_expand;
+
+        public string T_Expand
+        {
+            get { return T_expand; }
+            set
+            {
+                SetProperty(ref T_expand, value);
+            }
+        }
+
+        private string T_collapse;
+
+        public string T_Collapse
+        {
+            get { return T_collapse; }
+            set
+            {
+                SetProperty(ref T_collapse, value);
+            }
+        }
+
+        private string T_removeAll;
+
+        public string T_RemoveAll
+        {
+            get { return T_removeAll; }
+            set
+            {
+                SetProperty(ref T_removeAll, value);
+            }
+        }
+
+
+        private void InitString()
+        {
+            T_Title = App.MainPageLoader.GetString("Outline_Title");
+            T_Expand = App.MainPageLoader.GetString("Outline_Expand");
+            T_Collapse = App.MainPageLoader.GetString("Outline_Collapse");
+            T_RemoveAll = App.MainPageLoader.GetString("Outline_RemoveAll");
+        }
+
+        #endregion
+
         private string PageDefaultName = "";
         //缩略图相关全局变量,减少内存申请次数
         private WriteableBitmap WirteBitmap;
@@ -63,6 +120,7 @@ namespace PDF_Office.ViewModels.BOTA
             DeleteAllCommand = new DelegateCommand(DeleteAll);
             CollapseAllCommand = new DelegateCommand<ObservableCollection<OutlineNode>>(CollapseAll);
             ExpandAllCommand = new DelegateCommand<ObservableCollection<OutlineNode>>(ExpandAll);
+            InitString();
         }
 
         public bool IsNavigationTarget(NavigationContext navigationContext)

+ 22 - 0
PDF Office/ViewModels/PageEdit/PageEditContentViewModel.cs

@@ -32,6 +32,27 @@ namespace PDF_Office.ViewModels.PageEdit
 {
     public class PageEditContentViewModel : BindableBase, INavigationAware
     {
+        #region 文案
+
+        private string T_title;
+
+        public string T_Title
+        {
+            get { return T_title; }
+            set
+            {
+                SetProperty(ref T_title, value);
+            }
+        }
+
+
+        private void InitString()
+        {
+            T_Title = App.MainPageLoader.GetString("Thumbnails_Title");
+        }
+
+        #endregion
+
 
         private CPDFViewer PDFViewer;
 
@@ -451,6 +472,7 @@ namespace PDF_Office.ViewModels.PageEdit
             CacheFilePath.Instance.PropertyChanged += Instance_PropertyChanged;
 
             RefreshPageRangeItem();
+            InitString();
         }
 
         #region 事件

+ 4 - 1
PDF Office/Views/BOTA/OutLineControl.xaml

@@ -10,7 +10,6 @@
     xmlns:model="clr-namespace:PDF_Office.Model.BOTA"
     xmlns:mainPageLoader="clr-namespace:PDF_Office.Strings.MainPage"
     d:DataContext="{d:DesignInstance Type=bota:OutLineControlViewModel}"
-    Loaded="UserControl_Loaded"
     mc:Ignorable="d">
     <UserControl.Resources>
         <ResourceDictionary>
@@ -28,6 +27,7 @@
             <Grid x:Name="Header">
                 <TextBlock
                     x:Name="TxtTitle"
+                    Text="{Binding T_Title}"
                     Margin="16,0,0,0"
                     HorizontalAlignment="Left"
                     VerticalAlignment="Center"
@@ -81,14 +81,17 @@
                                 </ContextMenu.ItemContainerStyle>
                                 <MenuItem
                                     Name="MenuExpandAll"
+                                    Header="{Binding T_Expand}"
                                     Command="{Binding ExpandAllCommand}"
                                     CommandParameter="{Binding Outlinelist}" />
                                 <MenuItem
                                     Name="MenuCollapseAll"
+                                    Header="{Binding T_Collapse}"
                                     Command="{Binding CollapseAllCommand}"
                                     CommandParameter="{Binding Outlinelist}"/>
                                 <MenuItem
                                     Name="MenuDeleteAll"
+                                    Header="{Binding T_RemoveAll}"
                                     Command="{Binding DeleteAllCommand}" />
                             </ContextMenu>
                         </customcontrol:PathButton.ContextMenu>

+ 0 - 12
PDF Office/Views/BOTA/OutLineControl.xaml.cs

@@ -56,10 +56,6 @@ namespace PDF_Office.Views.BOTA
             InitializeComponent();
         }
 
-        private void LoadedLangText()
-        {
-        }
-
         private void BtnMore_Click(object sender, RoutedEventArgs e)
         {
             MenuMore.Placement = System.Windows.Controls.Primitives.PlacementMode.Bottom;
@@ -482,13 +478,5 @@ namespace PDF_Office.Views.BOTA
                 OutlineView.Focus();
             }
         }
-
-        private void UserControl_Loaded(object sender, RoutedEventArgs e)
-        {
-            TxtTitle.Text = App.MainPageLoader.GetString("Outline_Title");
-            MenuExpandAll.Header = App.MainPageLoader.GetString("Outline_Expand");
-            MenuCollapseAll.Header = App.MainPageLoader.GetString("Outline_Collapse");
-            MenuDeleteAll.Header = App.MainPageLoader.GetString("Outline_RemoveAll");
-        }
     }
 }

+ 1 - 1
PDF Office/Views/PageEdit/PageEditContent.xaml

@@ -302,7 +302,7 @@
                         FontSize="14"
                         FontWeight="SemiBold"
                         LineHeight="20"
-                        Text="Thumbnails" />
+                        Text="{Binding T_Title}" />
                     <ToggleButton
                         Name="TbnTwoLine"
                         Width="32"