Browse Source

蘭雅CorelDRAW插件 2024.5.1国际劳动节版

蘭雅sRGB 9 months ago
parent
commit
15a5e2c956
5 changed files with 277 additions and 193 deletions
  1. 35 12
      UI/ArrangeForm.frm
  2. 43 28
      UI/CQL_FIND_UI.frm
  3. 59 44
      UI/MakeSizePlus.frm
  4. 36 19
      UI/Replace_UI.frm
  5. 104 90
      UI/Toolbar.frm

+ 35 - 12
UI/ArrangeForm.frm

@@ -1,4 +1,22 @@
-'// 鐢ㄦ埛绐楀彛鍒濆�鍖�
+VERSION 5.00
+Begin {C62A69F0-16DC-11CE-9E98-00AA00574A4F} ArrangeForm 
+   Caption         =   "蘭雅sRGB 自动拼版 │ 嘉盟赞助"
+   ClientHeight    =   2475
+   ClientLeft      =   45
+   ClientTop       =   330
+   ClientWidth     =   4650
+   OleObjectBlob   =   "ArrangeForm.frx":0000
+   ShowModal       =   0   'False
+   StartUpPosition =   2  'CenterScreen
+   WhatsThisButton =   -1  'True
+   WhatsThisHelp   =   -1  'True
+End
+Attribute VB_Name = "ArrangeForm"
+Attribute VB_GlobalNameSpace = False
+Attribute VB_Creatable = False
+Attribute VB_PredeclaredId = True
+Attribute VB_Exposed = False
+'// 用户窗口初始化
 Private Sub UserForm_Initialize()
   ActiveDocument.Unit = cdrMillimeter
   Dim sr As ShapeRange
@@ -15,7 +33,7 @@ Private Sub UserForm_Initialize()
   If sr.Count > 0 Then
     ls = Int(sr.SizeWidth + 0.5)
     hs = Int(sr.SizeHeight + 0.5)
-    Label_Size.Caption = "灏哄�: " & ls & "脳" & hs & "mm"
+    Label_Size.Caption = "尺寸: " & ls & "×" & hs & "mm"
     
     lj = Int(pw / ls)
     hj = Int(ph / hs)
@@ -62,9 +80,9 @@ Private Sub CommandButton1_Click()
     GoTo ErrorHandler
   End If
   
-  '// 浠g爜杩愯�鏃跺叧闂�獥鍙e埛鏂�
+  '// 代码运行时关闭窗口刷新
   ActiveDocument.BeginCommandGroup:  Application.Optimization = True
-  '// 鎷肩増鐭╅樀
+  '// 拼版矩阵
   arrange_Clone matrix, sr
   Unload Me
   
@@ -72,26 +90,31 @@ ErrorHandler:
   API.EndOpt
 End Sub
 
-'// 鎷肩増鐭╅樀  matrix = Array(ls, hs, lj, hj)
+'// 拼版矩阵  matrix = Array(ls, hs, lj, hj)
 Private Function arrange_Clone(matrix As Variant, sr As ShapeRange)
   ls = matrix(0): hs = matrix(1)
   lj = matrix(2): hj = matrix(3)
-  x = sr.SizeWidth: Y = sr.SizeHeight
+  X = sr.SizeWidth: Y = sr.SizeHeight
   Set s1 = sr '// Set s1 = sr.Clone
-  '// StepAndRepeat 鏂规硶鍦ㄨ寖鍥村唴鍒涘缓澶氫釜褰㈢姸鍓�湰
-  Set dup1 = s1.StepAndRepeat(ls - 1, x + lj, 0#)
-  Set dup2 = ActiveDocument.CreateShapeRangeFromArray(dup1, s1).StepAndRepeat(hs - 1, 0#, -(Y + hj))
+  '// StepAndRepeat 方法在范围内创建多个形状副本
+  
+'//  Set dup1 = s1.StepAndRepeat(ls - 1, x + lj, 0#)
+'//  Set dup2 = ActiveDocument.CreateShapeRangeFromArray(dup1, s1).StepAndRepeat(hs - 1, 0#, -(Y + hj))
+
+Set dup1 = s1.StepAndRepeat(hs - 1, 0#, -(Y + hj))
+Set dup2 = ActiveDocument.CreateShapeRangeFromArray(dup1, s1).StepAndRepeat(ls - 1, X + lj, 0#)
+
   '// s1.Delete
 End Function
 
 Private Function arrange_Clone_one(matrix As Variant, sr As ShapeRange)
   ls = matrix(0): hs = matrix(1)
   lj = matrix(2): hj = matrix(3)
-  x = sr.SizeWidth: Y = sr.SizeHeight
+  X = sr.SizeWidth: Y = sr.SizeHeight
   Set s1 = sr '// Set s1 = sr.Clone
-  '// StepAndRepeat 鏂规硶鍦ㄨ寖鍥村唴鍒涘缓澶氫釜褰㈢姸鍓�湰
+  '// StepAndRepeat 方法在范围内创建多个形状副本
   If ls > 1 Then
-    Set dup1 = s1.StepAndRepeat(ls - 1, x + lj, 0#)
+    Set dup1 = s1.StepAndRepeat(ls - 1, X + lj, 0#)
   Else
     Set dup1 = s1
   End If

+ 43 - 28
UI/CQL_FIND_UI.frm

@@ -1,17 +1,32 @@
+VERSION 5.00
+Begin {C62A69F0-16DC-11CE-9E98-00AA00574A4F} CQL_FIND_UI 
+   ClientHeight    =   7830
+   ClientLeft      =   45
+   ClientTop       =   330
+   ClientWidth     =   11610
+   OleObjectBlob   =   "CQL_FIND_UI.frx":0000
+   StartUpPosition =   1  'CenterOwner
+End
+Attribute VB_Name = "CQL_FIND_UI"
+Attribute VB_GlobalNameSpace = False
+Attribute VB_Creatable = False
+Attribute VB_PredeclaredId = True
+Attribute VB_Exposed = False
+
 '// This is free and unencumbered software released into the public domain.
 '// For more information, please refer to  https://github.com/hongwenjun
 
 #If VBA7 Then
-    Private Declare PtrSafe Function DrawMenuBar Lib "user32" (ByVal hWnd As Long) As Long
-    Private Declare PtrSafe Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
-    Private Declare PtrSafe Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
+    Private Declare PtrSafe Function DrawMenuBar Lib "user32" (ByVal hwnd As Long) As Long
+    Private Declare PtrSafe Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
+    Private Declare PtrSafe Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
     Private Declare PtrSafe Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
     Private Declare PtrSafe Function GetSystemMetrics Lib "user32" (ByVal nIndex As Long) As Long
     
 #Else
-    Private Declare Function DrawMenuBar Lib "user32" (ByVal hWnd As Long) As Long
-    Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
-    Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
+    Private Declare Function DrawMenuBar Lib "user32" (ByVal hwnd As Long) As Long
+    Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
+    Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
     Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
     Private Declare Function GetSystemMetrics Lib "user32" (ByVal nIndex As Long) As Long
 #End If
@@ -23,22 +38,22 @@ Private Const WS_EX_DLGMODALFRAME = &H1&
 
 Private Sub UserForm_Initialize()
   Dim IStyle As Long
-  Dim hWnd As Long
+  Dim hwnd As Long
   
-  hWnd = FindWindow("ThunderDFrame", Me.Caption)
+  hwnd = FindWindow("ThunderDFrame", Me.Caption)
 
-  IStyle = GetWindowLong(hWnd, GWL_STYLE)
+  IStyle = GetWindowLong(hwnd, GWL_STYLE)
   IStyle = IStyle And Not WS_CAPTION
-  SetWindowLong hWnd, GWL_STYLE, IStyle
-  DrawMenuBar hWnd
-  IStyle = GetWindowLong(hWnd, GWL_EXSTYLE) And Not WS_EX_DLGMODALFRAME
-  SetWindowLong hWnd, GWL_EXSTYLE, IStyle
+  SetWindowLong hwnd, GWL_STYLE, IStyle
+  DrawMenuBar hwnd
+  IStyle = GetWindowLong(hwnd, GWL_EXSTYLE) And Not WS_EX_DLGMODALFRAME
+  SetWindowLong hwnd, GWL_EXSTYLE, IStyle
 
   With Me
   '  .StartUpPosition = 0
   '  .Left = 500
   '  .Top = 200
-    .Width = 378
+    .width = 378
     .Height = 228
   End With
   
@@ -55,7 +70,7 @@ End Sub
 
 Private Sub LOGO_MouseMove(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button Then
-  Debug.Print X, Y
+'//  Debug.Print X, Y
     Me.Left = Me.Left - mx + X
     Me.Top = Me.Top - my + Y
   End If
@@ -74,10 +89,10 @@ Private Sub Image1_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, By
   ElseIf Abs(X - pos_x(0)) < 30 And Abs(Y - pos_y(2)) < 30 Then
     Call CQLSameSize
   ElseIf Abs(X - pos_x(1)) < 30 And Abs(Y - pos_y(3)) < 30 Then
-    API.WebHelp "https://262235.xyz/index.php/tag/vba/"
+'//   WebHelp "https://262235.xyz/index.php/tag/vba/"
   End If
   
-    '// 棰勭疆棰滆壊杞�粨閫夋嫨    鍜� '// 褰╄泲鍔熻兘
+    '// 预置颜色轮廓选择    和 '// 彩蛋功能
   If Abs(X - 178) < 30 And Abs(Y - 118) < 30 = True Then
     Image1.Visible = False
     Close_Icon.Visible = False
@@ -88,7 +103,7 @@ Private Sub Image1_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, By
       .Left = Val(GetSetting("LYVBA", "Settings", "Left", "400")) + 318
       .Top = Val(GetSetting("LYVBA", "Settings", "Top", "55")) - 2
       .Height = 30
-      .Width = .Width - 20
+      .width = .width - 20
     End With
     
     If OptBt.value Then
@@ -163,7 +178,7 @@ Private Sub CQLSameSize()
     Dim box As Boolean
     box = ActiveDocument.GetUserArea(x1, y1, x2, y2, Shift, 10, False, cdrCursorWeldSingle)
     If Not b Then
-      ' MsgBox "閫夊尯鑼冨洿: " & x1 & y1 & x2 & y2
+      ' MsgBox "选区范围: " & x1 & y1 & x2 & y2
       Set sh = ActivePage.SelectShapesFromRectangle(x1, y1, x2, y2, False)
       sh.Shapes.FindShapes(Query:="@width = {" & s.SizeWidth & " mm} and @height ={" & s.SizeHeight & "mm}").CreateSelection
     End If
@@ -179,7 +194,7 @@ Private Sub CQLSameOutlineColor()
   If s Is Nothing Then Exit Sub
   colr.CopyAssign s.Outline.Color
   colr.ConvertToRGB
-  ' 鏌ユ壘瀵硅薄
+  ' 查找对象
   r = colr.RGBRed
   G = colr.RGBGreen
   b = colr.RGBBlue
@@ -194,7 +209,7 @@ Private Sub CQLSameOutlineColor()
     Dim box As Boolean
     box = ActiveDocument.GetUserArea(x1, y1, x2, y2, Shift, 10, False, cdrCursorWeldSingle)
     If Not b Then
-      ' MsgBox "閫夊尯鑼冨洿: " & x1 & y1 & x2 & y2
+      ' MsgBox "选区范围: " & x1 & y1 & x2 & y2
       Set sh = ActivePage.SelectShapesFromRectangle(x1, y1, x2, y2, False)
       sh.Shapes.FindShapes(Query:="@Outline.Color.rgb[.r='" & r & "' And .g='" & G & "' And .b='" & b & "']").CreateSelection
     End If
@@ -204,7 +219,7 @@ Private Sub CQLSameOutlineColor()
   
   Exit Sub
 err:
-    MsgBox "瀵硅薄杞�粨涓虹┖銆�"
+    MsgBox "对象轮廓为空。"
 End Sub
 
 Private Sub CQLSameUniformColor()
@@ -212,10 +227,10 @@ Private Sub CQLSameUniformColor()
   Dim colr As New Color, s As Shape
   Set s = ActiveShape
   If s Is Nothing Then Exit Sub
-  If s.Fill.Type = cdrFountainFill Then MsgBox "涓嶆敮鎸佹笎鍙樿壊銆�": Exit Sub
+  If s.Fill.Type = cdrFountainFill Then MsgBox "不支持渐变色。": Exit Sub
   colr.CopyAssign s.Fill.UniformColor
   colr.ConvertToRGB
-  ' 鏌ユ壘瀵硅薄
+  ' 查找对象
   r = colr.RGBRed
   G = colr.RGBGreen
   b = colr.RGBBlue
@@ -230,7 +245,7 @@ Private Sub CQLSameUniformColor()
     Dim box As Boolean
     box = ActiveDocument.GetUserArea(x1, y1, x2, y2, Shift, 10, False, cdrCursorWeldSingle)
     If Not b Then
-      ' MsgBox "閫夊尯鑼冨洿: " & x1 & y1 & x2 & y2
+      '// MsgBox "选区范围: " & x1 & y1 & x2 & y2
       Set sh = ActivePage.SelectShapesFromRectangle(x1, y1, x2, y2, False)
       sh.Shapes.FindShapes(Query:="@fill.color.rgb[.r='" & r & "' And .g='" & G & "' And .b='" & b & "']").CreateSelection
     End If
@@ -239,13 +254,13 @@ Private Sub CQLSameUniformColor()
   End If
   Exit Sub
 err:
-  MsgBox "瀵硅薄濉�厖涓虹┖銆�"
+  MsgBox "对象填充为空。"
 End Sub
 
 Private Sub X_EXIT_Click()
-  Unload Me    ' 鍏抽棴
+  Unload Me    '// 关闭
 End Sub
 
 Private Sub Close_Icon_Click()
-  Unload Me    ' 鍏抽棴
+  Unload Me    '// 关闭
 End Sub

+ 59 - 44
UI/MakeSizePlus.frm

@@ -1,3 +1,18 @@
+VERSION 5.00
+Begin {C62A69F0-16DC-11CE-9E98-00AA00574A4F} MakeSizePlus 
+   Caption         =   "Batch Dimension Plus"
+   ClientHeight    =   3690
+   ClientLeft      =   45
+   ClientTop       =   330
+   ClientWidth     =   5115
+   OleObjectBlob   =   "MakeSizePlus.frx":0000
+   StartUpPosition =   1  'CenterOwner
+End
+Attribute VB_Name = "MakeSizePlus"
+Attribute VB_GlobalNameSpace = False
+Attribute VB_Creatable = False
+Attribute VB_PredeclaredId = True
+Attribute VB_Exposed = False
 '// This is free and unencumbered software released into the public domain.
 '// For more information, please refer to  https://github.com/hongwenjun
 
@@ -20,7 +35,7 @@ Private Const GWL_EXSTYLE = (-20)
 Private Const WS_CAPTION As Long = &HC00000
 Private Const WS_EX_DLGMODALFRAME = &H1&
 
-'// 鎻掍欢鍚嶇О VBA_UserForm
+'// 插件名称 VBA_UserForm
 Private Const TOOLNAME As String = "LYVBA"
 Private Const SECTION As String = "MakeSizePlus"
 Private sreg As New ShapeRange
@@ -42,19 +57,19 @@ Private Sub UserForm_Initialize()
   Init_Translations Me, LNG_CODE
   Me.Caption = i18n("Batch Dimension Plus", LNG_CODE)
   
-   ' 璇诲彇绾胯�缃�
+   ' 读取线设置
   Bleed.text = API.GetSet("Bleed")
   Line_len.text = API.GetSet("Line_len")
   Outline_Width.text = GetSetting("LYVBA", "Settings", "Outline_Width", "0.2")
   
 End Sub
 
-'// 鍏抽棴绐楀彛鏃朵繚瀛樼獥鍙d綅缃�
+'// 关闭窗口时保存窗口位置
 Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
     saveFormPos True
 End Sub
 
-'// 淇濆瓨绐楀彛浣嶇疆鍜屽姞杞界獥鍙d綅缃�
+'// 保存窗口位置和加载窗口位置
 Sub saveFormPos(bDoSave As Boolean)
   If bDoSave Then 'save position
     SaveSetting TOOLNAME, SECTION, "form_left", Me.Left
@@ -77,7 +92,7 @@ Private Sub btn_ExpandForm_Click()
 End Sub
 
 
-'// Minimizes the window and retains dimensioning functionality   '// 鏈€灏忓寲绐楀彛骞朵繚鐣欐爣娉ㄥ昂瀵稿姛鑳�
+'// Minimizes the window and retains dimensioning functionality   '// 最小化窗口并保留标注尺寸功能
 Private Function MiniForm()
 
   Dim IStyle As Long
@@ -92,7 +107,7 @@ Private Function MiniForm()
   IStyle = GetWindowLong(hwnd, GWL_EXSTYLE) And Not WS_EX_DLGMODALFRAME
   SetWindowLong hwnd, GWL_EXSTYLE, IStyle
 
-  Dim ctl As Variant  '// CorelDRAW 2020 瀹氫箟鎴� Variant 鎵嶄笉浼氶敊璇�
+  Dim ctl As Variant  '// CorelDRAW 2020 定义成 Variant 才不会错误
   For Each ctl In MakeSizePlus.Controls
       ctl.Visible = False
       ctl.Top = 2
@@ -129,7 +144,7 @@ Private Sub Settings_Click()
    SaveSetting "LYVBA", "Settings", "Bleed", Bleed.text
    SaveSetting "LYVBA", "Settings", "Line_len", Line_len.text
    SaveSetting "LYVBA", "Settings", "Outline_Width", Outline_Width.text
-   Call API.Set_Space_Width  '// 璁剧疆绌洪棿闂撮殭
+   Call API.Set_Space_Width  '// 设置空间间隙
   End If
 End Sub
 
@@ -188,7 +203,7 @@ Sub make_sizes_sep(dr, Optional shft = 0, Optional ByVal mirror As Boolean = Fal
   
   Dim border As Variant
   Dim Line_len As Double
-  Line_len = API.Set_Space_Width(True)  '// 璇诲彇闂撮殧
+  Line_len = API.Set_Space_Width(True)  '// 读取间隔
 
   border = Array(cdrBottomRight, cdrBottomLeft, os.TopY + Line_len, os.TopY + 2 * Line_len, _
   cdrBottomRight, cdrTopRight, os.LeftX - Line_len, os.LeftX - 2 * Line_len)
@@ -259,7 +274,7 @@ Sub make_sizes_sep(dr, Optional shft = 0, Optional ByVal mirror As Boolean = Fal
             Set pte = os.Shapes(i + 1).SnapPoints.BBox(cdrTopRight)
             Set sh = ActiveLayer.CreateLinearDimension(cdrDimensionVertical, pts, pte, True, os.RightX + os.SizeWidth / 10, os.BottomY + os.SizeHeight / 10, cdrDimensionStyleEngineering)
         End Select
-        '// 灏哄�鏍囨敞璁剧疆灞炴€�
+        '// 尺寸标注设置属性
         Dimension_SetProperty sh, PresetProperty.value
         'ActiveDocument.ClearSelection
       Next i
@@ -357,12 +372,12 @@ ErrorHandler:
   API.EndOpt
 End Sub
 
-'// 浣跨敤鏍囪�绾挎壒閲忓缓绔嬪昂瀵告爣娉�:   宸﹂敭涓婃爣娉�紝鍙抽敭鍙虫爣娉�
+'// 使用标记线批量建立尺寸标注:   左键上标注,右键右标注
 Private Sub MarkLines_Makesize_MouseUp(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   Dim sr As ShapeRange
   Set sr = ActiveSelectionRange
   
-  '// 鍙抽敭
+  '// 右键
   If Button = 2 Then
     If chkOpposite.value = True Then
         CutLines.Dimension_MarkLines cdrAlignTop, True
@@ -372,7 +387,7 @@ Private Sub MarkLines_Makesize_MouseUp(ByVal Button As Integer, ByVal Shift As I
       make_sizes_sep "lfbx", Shift, True
     End If
   
-  '// 宸﹂敭
+  '// 左键
   ElseIf Button = 1 Then
     If chkOpposite.value = True Then
       CutLines.Dimension_MarkLines cdrAlignLeft, False
@@ -386,18 +401,18 @@ Private Sub MarkLines_Makesize_MouseUp(ByVal Button As Integer, ByVal Shift As I
   sr.CreateSelection
 End Sub
 
-'// 浣跨敤鎵嬪伐閫夎妭鐐瑰缓绔嬪昂瀵告爣娉�紝浣跨敤Ctrl鍒嗙�灏哄�鏍囨敞
+'// 使用手工选节点建立尺寸标注,使用Ctrl分离尺寸标注
 Private Sub Manual_Makesize_MouseUp(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
-      '// 鍙抽敭
+      '// 右键
   ElseIf Shift = fmCtrlMask Then
-      Slanted_Makesize  '// 鎵嬪姩鏍囨敞鍊炬枩灏哄�
+      Slanted_Makesize  '// 手动标注倾斜尺寸
   Else
-      ModulePlus.Untie_MarkLines   '// 瑙g粦灏哄�锛屽垎绂诲昂瀵�
+      ModulePlus.Untie_MarkLines   '// 解绑尺寸,分离尺寸
   End If
 End Sub
 
-'// 鎵嬪姩鏍囨敞鍊炬枩灏哄�
+'// 手动标注倾斜尺寸
 Private Function Slanted_Makesize()
   On Error GoTo ErrorHandler
   API.BeginOpt
@@ -410,7 +425,7 @@ Private Function Slanted_Makesize()
   Set nr = ActiveShape.Curve.Selection
   
   If chkOpposite.value = False Then
-    Slanted_Sort_Make sr  '// 鎺掑簭鏍囨敞鍊炬枩灏哄�
+    Slanted_Sort_Make sr  '// 排序标注倾斜尺寸
     Exit Function
   End If
   If nr.Count < 2 Then Exit Function
@@ -434,7 +449,7 @@ ErrorHandler:
   API.EndOpt
 End Function
 
-'// 鎺掑簭鏍囨敞鍊炬枩灏哄�
+'// 排序标注倾斜尺寸
 Private Function Slanted_Sort_Make(shs As ShapeRange)
   On Error GoTo ErrorHandler
   Dim sr As New ShapeRange
@@ -448,7 +463,7 @@ Private Function Slanted_Sort_Make(shs As ShapeRange)
     Next n
   Next sh
   
-  CutLines.RemoveDuplicates sr  '// 绠€鍗曞垹闄ら噸澶嶇畻娉�
+  CutLines.RemoveDuplicates sr  '// 简单删除重复算法
   Set sr = X4_Sort_ShapeRange(sr, stlx)
 
   For i = 1 To sr.Count - 1
@@ -473,15 +488,15 @@ ErrorHandler:
   API.EndOpt
 End Function
 
-'// 灏哄�鏍囨敞璁剧疆灞炴€�
+'// 尺寸标注设置属性
 Private Function Dimension_SetProperty(sh_dim As Shape, Optional ByVal Preset As Boolean = False)
 #If VBA7 Then
   If Preset And sh_dim.Type = cdrLinearDimensionShape Then
     With sh_dim.Style.GetProperty("dimension")
-      .SetProperty "precision", 0 '       灏忔暟浣嶆暟
-      .SetProperty "showUnits", 0 '       鏄�惁鏄剧ず鍗曚綅 0/1
-      .SetProperty "textPlacement", 0 '   0銆佷笂鏂癸紝1銆佷笅鏂癸紝2銆佷腑闂�
-    '  .SetProperty "dynamicText", 0 '    鏄�惁鍙�互缂栬緫灏哄�0/1
+      .SetProperty "precision", 0 '       小数位数
+      .SetProperty "showUnits", 0 '       是否显示单位 0/1
+      .SetProperty "textPlacement", 0 '   0、上方,1、下方,2、中间
+    '  .SetProperty "dynamicText", 0 '    是否可以编辑尺寸0/1
     '  .SetProperty "overhang", 500000 '
     End With
   End If
@@ -492,7 +507,7 @@ Private Function Dimension_SetProperty(sh_dim As Shape, Optional ByVal Preset As
 #End If
 End Function
 
-'// 灏哄�鏍囨敞宸﹁竟
+'// 尺寸标注左边
 Private Sub Makesize_Left_MouseUp(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     CutLines.Dimension_MarkLines cdrAlignLeft, False
@@ -507,7 +522,7 @@ Private Sub Makesize_Left_MouseUp(ByVal Button As Integer, ByVal Shift As Intege
   End If
 End Sub
 
-'// 灏哄�鏍囨敞鍙宠竟
+'// 尺寸标注右边
 Private Sub Makesize_Right_MouseUp(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     CutLines.Dimension_MarkLines cdrAlignLeft, True
@@ -523,7 +538,7 @@ Private Sub Makesize_Right_MouseUp(ByVal Button As Integer, ByVal Shift As Integ
 
 End Sub
 
-'// 灏哄�鏍囨敞鍚戜笂
+'// 尺寸标注向上
 Private Sub Makesize_Up_MouseUp(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     CutLines.Dimension_MarkLines cdrAlignTop, False
@@ -538,7 +553,7 @@ Private Sub Makesize_Up_MouseUp(ByVal Button As Integer, ByVal Shift As Integer,
   End If
 End Sub
 
-'// 灏哄�鏍囨敞鍚戜笅
+'// 尺寸标注向下
 Private Sub Makesize_Down_MouseUp(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     CutLines.Dimension_MarkLines cdrAlignTop, True
@@ -558,16 +573,16 @@ Private Sub MakeRuler_MouseUp(ByVal Button As Integer, ByVal Shift As Integer, B
   API.BeginOpt
   Set sreg = Nothing
   
-  If Button = 2 And Shift = 0 Then       '// 榧犳爣鍙抽敭 鏍囨敞鍙宠竟
+  If Button = 2 And Shift = 0 Then       '// 鼠标右键 标注右边
     Ruler_Align cdrAlignRight
     
-  ElseIf Button = 2 And Shift = 2 Then  '// Ctrl+榧犳爣鍙抽敭 鏍囨敞宸﹁竟
+  ElseIf Button = 2 And Shift = 2 Then  '// Ctrl+鼠标右键 标注左边
     Ruler_Align cdrAlignLeft
  
-  ElseIf Shift = 0 Then    '// 榧犳爣宸﹂敭锛屾爣娉ㄥ湪涓婅竟
+  ElseIf Shift = 0 Then    '// 鼠标左键,标注在上边
     Ruler_Align cdrAlignTop
     
-  ElseIf Shift = 2 Then  '// Ctrl+榧犳爣宸﹂敭锛屾爣娉ㄤ笅杈�
+  ElseIf Shift = 2 Then  '// Ctrl+鼠标左键,标注下边
     Ruler_Align cdrAlignBottom
   End If
   
@@ -583,7 +598,7 @@ Private Sub MakeRuler_Align_MouseUp(ByVal Button As Integer, ByVal Shift As Inte
    
   Dim ra As cdrAlignType
   ra = cdrAlignTop
-  ' 瀹氫箟鏂瑰悜涓婁笅宸﹀彸
+  ' 定义方向上下左右
   Dim pos_x As Variant, pos_y As Variant
   pos_x = Array(27, 27, 12, 44)
   pos_y = Array(12, 44, 27, 27)
@@ -604,22 +619,22 @@ ErrorHandler:
 End Sub
 
 Private Function Ruler_Align(ra As cdrAlignType)
-  If ra = cdrAlignRight Then       '// 鏍囨敞鍙宠竟
+  If ra = cdrAlignRight Then       '// 标注右边
     CutLines.Dimension_MarkLines cdrAlignLeft, True
     Add_Ruler_Text_Y True
-  ElseIf ra = cdrAlignLeft Then  '// 鏍囨敞宸﹁竟
+  ElseIf ra = cdrAlignLeft Then  '// 标注左边
     CutLines.Dimension_MarkLines cdrAlignLeft, False
     Add_Ruler_Text_Y True
-  ElseIf ra = cdrAlignTop Then    '// 鏍囨敞涓婅竟
+  ElseIf ra = cdrAlignTop Then    '// 标注上边
     CutLines.Dimension_MarkLines cdrAlignTop, False
     Add_Ruler_Text True
-  ElseIf ra = cdrAlignBottom Then  '// 鏍囨敞涓嬭竟
+  ElseIf ra = cdrAlignBottom Then  '// 标注下边
     CutLines.Dimension_MarkLines cdrAlignTop, True
     Add_Ruler_Text True
   End If
 End Function
 
-  '// 鏍囧昂绾胯浆鎹㈡垚璺濈�鏁板瓧
+  '// 标尺线转换成距离数字
 Private Function Add_Ruler_Text(rm_lines As Boolean)
   On Error GoTo ErrorHandler
   API.BeginOpt
@@ -641,7 +656,7 @@ ErrorHandler:
   API.EndOpt
 End Function
 
-  '// 鏍囧昂绾胯浆鎹㈡垚璺濈�鏁板瓧
+  '// 标尺线转换成距离数字
 Private Function Add_Ruler_Text_Y(rm_lines As Boolean)
   On Error GoTo ErrorHandler
   API.BeginOpt
@@ -677,7 +692,7 @@ Private Sub I18N_LNG_Click()
     LNG_CODE = 1033
   End If
   SaveSetting "LYVBA", "Settings", "I18N_LNG", LNG_CODE
-  MsgBox "涓�嫳鏂囪�瑷€鍒囨崲瀹屾垚锛岃�閲嶅惎鎻掍欢!", vbOKOnly, "鍏伴泤VBA浠g爜鍒嗕韩"
+  MsgBox "中英文语言切换完成,请重启插件!", vbOKOnly, "兰雅VBA代码分享"
 End Sub
 
 
@@ -693,18 +708,18 @@ Private Sub btn_square_wi_Click()
   ModulePlus.square_hw "Width"
 End Sub
 
-'// 鑺傜偣杩炴帴鍚堝苟
+'// 节点连接合并
 Private Sub btn_join_nodes_Click()
     ActiveSelection.CustomCommand "ConvertTo", "JoinCurves"
     Application.Refresh
 End Sub
 
-'// 鑺傜偣浼樺寲鍑忓皯
+'// 节点优化减少
 Private Sub btn_nodes_reduce_Click()
   ModulePlus.Nodes_Reduce
 End Sub
 
-'// 閫夋嫨鏍囨敞绾� 閫夋嫨鏂囧瓧 鍒犻櫎鎴栬€呰В缁戞爣鍑嗙嚎
+'// 选择标注线 选择文字 删除或者解绑标准线
 Private Sub SelectText_Click()
   ModulePlus.Dimension_Select_or_Delete 4
 End Sub

+ 36 - 19
UI/Replace_UI.frm

@@ -1,14 +1,31 @@
+VERSION 5.00
+Begin {C62A69F0-16DC-11CE-9E98-00AA00574A4F} Replace_UI 
+   Caption         =   "使剪贴板上的物件替换选择的目标物件"
+   ClientHeight    =   4560
+   ClientLeft      =   45
+   ClientTop       =   330
+   ClientWidth     =   7590
+   OleObjectBlob   =   "Replace_UI.frx":0000
+   StartUpPosition =   1  'CenterOwner
+End
+Attribute VB_Name = "Replace_UI"
+Attribute VB_GlobalNameSpace = False
+Attribute VB_Creatable = False
+Attribute VB_PredeclaredId = True
+Attribute VB_Exposed = False
+
+
 #If VBA7 Then
-    Private Declare PtrSafe Function DrawMenuBar Lib "user32" (ByVal hWnd As Long) As Long
-    Private Declare PtrSafe Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
-    Private Declare PtrSafe Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
+    Private Declare PtrSafe Function DrawMenuBar Lib "user32" (ByVal hwnd As Long) As Long
+    Private Declare PtrSafe Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
+    Private Declare PtrSafe Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
     Private Declare PtrSafe Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
     Private Declare PtrSafe Function GetSystemMetrics Lib "user32" (ByVal nIndex As Long) As Long
     
 #Else
-    Private Declare Function DrawMenuBar Lib "user32" (ByVal hWnd As Long) As Long
-    Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
-    Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
+    Private Declare Function DrawMenuBar Lib "user32" (ByVal hwnd As Long) As Long
+    Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
+    Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
     Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
     Private Declare Function GetSystemMetrics Lib "user32" (ByVal nIndex As Long) As Long
 #End If
@@ -19,27 +36,27 @@ Private Const WS_EX_DLGMODALFRAME = &H1&
 
 
 Private Sub Close_Icon_Click()
-  Unload Me    '// 鍏抽棴
+  Unload Me    '// 关闭
 End Sub
 
 Private Sub UserForm_Initialize()
   Dim IStyle As Long
-  Dim hWnd As Long
+  Dim hwnd As Long
   
-  hWnd = FindWindow("ThunderDFrame", Me.Caption)
+  hwnd = FindWindow("ThunderDFrame", Me.Caption)
 
-  IStyle = GetWindowLong(hWnd, GWL_STYLE)
+  IStyle = GetWindowLong(hwnd, GWL_STYLE)
   IStyle = IStyle And Not WS_CAPTION
-  SetWindowLong hWnd, GWL_STYLE, IStyle
-  DrawMenuBar hWnd
-  IStyle = GetWindowLong(hWnd, GWL_EXSTYLE) And Not WS_EX_DLGMODALFRAME
-  SetWindowLong hWnd, GWL_EXSTYLE, IStyle
+  SetWindowLong hwnd, GWL_STYLE, IStyle
+  DrawMenuBar hwnd
+  IStyle = GetWindowLong(hwnd, GWL_EXSTYLE) And Not WS_EX_DLGMODALFRAME
+  SetWindowLong hwnd, GWL_EXSTYLE, IStyle
   
   With Me
   '  .StartUpPosition = 0
   '  .Left = 500
   '  .Top = 200
-    .Width = 378
+    .width = 378
     .Height = 228
   End With
   
@@ -73,7 +90,7 @@ Private Sub Image1_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, By
   ElseIf Abs(X - pos_x(0)) < 30 And Abs(Y - pos_y(2)) < 30 Then
     Call image_replace
   ElseIf Abs(X - pos_x(1)) < 30 And Abs(Y - pos_y(3)) < 30 Then
-    API.WebHelp "https://262235.xyz/index.php/tag/vba/"
+ '//   API.WebHelp "https://262235.xyz/index.php/tag/vba/"
   End If
   
   Replace_UI.Hide
@@ -111,7 +128,7 @@ Private Sub image_replace()
   Next sh
 
 ErrorHandler:
-'//    MsgBox "璇峰厛澶嶅埗鍥剧墖鐨勫畬鏁磋矾寰勶紝鏈�伐鍏疯兘鑷�姩鏇挎崲鍥剧墖!"
+'//    MsgBox "请先复制图片的完整路径,本工具能自动替换图片!"
   API.EndOpt
 End Sub
 
@@ -141,7 +158,7 @@ Private Sub copy_shape_replace_resize()
   Next sh
 
 ErrorHandler:
-'// MsgBox "璇峰厛澶嶅埗Ctrl+C锛岀劧鍚庨€夋嫨瑕佹浛鎹㈢殑鐗╀欢杩愯�鏈�伐鍏�!"
+'// MsgBox "请先复制Ctrl+C,然后选择要替换的物件运行本工具!"
   API.EndOpt
 End Sub
 
@@ -168,7 +185,7 @@ Private Sub copy_shape_replace()
   Next sh
 
 ErrorHandler:
-'// MsgBox "璇峰厛澶嶅埗Ctrl+C锛岀劧鍚庨€夋嫨瑕佹浛鎹㈢殑鐗╀欢杩愯�鏈�伐鍏�!"
+'// MsgBox "请先复制Ctrl+C,然后选择要替换的物件运行本工具!"
   API.EndOpt
 End Sub
 

+ 104 - 90
UI/Toolbar.frm

@@ -1,3 +1,17 @@
+VERSION 5.00
+Begin {C62A69F0-16DC-11CE-9E98-00AA00574A4F} Toolbar 
+   Caption         =   "Toolbar"
+   ClientHeight    =   4230
+   ClientLeft      =   45
+   ClientTop       =   330
+   ClientWidth     =   6840
+   OleObjectBlob   =   "Toolbar.frx":0000
+End
+Attribute VB_Name = "Toolbar"
+Attribute VB_GlobalNameSpace = False
+Attribute VB_Creatable = False
+Attribute VB_PredeclaredId = True
+Attribute VB_Exposed = False
 '// This is free and unencumbered software released into the public domain.
 '// For more information, please refer to  https://github.com/hongwenjun
 
@@ -54,7 +68,7 @@ End Sub
 
 Private Sub Change_UI_Close_Voice_Click()
   SaveSetting "LYVBA", "Settings", "SpeakHelp", "0"
-  MsgBox "璇风粰鎴戞敮鎸�!" & vbNewLine & "鎮ㄧ殑鏀�寔锛屾垜鎵嶈兘鏈夊姩鍔涙坊鍔犳洿澶氬姛鑳�." & vbNewLine & "铇�泤CorelVBA宸ュ叿 姘镐箙鍏嶈垂寮€婧�"
+  MsgBox "请给我支持!" & vbNewLine & "您的支持,我才能有动力添加更多功能." & vbNewLine & "蘭雅CorelVBA工具 永久免费开源"
 End Sub
 
 Private Sub I18N_LNG_Click()
@@ -65,7 +79,7 @@ Private Sub I18N_LNG_Click()
     LNG_CODE = 1033
   End If
   SaveSetting "LYVBA", "Settings", "I18N_LNG", LNG_CODE
-  MsgBox "涓�嫳鏂囪�瑷€鍒囨崲瀹屾垚锛岃�閲嶅惎鎻掍欢!", vbOKOnly, "鍏伴泤VBA浠g爜鍒嗕韩"
+  MsgBox "中英文语言切换完成,请重启插件!", vbOKOnly, "兰雅VBA代码分享"
 End Sub
 
 Private Sub UserForm_Initialize()
@@ -83,7 +97,7 @@ Private Sub UserForm_Initialize()
   
 With Me
   .StartUpPosition = 0
-  .Left = Val(GetSetting("LYVBA", "Settings", "Left", "400"))  ' 璁剧疆宸ュ叿鏍忎綅缃�
+  .Left = Val(GetSetting("LYVBA", "Settings", "Left", "400"))  ' 设置工具栏位置
   .Top = Val(GetSetting("LYVBA", "Settings", "Top", "55"))
   .Height = 30
   .width = 336
@@ -92,14 +106,14 @@ End With
   OutlineKey = True
   OptKey = True
 
-  ' 璇诲彇瑙掔嚎璁剧疆
+  ' 读取角线设置
   Bleed.text = API.GetSet("Bleed")
   Line_len.text = API.GetSet("Line_len")
   Outline_Width.text = GetSetting("LYVBA", "Settings", "Outline_Width", "0.2")
   
   UIFile = Path & "GMS\LYVBA\" & HDPI.GetHDPIPercentage & "\ToolBar.jpg"
   If API.ExistsFile_UseFso(UIFile) Then
-    UI.Picture = LoadPicture(UIFile)   '鎹�I鍥�
+    UI.Picture = LoadPicture(UIFile)   '换UI图
     Set pic1 = LoadPicture(UIFile)
   End If
 
@@ -109,11 +123,11 @@ End With
     UIL_Key = True
   End If
 
-  ' 绐楀彛閫忔槑, 鏈€灏忓寲鍙�樉绀轰竴涓�浘鏍�
+  ' 窗口透明, 最小化只显示一个图标
   #If VBA7 Then
     MakeUserFormTransparent Me, RGB(26, 22, 35)
   #Else
-  ' CorelDRAW X4 / Windows7 鑷�敤鍏抽棴閫忔槑
+  ' CorelDRAW X4 / Windows7 自用关闭透明
   #End If
 End Sub
 
@@ -159,7 +173,7 @@ Private Sub LOGO_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVa
   ElseIf Shift = fmCtrlMask Then
       mx = X: my = Y
   Else
-    Unload Me   ' Ctrl + 榧犳爣 鍏抽棴宸ュ叿
+    Unload Me   ' Ctrl + 鼠标 关闭工具
   End If
 End Sub
 
@@ -172,152 +186,152 @@ End Sub
 
 Private Sub UI_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   Dim c As New Color
-  ' 瀹氫箟鍥炬爣鍧愭爣pos
+  ' 定义图标坐标pos
   Dim pos_x As Variant, pos_y As Variant
   pos_y = Array(14)
   pos_x = Array(14, 41, 67, 94, 121, 148, 174, 201, 228, 254, 281, 308, 334, 361, 388, 415, 441, 468, 495)
 
-  '// 鎸変笅Ctrl閿�紝鏈€浼樺厛澶勭悊宸ュ叿鍔熻兘
+  '// 按下Ctrl键,最优先处理工具功能
   If Shift = 2 Then
     If Abs(X - pos_x(0)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 瀹夊叏绾匡紝娓呴櫎杈呭姪绾�
-      Tools.guideangle ActiveSelectionRange, 3    ' 宸﹂敭 3mm 鍑鸿�
+      '// 安全线,清除辅助线
+      Tools.guideangle ActiveSelectionRange, 3    ' 左键 3mm 出血
       
     ElseIf Abs(X - pos_x(1)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// Adobe AI EPS INDD PDF鍜孋orelDRAW 缂╃暐鍥惧伐鍏�
+      '// Adobe AI EPS INDD PDF和CorelDRAW 缩略图工具
       AdobeThumbnail_Click
       
     ElseIf Abs(X - pos_x(2)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 澶氱墿浠舵媶鍒嗙嚎娈�
+      '// 多物件拆分线段
       Tools.Split_Segment
       
     ElseIf Abs(X - pos_x(3)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鏅鸿兘鎷嗗瓧
+      '// 智能拆字
       Tools.Take_Apart_Character
       
     ElseIf Abs(X - pos_x(4)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鏆傛椂绌�
+      '// 暂时空
       
     ElseIf Abs(X - pos_x(5)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鏆傛椂绌�
+      '// 暂时空
       
     ElseIf Abs(X - pos_x(6)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鏈ㄥご浜烘櫤鑳界兢缁勶紝寮傚舰缇ょ粍
+      '// 木头人智能群组,异形群组
       autogroup("group", 1).CreateSelection
       
     ElseIf Abs(X - pos_x(8)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// CTRL鎵╁睍宸ュ叿鏍�
+      '// CTRL扩展工具栏
       Me.Height = 30 + 45
       
     ElseIf Abs(X - pos_x(9)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      ' 鏂囨湰杞�洸  鍙傛暟 all=1 锛屾敮鎸佹�閫夊拰鍥炬�鍓��鍐呯殑鏂囨湰
+      ' 文本转曲  参数 all=1 ,支持框选和图框剪裁内的文本
       ' Tools.TextShape_ConvertToCurves 1
     End If
     Exit Sub
   End If
 
 
-  '// 榧犳爣鍙抽敭 鎵╁睍閿�寜閽�紭鍏�  鏀剁缉宸ュ叿鏍�  鏍囪�鑼冨洿妗�  灞呬腑椤甸潰 灏哄�鍙栨暣鏁�  鍗曡壊榛戜腑绾挎爣璁� 鎵╁睍宸ュ叿鏍�  鎺掑垪宸ュ叿  鎵╁睍宸ュ叿鏍忔敹缂�
+  '// 鼠标右键 扩展键按钮优先  收缩工具栏  标记范围框  居中页面 尺寸取整数  单色黑中线标记 扩展工具栏  排列工具  扩展工具栏收缩
   If Button = 2 Then
     If Abs(X - pos_x(0)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鏀剁缉宸ュ叿鏍�
+      '// 收缩工具栏
       Me.width = 30: Me.Height = 30
       UI.Visible = False: LOGO.Visible = True
 
     ElseIf Abs(X - pos_x(1)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 灞呬腑椤甸潰
+      '// 居中页面
       Tools.Align_Page_Center
 
     ElseIf Abs(X - pos_x(2)) < 14 And Abs(Y - pos_y(0)) < 14 Then
     
       If Github_Version = 1 Then
-        '// 鍗曠嚎鏉¤浆瑁佸垏绾� - 鏀剧疆鍒伴〉闈㈠洓杈�
+        '// 单线条转裁切线 - 放置到页面四边
         CutLines.SelectLine_to_Cropline
       Else
-        '// 鏍囪�鑼冨洿妗�
+        '// 标记范围框
         Tools.Mark_Range_Box
       End If
 
     ElseIf Abs(X - pos_x(3)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鎵归噺璁剧疆鐗╀欢灏哄�鏁存暟
+      '// 批量设置物件尺寸整数
       Tools.Size_to_Integer
     
-    '//鍒嗗垎鍚堝悎鎶婂嚑涓�姛鑳芥寜閿�悎骞跺埌涓€璧凤紝瀹氫箟鍒板彸閿�笂
+    '//分分合合把几个功能按键合并到一起,定义到右键上
     ElseIf Abs(X - pos_x(4)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-     '// Tools.鍒嗗垎鍚堝悎
+     '// Tools.分分合合
 
     ElseIf Abs(X - pos_x(5)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鑷�姩涓�嚎鑹查樁鏉� 榛戠櫧
+      '// 自动中线色阶条 黑白
       AutoColorMark.Auto_ColorMark_K
 
     ElseIf Abs(X - pos_x(6)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-     '// 鏅鸿兘缇ょ粍
+     '// 智能群组
       SmartGroup.Smart_Group API.Create_Tolerance
       
     ElseIf Abs(X - pos_x(7)) < 14 And Abs(Y - pos_y(0)) < 14 Then
     If Github_Version = 1 Then
       CQL_FIND_UI.Show 0
     Else
-      '// 閫夋嫨鐩稿悓宸ュ叿澧炲己鐗�
+      '// 选择相同工具增强版
       frmSelectSame.Show 0
     End If
 
     ElseIf Abs(X - pos_x(8)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鍙抽敭鎵╁睍宸ュ叿鏍�
+      '// 右键扩展工具栏
       Me.Height = 30 + 45
       
     ElseIf Abs(X - pos_x(9)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-     '// 鏂囨湰缁熻�淇℃伅
+     '// 文本统计信息
      Application.FrameWork.Automation.InvokeItem "bf3bd8fe-ca26-4fe0-91b0-3b5c99786fb6"
 
     ElseIf Abs(X - pos_x(10)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鍙抽敭鎺掑垪宸ュ叿
+      '// 右键排列工具
       TOP_ALIGN_BT.Visible = True
       LEFT_ALIGN_BT.Visible = True
 
     ElseIf Abs(X - pos_x(11)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-      '// 鍙抽敭鎵╁睍宸ュ叿鏍忔敹缂�
+      '// 右键扩展工具栏收缩
       Me.Height = 30
       
     End If
     Exit Sub
   End If
   
-  '// 榧犳爣宸﹂敭 鍗曞嚮鎸夐挳鍔熻兘  鎸夊伐鍏锋爮涓婂浘鏍囨�甯稿姛鑳�
+  '// 鼠标左键 单击按钮功能  按工具栏上图标正常功能
   If Abs(X - pos_x(0)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-   '// 瑁佸垏绾�: 鎵归噺鐗╀欢瑁佸垏绾�
+   '// 裁切线: 批量物件裁切线
     CutLines.Batch_CutLines
     
   ElseIf Abs(X - pos_x(1)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-  '// 鍓�创鏉垮昂瀵稿缓绔嬬煩褰�
+  '// 剪贴板尺寸建立矩形
     ClipbRectangle.Build_Rectangle
     
   ElseIf Abs(X - pos_x(2)) < 14 And Abs(Y - pos_y(0)) < 14 Then
     If Github_Version = 1 Then
       MakeSizePlus.Show 0
     Else
-      '// 鍗曠嚎鏉¤浆瑁佸垏绾� - 鏀剧疆鍒伴〉闈㈠洓杈�
+      '// 单线条转裁切线 - 放置到页面四边
       CutLines.SelectLine_to_Cropline
     End If
   ElseIf Abs(X - pos_x(3)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-    '// 鎷肩増.Arrange
+    '// 拼版.Arrange
     Arrange.Arrange
     
   ElseIf Abs(X - pos_x(4)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-    '// 鎷肩増瑁佸垏绾�
+    '// 拼版裁切线
     CutLines.Draw_Lines
     
   ElseIf Abs(X - pos_x(5)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-    '// 鑷�姩涓�嚎鑹查樁鏉� 褰╄壊
+    '// 自动中线色阶条 彩色
     AutoColorMark.Auto_ColorMark
     
   ElseIf Abs(X - pos_x(6)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-   '// 鏅鸿兘缇ょ粍 娌″�宸�
+   '// 智能群组 没容差
     SmartGroup.Smart_Group
     
   ElseIf Abs(X - pos_x(7)) < 14 And Abs(Y - pos_y(0)) < 14 Then
     If Github_Version = 1 Then
-       '// 閫夋嫨鐩稿悓宸ュ叿澧炲己鐗�
+       '// 选择相同工具增强版
       frmSelectSame.Show 0
     Else
       CQL_FIND_UI.Show 0
@@ -327,54 +341,54 @@ Private Sub UI_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal
     Replace_UI.Show 0
     
   ElseIf Abs(X - pos_x(9)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-    ' 绠€鍗曟枃鏈�浆鏇�
+    ' 简单文本转曲
     Tools.TextShape_ConvertToCurves 0
     
   ElseIf Abs(X - pos_x(10)) < 14 And Abs(Y - pos_y(0)) < 14 Then
-    '// 鎵╁睍宸ュ叿鏍�
+    '// 扩展工具栏
     Me.Height = 30 + 45
     
-    Speak_Msg "宸﹀彸閿�湁涓嶅悓鍔熻兘"
+    Speak_Msg "左右键有不同功能"
     
   ElseIf Abs(X - pos_x(11)) < 14 And Abs(Y - pos_y(0)) < 14 Then
     If Me.Height > 30 Then
       Me.Height = 30
     Else
-      '// 鏈€灏忓寲
+      '// 最小化
       Me.width = 30
       Me.Height = 30
       OPEN_UI_BIG.Left = 31
       UI.Visible = False
       LOGO.Visible = True
   
-      ' 淇濆瓨宸ュ叿鏉′綅缃� Left 鍜� Top
+      ' 保存工具条位置 Left 和 Top
       SaveSetting "LYVBA", "Settings", "Left", Me.Left
       SaveSetting "LYVBA", "Settings", "Top", Me.Top
     
-      Speak_Msg "宸﹂敭缂╁皬 鍙抽敭鏀剁缉"
+      Speak_Msg "左键缩小 右键收缩"
     End If
   End If
 
 End Sub
 
 Private Sub X_EXIT_Click()
-  Unload Me    ' 鍏抽棴
+  Unload Me    ' 关闭
 End Sub
 
-'// 澶氶〉鍚堝苟宸ュ叿锛屽凡缁忓悎骞跺埌涓荤嚎宸ュ叿
-' Private Sub 璋冪敤澶氶〉鍚堝苟宸ュ叿()
+'// 多页合并工具,已经合并到主线工具
+' Private Sub 调用多页合并工具()
 '  Dim value As Integer
-'  value = GMSManager.RunMacro("鍚堝苟澶氶〉宸ュ叿", "鍚堝苟澶氶〉杩愯�.run")
+'  value = GMSManager.RunMacro("合并多页工具", "合并多页运行.run")
 ' End Sub
 
-'''///  璐�績鍟嗕汉鍜屽ソ鐜╁伐鍏风瓑  ///'''
+'''///  贪心商人和好玩工具等  ///'''
 Private Sub Cdr_Nodes_BT_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     TSP.Nodes_To_TSP
   ElseIf Shift = fmCtrlMask Then
     TSP.CDR_TO_TSP
   Else
-    ' Ctrl + 榧犳爣  绌�
+    ' Ctrl + 鼠标  空
   End If
 End Sub
 
@@ -400,7 +414,7 @@ Private Sub TSP2DRAW_LINE_MouseDown(ByVal Button As Integer, ByVal Shift As Inte
   ElseIf Shift = fmCtrlMask Then
     TSP.TSP_TO_DRAW_LINES
   Else
-    ' Ctrl + 榧犳爣  绌�
+    ' Ctrl + 鼠标  空
   End If
 End Sub
 
@@ -425,7 +439,7 @@ Private Sub BITMAP_MAKE_DOTS_Click()
   TSP.BITMAP_MAKE_DOTS
 End Sub
 
-'''///  Python鑴氭湰鍜屼簩缁寸爜绛�  ///'''
+'''///  Python脚本和二维码等  ///'''
 Private Sub Organize_Size_Click()
   Tools.Python_Organize_Size
 End Sub
@@ -445,8 +459,8 @@ End Sub
 
 Private Sub OPEN_UI_BIG_Click()
   Unload Me
-  MsgBox "璇风粰鎴戞敮鎸�!" & vbNewLine & "鎮ㄧ殑鏀�寔锛屾垜鎵嶈兘鏈夊姩鍔涙坊鍔犳洿澶氬姛鑳�." & vbNewLine & "铇�泤CorelVBA宸ュ叿 姘镐箙鍏嶈垂寮€婧�" _
-       & vbNewLine & "婧愮爜缃戝潃:" & vbNewLine & "https://github.com/hongwenjun/corelvba"
+  MsgBox "请给我支持!" & vbNewLine & "您的支持,我才能有动力添加更多功能." & vbNewLine & "蘭雅CorelVBA工具 永久免费开源" _
+       & vbNewLine & "源码网址:" & vbNewLine & "https://github.com/hongwenjun/corelvba"
 End Sub
 
 Private Sub Settings_Click()
@@ -456,7 +470,7 @@ Private Sub Settings_Click()
    SaveSetting "LYVBA", "Settings", "Outline_Width", Outline_Width.text
   End If
 
-  ' 淇濆瓨宸ュ叿鏉′綅缃� Left 鍜� Top
+  ' 保存工具条位置 Left 和 Top
   SaveSetting "LYVBA", "Settings", "Left", Me.Left
   SaveSetting "LYVBA", "Settings", "Top", Me.Top
   
@@ -464,16 +478,16 @@ Private Sub Settings_Click()
 End Sub
 
 
-'''/////////  鍥炬爣榧犳爣宸﹀彸鐐瑰嚮鍔熻兘璋冪敤   /////////'''
+'''/////////  图标鼠标左右点击功能调用   /////////'''
 
 Private Sub Tools_Icon_Click()
-  ' 璋冪敤璇�彞
+  ' 调用语句
   i = GMSManager.RunMacro("ZeroBase", "Hello_VBA.run")
 End Sub
 
 Private Sub Split_Segment_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
-    MsgBox "宸﹂敭鎷嗗垎绾挎�锛孋trl鍚堝苟绾挎�"
+    MsgBox "左键拆分线段,Ctrl合并线段"
   ElseIf Shift = fmCtrlMask Then
     Tools.Split_Segment
   Else
@@ -481,10 +495,10 @@ Private Sub Split_Segment_MouseDown(ByVal Button As Integer, ByVal Shift As Inte
     Application.Refresh
   End If
   
-  Speak_Msg "鎷嗗垎绾挎�锛孋trl鍚堝苟绾挎�"
+  Speak_Msg "拆分线段,Ctrl合并线段"
 End Sub
 
-'''////  CorelDRAW 涓� Adobe_Illustrator 鍓�创鏉胯浆鎹�  ////'''
+'''////  CorelDRAW 与 Adobe_Illustrator 剪贴板转换  ////'''
 Private Sub Adobe_Illustrator_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   Dim value As Integer
   If Button = 2 Then
@@ -494,11 +508,11 @@ Private Sub Adobe_Illustrator_MouseDown(ByVal Button As Integer, ByVal Shift As
   
   If Button Then
     value = GMSManager.RunMacro("AIClipboard", "CopyPaste.CopyAIFormat")
-    MsgBox "CorelDRAW 涓� Adobe_Illustrator 鍓�创鏉胯浆鎹�" & vbNewLine & "榧犳爣宸﹂敭澶嶅埗锛岄紶鏍囧彸閿�矘璐�"
+    MsgBox "CorelDRAW 与 Adobe_Illustrator 剪贴板转换" & vbNewLine & "鼠标左键复制,鼠标右键粘贴"
   End If
 End Sub
 
-'''////  鏍囪�鐢绘� 鏀�寔瀹瑰樊  ////'''
+'''////  标记画框 支持容差  ////'''
 Private Sub Mark_CreateRectangle_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     Tools.Mark_CreateRectangle True
@@ -507,10 +521,10 @@ Private Sub Mark_CreateRectangle_MouseDown(ByVal Button As Integer, ByVal Shift
   Else
     Create_Tolerance
   End If
-  Speak_Msg "鏍囪�鐢绘�  鍙抽敭鏀�寔瀹瑰樊"
+  Speak_Msg "标记画框  右键支持容差"
 End Sub
 
-'''////  涓€閿�媶寮€澶氳�缁勫悎鐨勬枃瀛楀瓧绗�  ////'''
+'''////  一键拆开多行组合的文字字符  ////'''
 Private Sub Batch_Combine_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     Tools.Batch_Combine
@@ -521,7 +535,7 @@ Private Sub Batch_Combine_MouseDown(ByVal Button As Integer, ByVal Shift As Inte
   End If
 End Sub
 
-'''////  绠€鍗曚竴鍒€鍒�  ////'''
+'''////  简单一刀切  ////'''
 Private Sub Single_Line_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     Tools.Single_Line_Vertical
@@ -532,7 +546,7 @@ Private Sub Single_Line_MouseDown(ByVal Button As Integer, ByVal Shift As Intege
   End If
 End Sub
 
-'''////  鍌荤摐鐏�溅鎺掑垪  ////'''
+'''////  傻瓜火车排列  ////'''
 Private Sub TOP_ALIGN_BT_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     Tools.Simple_Train_Arrangement 3#
@@ -543,7 +557,7 @@ Private Sub TOP_ALIGN_BT_MouseDown(ByVal Button As Integer, ByVal Shift As Integ
   End If
 End Sub
 
-'''////  鍌荤摐闃舵�鎺掑垪  ////'''
+'''////  傻瓜阶梯排列  ////'''
 Private Sub LEFT_ALIGN_BT_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     Tools.Simple_Ladder_Arrangement 3#
@@ -555,28 +569,28 @@ Private Sub LEFT_ALIGN_BT_MouseDown(ByVal Button As Integer, ByVal Shift As Inte
 End Sub
 
 
-'''////  宸﹂敭-澶氶〉鍚堝苟涓€椤靛伐鍏�   鍙抽敭-鎵归噺澶氶〉灞呬腑 ////'''
+'''////  左键-多页合并一页工具   右键-批量多页居中 ////'''
 Private Sub UniteOne_BT_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
     Tools.Batch_Align_Page_Center
   ElseIf Shift = fmCtrlMask Then
     UniteOne.Show 0
   Else
-    ' Ctrl + 榧犳爣  绌�
+    ' Ctrl + 鼠标  空
   End If
 End Sub
 
-'''////  Adobe AI EPS INDD PDF鍜孋orelDRAW 缂╃暐鍥惧伐鍏�  ////'''
+'''////  Adobe AI EPS INDD PDF和CorelDRAW 缩略图工具  ////'''
 Private Sub AdobeThumbnail_Click()
     Dim h As Long, r As Long
     mypath = Path & "GMS\LYVBA\"
     App = mypath & "GuiAdobeThumbnail.exe"
     
-    h = FindWindow(vbNullString, "CorelVBA 闈掑勾鑺� By 铇�泤sRGB")
+    h = FindWindow(vbNullString, "CorelVBA 青年节 By 蘭雅sRGB")
     i = ShellExecute(h, "", App, "", mypath, 1)
 End Sub
 
-'''////  蹇�€熼�鑹查€夋嫨  ////'''
+'''////  快速颜色选择  ////'''
 Private Sub Quick_Color_Select_Click()
   Tools.quickColorSelect
 End Sub
@@ -587,42 +601,42 @@ Private Sub Cut_Cake_MouseDown(ByVal Button As Integer, ByVal Shift As Integer,
   ElseIf Shift = fmCtrlMask Then
     Tools.divideHorizontally
   Else
-    ' Ctrl + 榧犳爣  绌�
+    ' Ctrl + 鼠标  空
   End If
 End Sub
 
-'// 瀹夊叏杈呭姪绾垮姛鑳斤紝涓夐敭鎺у埗锛岃�鍘岃緟鍔╃嚎鐨勪篃鍙�互鐢ㄦ潵鍒犻櫎杈呭姪绾�
+'// 安全辅助线功能,三键控制,讨厌辅助线的也可以用来删除辅助线
 Private Sub Safe_Guideangle_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
-    Tools.guideangle ActiveSelectionRange, 0#   ' 鍙抽敭0璺濈�璐寸揣
+    Tools.guideangle ActiveSelectionRange, 0#   ' 右键0距离贴紧
   ElseIf Shift = fmCtrlMask Then
-    Tools.guideangle ActiveSelectionRange, 3    ' 宸﹂敭 3mm 鍑鸿�
+    Tools.guideangle ActiveSelectionRange, 3    ' 左键 3mm 出血
   Else
-    Tools.guideangle ActiveSelectionRange, -Set_Space_Width     ' Ctrl + 榧犳爣宸﹂敭 鑷�畾涔夐棿闅�
+    Tools.guideangle ActiveSelectionRange, -Set_Space_Width     ' Ctrl + 鼠标左键 自定义间隔
   End If
 End Sub
 
-'// 鏍囧噯灏哄�锛屽乏閿�彸閿瓹trl涓夐敭鎺у埗锛岃皟鐢ㄤ笁绉嶆牱寮�
+'// 标准尺寸,左键右键Ctrl三键控制,调用三种样式
 Private Sub btn_makesizes_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
   If Button = 2 Then
-    Make_SIZE.Show 0   ' 鍙抽敭
+    Make_SIZE.Show 0   ' 右键
   ElseIf Shift = fmCtrlMask Then
     #If VBA7 Then
       MakeSizePlus.Show 0
-    #Else  ' X4 浣跨敤
+    #Else  ' X4 使用
       Make_SIZE.Show 0
     #End If
   Else
-    Tools.Simple_Label_Numbers  ' Ctrl + 榧犳爣  鎵归噺绠€鍗曟暟瀛楁爣娉�
+    Tools.Simple_Label_Numbers  ' Ctrl + 鼠标  批量简单数字标注
   End If
 End Sub
 
-'// 鎵归噺杞�浘鐗囧拰瀵煎嚭鍥剧墖鏂囦欢
+'// 批量转图片和导出图片文件
 Private Sub Photo_Form_Click()
   PhotoForm.Show 0
 End Sub
 
-'// 淇��鍦嗚�缂鸿�鍒扮洿瑙�
+'// 修复圆角缺角到直角
 Private Sub btn_corners_off_Click()
   Tools.corner_off
 End Sub
@@ -648,7 +662,7 @@ Private Sub SwapShape_Click()
 End Sub
 
 
-'// 灏忓伐鍏峰揩閫熷惎鍔�
+'// 小工具快速启动
 Private Sub Open_Calc_Click()
   Launcher.START_Calc
 End Sub