MirrorBar Plus 11: clock font, more colors and logo shapes, charging color, emoji button

Clock font picker (16 fonts), 8 more bar colors, 8 more logo/tray/clock colors, 6 new Windows logo shapes, battery charging color picker, and an emoji panel button (Win+.) on the bar with a show/hide tickbox and right-click item.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JW57Zw8fvgzpeDkbUYT7sG
This commit is contained in:
2026-11-20 15:50:20 +00:00
co-authored by Claude Sonnet 5.5
parent 93f6b94d98
commit eab5a47495
8 changed files with 286 additions and 21 deletions
+36 -8
View File
@@ -83,6 +83,9 @@ const (
idShowBattery = 224
idShowVolume = 225
idShowWifi = 226
idShowEmoji = 227
idClockFont = 228
idChargeColor = 229
)
var (
@@ -97,6 +100,7 @@ var (
ctlGroup, ctlAutoHide uintptr
ctlBarColor, ctlLogoStyle, ctlClockSize, ctlClockBold uintptr
ctlShowBattery, ctlShowVolume, ctlShowWifi uintptr
ctlShowEmoji, ctlClockFont, ctlChargeColor uintptr
zipSyncing bool // true while the program itself is filling in the ZIP box
)
@@ -217,13 +221,18 @@ func openSettings() {
ctlBarColor = combo2(16, idBarColor)
label2("Windows logo shape", 52)
ctlLogoStyle = combo2(52, idLogoStyle)
label2("Clock text size", 88)
ctlClockSize = combo2(88, idClockSize)
ctlClockBold = makeControl(hw, inst, "BUTTON", "Bold clock text", bsAutoCheckBox|wsTabStop, 416, 124, 368, 22, idClockBold)
makeControl(hw, inst, "STATIC", "Show on the bar:", 0, 416, 172, 368, 20, 0)
ctlShowBattery = makeControl(hw, inst, "BUTTON", "Battery", bsAutoCheckBox|wsTabStop, 416, 198, 368, 22, idShowBattery)
ctlShowVolume = makeControl(hw, inst, "BUTTON", "Volume", bsAutoCheckBox|wsTabStop, 416, 226, 368, 22, idShowVolume)
ctlShowWifi = makeControl(hw, inst, "BUTTON", "Wifi", bsAutoCheckBox|wsTabStop, 416, 254, 368, 22, idShowWifi)
label2("Clock font", 88)
ctlClockFont = combo2(88, idClockFont)
label2("Clock text size", 124)
ctlClockSize = combo2(124, idClockSize)
ctlClockBold = makeControl(hw, inst, "BUTTON", "Bold clock text", bsAutoCheckBox|wsTabStop, 416, 160, 368, 22, idClockBold)
label2("Battery charging color", 196)
ctlChargeColor = combo2(196, idChargeColor)
makeControl(hw, inst, "STATIC", "Show on the bar:", 0, 416, 244, 368, 20, 0)
ctlShowBattery = makeControl(hw, inst, "BUTTON", "Battery", bsAutoCheckBox|wsTabStop, 416, 270, 368, 22, idShowBattery)
ctlShowVolume = makeControl(hw, inst, "BUTTON", "Volume", bsAutoCheckBox|wsTabStop, 416, 298, 368, 22, idShowVolume)
ctlShowWifi = makeControl(hw, inst, "BUTTON", "Wifi", bsAutoCheckBox|wsTabStop, 416, 326, 368, 22, idShowWifi)
ctlShowEmoji = makeControl(hw, inst, "BUTTON", "Emoji panel button", bsAutoCheckBox|wsTabStop, 416, 354, 368, 22, idShowEmoji)
for _, b := range barPalette {
pSendMessage.Call(ctlBarColor, cbAddString, 0, uintptr(unsafe.Pointer(u16(b.name))))
}
@@ -233,6 +242,16 @@ func openSettings() {
for _, c := range clockSizes {
pSendMessage.Call(ctlClockSize, cbAddString, 0, uintptr(unsafe.Pointer(u16(c.name))))
}
for i, f := range clockFonts {
name := f
if i == 0 {
name = f + " (default)"
}
pSendMessage.Call(ctlClockFont, cbAddString, 0, uintptr(unsafe.Pointer(u16(name))))
}
for _, c := range chargeColors {
pSendMessage.Call(ctlChargeColor, cbAddString, 0, uintptr(unsafe.Pointer(u16(c.name))))
}
makeControl(hw, inst, "BUTTON", "Reset position", bsPushButton|wsTabStop, 16, 526, 116, 28, idResetPos)
makeControl(hw, inst, "BUTTON", "Reset bar width", bsPushButton|wsTabStop, 140, 526, 116, 28, idResetWidth)
@@ -268,6 +287,9 @@ func settingsSync() {
pSendMessage.Call(ctlLogoStyle, cbSetCurSel, uintptr(logoStyle), 0)
pSendMessage.Call(ctlClockSize, cbSetCurSel, uintptr(clockSizeIx), 0)
pSendMessage.Call(ctlClockBold, bmSetCheck, boolWP(clockBold), 0)
pSendMessage.Call(ctlClockFont, cbSetCurSel, uintptr(clockFontIx), 0)
pSendMessage.Call(ctlChargeColor, cbSetCurSel, uintptr(chargeIx), 0)
pSendMessage.Call(ctlShowEmoji, bmSetCheck, boolWP(showEmoji), 0)
pSendMessage.Call(ctlShowBattery, bmSetCheck, boolWP(showBattery), 0)
pSendMessage.Call(ctlShowVolume, bmSetCheck, boolWP(showVolume), 0)
pSendMessage.Call(ctlShowWifi, bmSetCheck, boolWP(showWifi), 0)
@@ -381,7 +403,7 @@ func settingsCommand(id, note uintptr) {
setGroupWins(checked(ctlGroup))
case idAutoHide:
setAutoHide(checked(ctlAutoHide))
case idBarColor, idLogoStyle, idClockSize:
case idBarColor, idLogoStyle, idClockSize, idClockFont, idChargeColor:
if note != cbnSelChange {
return
}
@@ -392,6 +414,10 @@ func settingsCommand(id, note uintptr) {
setLogoStyle(comboChoice(ctlLogoStyle))
case idClockSize:
setClockSize(comboChoice(ctlClockSize))
case idClockFont:
setClockFont(comboChoice(ctlClockFont))
case idChargeColor:
setChargeColor(comboChoice(ctlChargeColor))
}
case idClockBold:
setClockBold(checked(ctlClockBold))
@@ -401,6 +427,8 @@ func settingsCommand(id, note uintptr) {
setShowVolume(checked(ctlShowVolume))
case idShowWifi:
setShowWifi(checked(ctlShowWifi))
case idShowEmoji:
setShowEmoji(checked(ctlShowEmoji))
case idAutostart:
setAutostart(checked(ctlAutostart))
settingsSync()