Skip to content

Commit

Permalink
use mone font for delay display
Browse files Browse the repository at this point in the history
  • Loading branch information
yichengchen committed Apr 25, 2020
1 parent 69e344b commit d6ad8d8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ClashX/Views/ProxyItemView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class ProxyItemView: MenuItemBaseView {
delayLabel.translatesAutoresizingMaskIntoConstraints = false

nameLabel.font = type(of: self).labelFont
delayLabel.font = NSFont.menuBarFont(ofSize: 11)
delayLabel.font = NSFont.monospacedDigitSystemFont(ofSize: 11, weight: .regular)
nameLabel.alignment = .left
delayLabel.alignment = .right

Expand Down
2 changes: 1 addition & 1 deletion ClashX/Views/ProxyMenuItem.swift
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ extension ProxyMenuItem {
attributed.addAttributes(hackAttr, range: NSRange(name.utf16.count..<name.utf16.count + 1))

if delay != nil {
let delayAttr = [NSAttributedString.Key.font: NSFont.menuBarFont(ofSize: 12)]
let delayAttr = [NSAttributedString.Key.font: NSFont.monospacedDigitSystemFont(ofSize: 12, weight: .regular)]
attributed.addAttributes(delayAttr, range: NSRange(name.utf16.count + 1..<str.utf16.count))
}
return attributed
Expand Down

0 comments on commit d6ad8d8

Please sign in to comment.