Skip to content

Commit

Permalink
CurrencyBarItem: fix text vertical alignment
Browse files Browse the repository at this point in the history
  • Loading branch information
bobrosoft committed Jul 27, 2019
1 parent 58e4160 commit 67aaa2a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion MTMR/Widgets/CurrencyBarItem.swift
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ class CurrencyBarItem: CustomButtonTouchBarItem {
}

let regularFont = attributedTitle.attribute(.font, at: 0, effectiveRange: nil) as? NSFont ?? NSFont.systemFont(ofSize: 15)
let newTitle = NSMutableAttributedString(string: title as String, attributes: [.foregroundColor: color, .font: regularFont])
let newTitle = NSMutableAttributedString(string: title as String, attributes: [.foregroundColor: color, .font: regularFont, .baselineOffset: 1])
newTitle.setAlignment(.center, range: NSRange(location: 0, length: title.count))
attributedTitle = newTitle
}
Expand Down

0 comments on commit 67aaa2a

Please sign in to comment.