{"id":26610913,"url":"https://github.com/cuarzosoftware/xdgkit","last_synced_at":"2026-05-02T09:34:42.247Z","repository":{"id":282507565,"uuid":"948822783","full_name":"CuarzoSoftware/XDGKit","owner":"CuarzoSoftware","description":"XDG Utilities for C++","archived":false,"fork":false,"pushed_at":"2025-03-23T01:01:10.000Z","size":277,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-23T01:19:35.174Z","etag":null,"topics":["icons","linux","utilities","xdg"],"latest_commit_sha":null,"homepage":"","language":"CSS","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-2.1","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CuarzoSoftware.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGES","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"CuarzoSoftware"}},"created_at":"2025-03-15T03:16:46.000Z","updated_at":"2025-03-23T00:48:06.000Z","dependencies_parsed_at":null,"dependency_job_id":"a679810c-a351-465b-9bb9-95c342c1dcd0","html_url":"https://github.com/CuarzoSoftware/XDGKit","commit_stats":null,"previous_names":["cuarzosoftware/xdgkit"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CuarzoSoftware%2FXDGKit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CuarzoSoftware%2FXDGKit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CuarzoSoftware%2FXDGKit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CuarzoSoftware%2FXDGKit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CuarzoSoftware","download_url":"https://codeload.github.com/CuarzoSoftware/XDGKit/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245196741,"owners_count":20576081,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["icons","linux","utilities","xdg"],"created_at":"2025-03-24T02:24:10.058Z","updated_at":"2026-05-02T09:34:42.240Z","avatar_url":"https://github.com/CuarzoSoftware.png","language":"CSS","funding_links":["https://github.com/sponsors/CuarzoSoftware"],"categories":[],"sub_categories":[],"readme":"# XDGKit\n\n\u003cp align=\"left\"\u003e\n  \u003ca href=\"https://github.com/CuarzoSoftware/XDGKit/blob/main/LICENSE\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/license-LGPLv2.1-blue.svg\" alt=\"XDGKit is released under the LGPLv2.1 license.\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/CuarzoSoftware/XDGKit\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/version-1.0.0-brightgreen\" alt=\"Current XDGKit version.\" /\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\nXDGKit is a C++ library providing utilities for working with XDG standards.\n\n### Features\n\n- **Icon Themes**: Tools for searching icons, adhering to the [XDG Icon Theme Specification v0.13](https://specifications.freedesktop.org/icon-theme-spec/latest/#overview).\n\n\u003e This library does not load icons into memory. Instead, it provides fast lookups for icon metadata, including paths, extensions, sizes, and other relevant details.\n\n## Links\n\n- [📖 C++ API Documentation](https://cuarzosoftware.github.io/XDGKit/annotated.html)\n- [🕹️ Examples](https://cuarzosoftware.github.io/XDGKit/examples_page.html)\n- [📦 Downloads](https://cuarzosoftware.github.io/XDGKit/downloads_page.html)\n- [⚙️ Environment](https://cuarzosoftware.github.io/XDGKit/environment_page.html)\n- [💬 Contact](https://cuarzosoftware.github.io/XDGKit/contact_page.html)\n\n### Example\n\n```cpp\n#include \u003cCZ/XDG/XDGKit.h\u003e\n#include \u003ciostream\u003e\n\nusing namespace CZ;\n\nint main()\n{\n    XDGKit::Options options;\n\n    // Load themes from cache when possible\n    options.useIconThemesCache = true;\n\n    // Automatically reload themes if a cache update is detected\n    options.autoReloadCache = true;\n\n    // Create an instance of XDGKit.\n    auto kit = XDGKit::Make(options);\n\n    // Search for an icon\n    const XDGIcon *firefox =\n        kit-\u003eiconThemeManager().findIcon(\n            \"firefox\",                                  // Icon to search for\n            512,                                        // Desired icon size (unscaled)\n            2,                                          // Scale factor\n            XDGIcon::PNG | XDGIcon::SVG | XDGIcon::XMP, // File extensions to consider\n            { \"Adwaita\", \"\" }                           // Theme names to search in order, \"\" as wildcard for all themes\n        );\n\n    // Check if the icon was found\n    if (firefox)\n    {\n        std::cout\n            \u003c\u003c \"Theme: \" \u003c\u003c firefox-\u003edirectory().theme().name() \u003c\u003c \"\\n\"\n            \u003c\u003c \"Icon: \" \u003c\u003c firefox-\u003ename() \u003c\u003c \"\\n\"\n            \u003c\u003c \"Size: \" \u003c\u003c firefox-\u003edirectory().size() \u003c\u003c \"\\n\"\n            \u003c\u003c \"Scale: \" \u003c\u003c firefox-\u003edirectory().scale() \u003c\u003c \"\\n\";\n\n        if (firefox-\u003eextensions() \u0026 XDGIcon::PNG)\n            std::cout \u003c\u003c \"PNG Path: \" \u003c\u003c firefox-\u003egetPath(XDGIcon::PNG) \u003c\u003c \"\\n\";\n\n        if (firefox-\u003eextensions() \u0026 XDGIcon::SVG)\n            std::cout \u003c\u003c \"SVG Path: \" \u003c\u003c firefox-\u003egetPath(XDGIcon::SVG) \u003c\u003c \"\\n\";\n\n        if (firefox-\u003eextensions() \u0026 XDGIcon::XMP)\n            std::cout \u003c\u003c \"XMP Path: \" \u003c\u003c firefox-\u003egetPath(XDGIcon::XMP) \u003c\u003c \"\\n\";\n\n        return 0;\n    }\n    else\n    {\n        std::cout \u003c\u003c \"Could not find an icon named 'firefox'.\" \u003c\u003c \"\\n\";\n        return 1;\n    }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcuarzosoftware%2Fxdgkit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcuarzosoftware%2Fxdgkit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcuarzosoftware%2Fxdgkit/lists"}