Browse Source

【fix】【页面编辑】夜间模式分隔符看不清

tangchao 5 months ago
parent
commit
2f73da0c30

+ 5 - 1
PDF Office/PDF Master/Class/PDFWindowController/Toolbar/KMToolbarItemView.swift

@@ -303,7 +303,11 @@ extension KMToolbarItemView {
             KMContextTranslateCTM(context, NSWidth(dirtyRect)/2.0, NSHeight(dirtyRect)/2.0-10)
             KMContextMoveToPoint(context, 0, 0)
             KMContextAddLineToPoint(context, 0, 20)
-            KMContextSetStrokeColorWithColor(context, NSColor(red: 0, green: 0, blue: 0, alpha: 0.1).cgColor)
+            if (KMAppearance.isDarkMode()) {
+                KMContextSetStrokeColorWithColor(context, KMAppearance.separatorLineColor().cgColor)
+            } else {
+                KMContextSetStrokeColorWithColor(context, NSColor(red: 0, green: 0, blue: 0, alpha: 0.1).cgColor)
+            }
             KMContextStrokePath(context)
             KMContextRestoreGState(context)
         }