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 README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<p align="center">
<img src="assets/icons/hicolor/scalable/apps/com.example.QuickView.svg" width="128" height="128" alt="QuickView icon">
<img src="assets/icons/hicolor/scalable/apps/io.github.Green2Grey2.QuickView.svg" width="128" height="128" alt="QuickView icon">
</p>

<h1 align="center">QuickView</h1>
Expand Down
4 changes: 2 additions & 2 deletions adrs/ADR-0009-Caching.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ The implementation went **straight to on-disk**, revising the decision above:
length still misses, and the key is snapshotted *before* tesseract runs so
a file edited mid-OCR stores its stale result under the old key (which the
edited file then correctly misses) rather than the new one. The path is
derived from the lowercased app name, so the pending app-ID rename does not
move it on Linux.
derived from the lowercased app name, so the app-ID rename (done:
io.github.Green2Grey2.QuickView) did not move it on Linux.
- Tesseract is currently invoked with no psm/oem flags, so `lang` is the only
setting and it is in the key. **When OCR settings become configurable
(Phase 7 hardening: psm/oem, tessdata_fast/best), they must join the key.**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Type=Application
Name=QuickView
Comment=Wayland image viewer with OCR text selection
Exec=quickview %f
Icon=com.example.QuickView
Icon=io.github.Green2Grey2.QuickView
Terminal=false
Categories=Graphics;Viewer;
MimeType=image/png;image/jpeg;image/webp;image/gif;image/tiff;image/bmp;image/svg+xml;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<component type="desktop-application">
<id>com.example.QuickView</id>
<id>io.github.Green2Grey2.QuickView</id>
<name>QuickView</name>
<summary>Wayland image viewer with OCR text selection</summary>
<metadata_license>CC0-1.0</metadata_license>
Expand All @@ -16,7 +16,7 @@
<url type="homepage">https://github.com/Green2Grey2/QuickView</url>
<url type="bugtracker">https://github.com/Green2Grey2/QuickView/issues</url>

<launchable type="desktop-id">com.example.QuickView.desktop</launchable>
<launchable type="desktop-id">io.github.Green2Grey2.QuickView.desktop</launchable>

<provides>
<binary>quickview</binary>
Expand Down
7 changes: 5 additions & 2 deletions crates/quickview-core/src/cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,11 @@ use crate::ocr::models::OcrResult;
///
/// On Linux this is typically: `~/.cache/quickview/`.
pub fn cache_dir() -> Option<PathBuf> {
// qualifier, org, app
let proj = ProjectDirs::from("com", "example", "QuickView")?;
// qualifier, org, app — must stay in sync with the application ID
// io.github.Green2Grey2.QuickView. On Linux the path only uses the
// lowercased app name (~/.cache/quickview/), so renaming the ID did not
// move the cache and pre-rename entries remain valid.
let proj = ProjectDirs::from("io.github", "Green2Grey2", "QuickView")?;
Some(proj.cache_dir().to_path_buf())
}

Expand Down
2 changes: 1 addition & 1 deletion crates/quickview-ui/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ struct PreviewHandle {
/// [`ipc::to_argv`] ever reaches GLib, so GLib never sees the real CLI flags.
pub fn run(opts: LaunchOptions) -> Result<i32> {
let app = adw::Application::builder()
.application_id("com.example.QuickView")
.application_id("io.github.Green2Grey2.QuickView")
.flags(gio::ApplicationFlags::HANDLES_COMMAND_LINE)
.build();

Expand Down
7 changes: 5 additions & 2 deletions docs/PHASED_PLAN.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,11 @@ If priorities change, you can reshuffle phases, but try to keep the “render fi
- optional action for quick preview mode ✅ (`QuickPreview` desktop action)
- Compositor keybind recipes (niri, Hyprland, Sway) documented
(`templates/keybind-examples.md` exists but is generic — add per-compositor snippets)
- Rename placeholder app ID `com.example.QuickView` before wider distribution
(touches app ID in `quickview-ui`, `.desktop`, metainfo, icon filename, Flatpak manifest, PKGBUILD)
- Rename placeholder app ID to `io.github.Green2Grey2.QuickView` ✅
(app ID in `quickview-ui`, `.desktop`, metainfo, icon filename, Flatpak
manifest, PKGBUILD, and the `ProjectDirs` qualifier in `cache.rs`; Linux
cache/config paths derive from the lowercased app name, so
`~/.cache/quickview/` did not move and existing OCR cache entries stay valid)
- Quick Preview dismissal completeness (FR-002):
- click outside closes ✅ — layer-shell path: surface anchored to all edges,
transparent backdrop (`gtk::Overlay` sibling of the centered panel) closes
Expand Down
12 changes: 6 additions & 6 deletions packaging/arch/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,14 @@ package() {

install -Dm755 "target/release/quickview" "$pkgdir/usr/bin/quickview"

install -Dm644 "assets/desktop/com.example.QuickView.desktop" \
"$pkgdir/usr/share/applications/com.example.QuickView.desktop"
install -Dm644 "assets/desktop/io.github.Green2Grey2.QuickView.desktop" \
"$pkgdir/usr/share/applications/io.github.Green2Grey2.QuickView.desktop"

install -Dm644 "assets/metainfo/com.example.QuickView.metainfo.xml" \
"$pkgdir/usr/share/metainfo/com.example.QuickView.metainfo.xml"
install -Dm644 "assets/metainfo/io.github.Green2Grey2.QuickView.metainfo.xml" \
"$pkgdir/usr/share/metainfo/io.github.Green2Grey2.QuickView.metainfo.xml"

install -Dm644 "assets/icons/hicolor/scalable/apps/com.example.QuickView.svg" \
"$pkgdir/usr/share/icons/hicolor/scalable/apps/com.example.QuickView.svg"
install -Dm644 "assets/icons/hicolor/scalable/apps/io.github.Green2Grey2.QuickView.svg" \
"$pkgdir/usr/share/icons/hicolor/scalable/apps/io.github.Green2Grey2.QuickView.svg"

install -Dm644 "LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"app-id": "com.example.QuickView",
"app-id": "io.github.Green2Grey2.QuickView",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Use a lowercase owner in the Flatpak app ID

When building or publishing the Flatpak/AppStream metadata, Green2Grey2 is part of the reverse-DNS domain portion (io.github.<owner>), and the Flatpak application-ID conventions say that domain portion must be lowercase (Flatpak docs). Keeping this mixed-case owner makes the renamed ID non-compliant and can block app-center/Flatpak validation; use a lowercase owner such as io.github.green2grey2.QuickView consistently across the manifest, desktop ID, metainfo, icon name, and GApplication ID.

Useful? React with 👍 / 👎.

"runtime": "org.gnome.Platform",
"runtime-version": "49",
"sdk": "org.gnome.Sdk",
Expand Down Expand Up @@ -36,9 +36,9 @@
"build-commands": [
"cargo build --release --locked",
"install -Dm755 target/release/quickview /app/bin/quickview",
"install -Dm644 assets/desktop/com.example.QuickView.desktop /app/share/applications/com.example.QuickView.desktop",
"install -Dm644 assets/metainfo/com.example.QuickView.metainfo.xml /app/share/metainfo/com.example.QuickView.metainfo.xml",
"install -Dm644 assets/icons/hicolor/scalable/apps/com.example.QuickView.svg /app/share/icons/hicolor/scalable/apps/com.example.QuickView.svg",
"install -Dm644 assets/desktop/io.github.Green2Grey2.QuickView.desktop /app/share/applications/io.github.Green2Grey2.QuickView.desktop",
"install -Dm644 assets/metainfo/io.github.Green2Grey2.QuickView.metainfo.xml /app/share/metainfo/io.github.Green2Grey2.QuickView.metainfo.xml",
"install -Dm644 assets/icons/hicolor/scalable/apps/io.github.Green2Grey2.QuickView.svg /app/share/icons/hicolor/scalable/apps/io.github.Green2Grey2.QuickView.svg",
"install -Dm644 LICENSE /app/share/licenses/quickview/LICENSE"
],
"sources": [
Expand Down
4 changes: 2 additions & 2 deletions templates/flatpak-manifest.stub.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"_note": "This is a starter template. The canonical manifest is packaging/flatpak/com.example.QuickView.json.",
"app-id": "com.example.QuickView",
"_note": "This is a starter template. The canonical manifest is packaging/flatpak/io.github.Green2Grey2.QuickView.json.",
"app-id": "io.github.Green2Grey2.QuickView",
"runtime": "org.gnome.Platform",
"runtime-version": "46",
"sdk": "org.gnome.Sdk",
Expand Down
2 changes: 1 addition & 1 deletion templates/quickview.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Type=Application
Name=QuickView
Comment=Wayland image viewer with OCR text selection
Exec=quickview %f
Icon=com.example.QuickView
Icon=io.github.Green2Grey2.QuickView
Terminal=false
Categories=Graphics;Viewer;
MimeType=image/png;image/jpeg;image/webp;image/gif;image/tiff;image/bmp;image/svg+xml;
Expand Down
Loading