Skip to content

Commit 96c4b19

Browse files
committed
status bar: fix layout shift of icons on the left
1 parent bead4b2 commit 96c4b19

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/server.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@ class AppDelegate: NSObject, NSApplicationDelegate {
4646

4747
signal(SIGTERM, signalHandler)
4848

49-
AppDelegate.statusItem = NSStatusBar.system.statusItem(withLength: NSStatusItem.variableLength)
49+
// NSStatusItem.variableLength causes layout shift of icons on the left when switching between en and 拼.
50+
AppDelegate.statusItem = NSStatusBar.system.statusItem(withLength: NSStatusItem.squareLength)
5051

5152
if let button = AppDelegate.statusItem?.button {
5253
button.action = #selector(handleStatusItemClick)

0 commit comments

Comments
 (0)