From 3b3b1c0f4503209618d4fb1b735a995d1ab0239d Mon Sep 17 00:00:00 2001 From: agent Date: Mon, 26 Oct 2026 14:05:54 +0000 Subject: [PATCH 1/2] Fix top-bar icon showing as three dots The AppIndicator extension looks up IconName with a fresh icon theme whose search path is *only* our IconThemePath (data/icons), replacing the system dirs. Without the system hicolor/index.theme it didn't know about symbolic/apps, found nothing, and showed its "missing" placeholder. GTK's own lookup keeps the system dirs, which is why this passed in testing. Ship an index.theme in data/icons/hicolor, and test that it lists the folder the icons live in. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01F7w6vnQked3XNiTdTZDP8r --- data/icons/hicolor/index.theme | 12 ++++++++++++ tests/test_tray.py | 16 ++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 data/icons/hicolor/index.theme diff --git a/data/icons/hicolor/index.theme b/data/icons/hicolor/index.theme new file mode 100644 index 0000000..e255c8a --- /dev/null +++ b/data/icons/hicolor/index.theme @@ -0,0 +1,12 @@ +# Pause hands this folder to the top-bar extension as IconThemePath, and the +# extension searches ONLY here, so it needs its own index to find the icons. +[Icon Theme] +Name=Hicolor +Comment=Pause's top-bar icons +Directories=symbolic/apps + +[symbolic/apps] +Size=16 +MinSize=8 +MaxSize=512 +Type=Scalable diff --git a/tests/test_tray.py b/tests/test_tray.py index a929096..5f2dffb 100644 --- a/tests/test_tray.py +++ b/tests/test_tray.py @@ -1,7 +1,9 @@ +import configparser import unittest from gi.repository import Gio, GLib +from pause.app import ICON_DIR from pause.tray import MENU_PATH, ITEM_PATH, WATCHER, MenuItem, Tray, separator WATCHER_XML = Gio.DBusNodeInfo.new_for_xml(f""" @@ -124,5 +126,19 @@ class TrayTest(unittest.TestCase): self.assertEqual(sorted(signals), ["LayoutUpdated", "NewToolTip"]) +class IconDirTest(unittest.TestCase): + def test_icons_findable_from_icon_theme_path_alone(self): + # The AppIndicator extension searches *only* IconThemePath, not the + # system icon dirs, so the theme there needs its own index.theme + # listing every folder an icon lives in. + index = configparser.ConfigParser() + self.assertTrue(index.read(ICON_DIR / "hicolor" / "index.theme")) + listed = index["Icon Theme"]["Directories"].split(",") + for name in ("net.reudy.Pause-symbolic", "net.reudy.Pause-off-symbolic"): + found = list((ICON_DIR / "hicolor").glob(f"*/*/{name}.svg")) + self.assertEqual(len(found), 1, name) + self.assertIn(str(found[0].parent.relative_to(ICON_DIR / "hicolor")), listed) + + if __name__ == "__main__": unittest.main() From 9dcfb0cc5f2b615959d057e14a47ea43e389fe29 Mon Sep 17 00:00:00 2001 From: agent Date: Mon, 26 Oct 2026 14:24:38 +0000 Subject: [PATCH 2/2] Replace the eye icons with a pause sign and a plus The eye read as creepy. The top-bar icon is now pause bars behind a plus, in a ring, struck through while breaks are off; the app-grid icon shows the same picture on the green tile. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01F7w6vnQked3XNiTdTZDP8r --- README.md | 4 ++-- .../apps/net.reudy.Pause-off-symbolic.svg | 16 +++++++++++++--- .../symbolic/apps/net.reudy.Pause-symbolic.svg | 7 +++++-- data/net.reudy.Pause.svg | 8 ++++---- 4 files changed, 24 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index 5446f70..55e8470 100644 --- a/README.md +++ b/README.md @@ -30,8 +30,8 @@ Remove it with `./install.sh --uninstall` (your notes are kept). ### Top-bar icon -Pause puts an eye in the top bar: open while breaks are on, closed while -they're off. Click it for the time to the next break and *Take a Break Now*, +Pause puts a pause sign with a plus in front in the top bar, struck +through while breaks are off. Click it for the time to the next break and *Take a Break Now*, *Turn Off for an Hour*, *Turn Off for 2 Hours*, *Turn Breaks Back On* and *Quit Pause*. diff --git a/data/icons/hicolor/symbolic/apps/net.reudy.Pause-off-symbolic.svg b/data/icons/hicolor/symbolic/apps/net.reudy.Pause-off-symbolic.svg index 2bc4bc7..0b9cd52 100644 --- a/data/icons/hicolor/symbolic/apps/net.reudy.Pause-off-symbolic.svg +++ b/data/icons/hicolor/symbolic/apps/net.reudy.Pause-off-symbolic.svg @@ -1,5 +1,15 @@ - - - + + + + + + + + + + + + + diff --git a/data/icons/hicolor/symbolic/apps/net.reudy.Pause-symbolic.svg b/data/icons/hicolor/symbolic/apps/net.reudy.Pause-symbolic.svg index bfbd565..f02e608 100644 --- a/data/icons/hicolor/symbolic/apps/net.reudy.Pause-symbolic.svg +++ b/data/icons/hicolor/symbolic/apps/net.reudy.Pause-symbolic.svg @@ -1,4 +1,7 @@ - - + + + + + diff --git a/data/net.reudy.Pause.svg b/data/net.reudy.Pause.svg index 9e93343..467eacf 100644 --- a/data/net.reudy.Pause.svg +++ b/data/net.reudy.Pause.svg @@ -6,8 +6,8 @@ - - - - + + + +