Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ Users install via the one-liner in README (`install.sh` fetches the DMG and veri

## Packaging

- `packaging/appicon.png` - source icon (1024px black circle, transparent background)
- `packaging/appicon.png` - source icon (1024px, stack Z design: shadow square + framed Z, transparent background)
- `packaging/mkicns.sh` - generates `Zee.icns` from `appicon.png` (via `make icns`)
- `packaging/mkdmg.sh` - creates DMG with Zee.app + Applications symlink (via `make app`)
- `packaging/Info.plist` - app bundle metadata (version templated from git tag)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<p align="center">
<img src="eye.gif" alt="zee" width="264"><br>
<img src="zee-logo-stack.svg" alt="zee" width="180"><br>
<strong>zee</strong><br><br>
Voice transcription that stays out of your way.<br>
Supports Groq, OpenAI, Mistral, ElevenLabs and Deepgram models.<br>
Expand Down
Binary file modified packaging/appicon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
62 changes: 9 additions & 53 deletions tray/icons.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,60 +2,16 @@

package tray

import (
"bytes"
"image"
"image/color"
"image/png"
"math"
)
import _ "embed"

var (
iconIdle []byte
iconIdleHi []byte
iconRecHi []byte
iconWarnHi []byte
)

func init() {
transparent := color.RGBA{A: 0}
red := color.RGBA{R: 255, G: 59, B: 48, A: 255}
amber := color.RGBA{R: 255, G: 230, B: 0, A: 255}
dotR := 44.0 / 6.5
iconIdle = renderIcon(22, &transparent, 22.0/8, nil, 0)
iconIdleHi = renderIcon(44, &transparent, 44.0/8, nil, 0)
iconRecHi = renderIcon(44, &red, dotR, nil, 0)
iconWarnHi = renderIcon(44, &amber, dotR, nil, 0)
}
//go:embed icon_idle.png

Check failure on line 8 in tray/icons.go

View workflow job for this annotation

GitHub Actions / integration

pattern icon_idle.png: no matching files found
iconIdle []byte
iconIdleHi = iconIdle

func encodePNG(img image.Image) []byte {
var buf bytes.Buffer
if err := png.Encode(&buf, img); err != nil {
panic("encodePNG: " + err.Error())
}
return buf.Bytes()
}

func drawCircleIcon(img *image.RGBA, size int, dot *color.RGBA, dotR float64, inner *color.RGBA, innerR float64) {
cx, cy := float64(size)/2, float64(size)/2
r := float64(size)/2 - 1
for y := range size {
for x := range size {
d := math.Hypot(float64(x)+0.5-cx, float64(y)+0.5-cy)
if inner != nil && d <= innerR {
img.Set(x, y, inner)
} else if dot != nil && d <= dotR {
img.Set(x, y, dot)
} else if d <= r {
img.Set(x, y, color.Black)
}
}
}
}

func renderIcon(size int, dot *color.RGBA, dotR float64, inner *color.RGBA, innerR float64) []byte {
img := image.NewRGBA(image.Rect(0, 0, size, size))
drawCircleIcon(img, size, dot, dotR, inner, innerR)
return encodePNG(img)
}
//go:embed icon_rec.png
iconRecHi []byte

//go:embed icon_warn.png
iconWarnHi []byte
)
Loading