mirror of
https://github.com/morgan9e/macos-stats
synced 2026-04-14 00:04:15 +09:00
fix: fixed crash when calculating text width for a monospaced font (#1988)
This commit is contained in:
@@ -136,7 +136,7 @@ public class StackWidget: WidgetWrapper {
|
||||
private func drawOneRow(_ x: CGFloat, _ element: Stack_t) -> CGFloat {
|
||||
var font: NSFont = NSFont.systemFont(ofSize: 13, weight: .regular)
|
||||
if self.monospacedFontState {
|
||||
font = NSFont.monospacedSystemFont(ofSize: 13, weight: .regular)
|
||||
font = NSFont.monospacedDigitSystemFont(ofSize: 13, weight: .regular)
|
||||
}
|
||||
|
||||
let style = NSMutableParagraphStyle()
|
||||
|
||||
Reference in New Issue
Block a user