{"id":13434588,"url":"https://github.com/bilelmoussaoui/Hardcode-Tray","last_synced_at":"2025-03-17T19:30:58.740Z","repository":{"id":30074161,"uuid":"33623675","full_name":"bilelmoussaoui/Hardcode-Tray","owner":"bilelmoussaoui","description":"Fixes Hardcoded tray icons in Linux","archived":false,"fork":false,"pushed_at":"2024-01-01T20:15:33.000Z","size":8094,"stargazers_count":856,"open_issues_count":66,"forks_count":61,"subscribers_count":26,"default_branch":"master","last_synced_at":"2024-05-22T05:04:40.125Z","etag":null,"topics":["linux","python","theme","tray-icons"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bilelmoussaoui.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.BSD-3-Clause","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2015-04-08T18:10:04.000Z","updated_at":"2024-05-17T16:43:14.000Z","dependencies_parsed_at":"2024-01-07T01:18:18.920Z","dependency_job_id":"0d00a2cd-7c93-4b6b-940b-3a2735528753","html_url":"https://github.com/bilelmoussaoui/Hardcode-Tray","commit_stats":null,"previous_names":[],"tags_count":28,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bilelmoussaoui%2FHardcode-Tray","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bilelmoussaoui%2FHardcode-Tray/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bilelmoussaoui%2FHardcode-Tray/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bilelmoussaoui%2FHardcode-Tray/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bilelmoussaoui","download_url":"https://codeload.github.com/bilelmoussaoui/Hardcode-Tray/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221699019,"owners_count":16865967,"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":["linux","python","theme","tray-icons"],"created_at":"2024-07-31T03:00:18.269Z","updated_at":"2024-10-27T15:31:26.067Z","avatar_url":"https://github.com/bilelmoussaoui.png","language":"Python","readme":"# Hardcode-Tray\n[![CircleCI](https://circleci.com/gh/bilelmoussaoui/Hardcode-Tray/tree/master.svg?style=shield)](https://circleci.com/gh/bilelmoussaoui/Hardcode-Tray/tree/master)\n[![Codacy Badge](https://api.codacy.com/project/badge/Grade/4d5c0768b874407bb1dcc2f928899ba5)](https://www.codacy.com/app/bil-elmoussaoui/Hardcode-Tray?utm_source=github.com\u0026amp;utm_medium=referral\u0026amp;utm_content=bil-elmoussaoui/Hardcode-Tray\u0026amp;utm_campaign=Badge_Grade)\n[![Gitter](https://img.shields.io/gitter/room/nwjs/nw.js.svg)](https://gitter.im/Hardcode-Tray/Lobby?utm_source=share-link\u0026utm_medium=link\u0026utm_campaign=share-link)\n[![Hardcode-Tray\nrelease](https://img.shields.io/badge/release-v4.3-blue.svg)](https://github.com/bilelmoussaoui/Hardcode-Tray/releases)\n[![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.me/BilalELMoussaoui)\n\nFixes Hardcoded tray icons in Linux\n\nThe script will automatically detect your default theme, the correct icon size, the hard-coded applications, the correct icons for each indicator and fix them. All that with the possibility to revert to the original icons.\n\n## Themes\n\nHere's a list of themes that supports Hardcode-Tray:\n\n- [Numix icon theme](https://github.com/numixproject/numix-icon-theme)\n\n \u003cdiv align=\"center\"\u003e\u003cimg src=\"screenshots/numix.png\" alt=\"Preview\" /\u003e\u003c/div\u003e\n\n- [Papirus icon theme](https://github.com/PapirusDevelopmentTeam/papirus-icon-theme)\n\n \u003cdiv align=\"center\"\u003e\u003cimg src=\"screenshots/papirus.png\" alt=\"Preview\" /\u003e\u003c/div\u003e\n\n## Requirements\n\n### Running dependencies\n\n- `python3`\n- `python3-gi`\n- Pick up your favorite conversion tool\n  - `python3-cairosvg`\n  - `librsvg`\n  - `inkscape`\n  - `imagemagick`\n  - `svgexport`\n\nIf the icons looks blury, you should try installing this package `libappindicator3-1`. See [#567](https://github.com/bilelmoussaoui/Hardcode-Tray/issues/567) for reference.\n\n### Building dependencies\n\n- `ninja`\n- `meson (\u003e= 0.40)`\n\n## Install\n\n### Arch Linux (AUR)\n\nMake sure the `base-devel` group is installed:\n\n```bash\nsudo pacman -S base-devel\n```\n\nStable version:\n\n```bash\nyaourt -S hardcode-tray\n```\n\nDevelopment version:\n\n```bash\nyaourt -S hardcode-tray-git\n```\n\n### Ubuntu 16.04+ (PPA)\n\n```bash\nsudo add-apt-repository ppa:papirus/hardcode-tray\nsudo apt update\nsudo apt install hardcode-tray\n```\n\n### Debian 10+\n\n```bash\nsudo sh -c \"echo 'deb http://download.opensuse.org/repositories/home:/SmartFinn:/hardcode-tray/Debian_$(lsb_release -rs)/ /' \u003e /etc/apt/sources.list.d/hardcode-tray.list\"\nwget -qO- https://download.opensuse.org/repositories/home:SmartFinn:hardcode-tray/Debian_$(lsb_release -rs)/Release.key | sudo apt-key add -\nsudo apt-get update\nsudo apt-get install hardcode-tray\n```\n\n### Fedora 30+ / Fedora Rawhide\n\n```bash\nsudo dnf config-manager --add-repo https://download.opensuse.org/repositories/home:SmartFinn:hardcode-tray/Fedora_$(rpm -E %fedora)/home:SmartFinn:hardcode-tray.repo\nsudo dnf install hardcode-tray\n```\n\nYou can see all available packages [here](https://software.opensuse.org/download.html?project=home%3ASmartFinn%3Ahardcode-tray\u0026package=hardcode-tray).\n\n### Manual installation\n\n1- Install dependencies\n\n#### On Ubuntu:\n```bash\nsudo apt install git build-essential meson libgirepository1.0-dev libgtk-3-dev python3 python3-gi gir1.2-rsvg-2.0 librsvg2-bin gir1.2-gtk-3.0\n```\n\n2- Compile\n\n```bash\ngit clone https://github.com/bil-elmoussaoui/Hardcode-Tray\ncd Hardcode-Tray\nmeson builddir --prefix=/usr\nsudo ninja -C builddir install\n```\n\n3- Open Hardcode-Tray using this command\n\n```bash\nsudo -E hardcode-tray\n```\n\n4- Enjoy!\n\n## Options\n\n- `--apply` and `--revert`\n\nHardcode-Tray shows a welcome message by default and asks the user to choose between applying the fix or reverting it. You can hide that using\n\n```bash\nhardcode-tray --apply\n```\n\nor\n\n```bash\nhardcode-tray --revert\n```\n\n- `--change-color`\n\nYour favorite theme does not provide icons for all those hardcoded icons? Just use a different theme and change the colors using Hardcode-Tray.\n\n```bash\nhardcode-tray --change-color \"#FIRSTCOLOR #REPLACE_FIRST_COLOR\" \"#SECONDCOLOR #REPLACE_SECOND_COLOR\"...\n```\n\n- `--clear-cache`\n\nLet you clear the backup cache folder\n\n```bash\nhardcode-tray --clear-cache\n```\n\n- `--conversion-tool`\n\nHardcode-Tray by default detects if the user has either Inkscape, CairoSVG, RSVGConvert, ImageMagick or SVGExport installed and use one of them to convert SVG icons to PNG. In order to choose the tool to use if one of them is broken in your installation is\n\n```bash\nhardcode-tray --conversion-tool {Inkscape, CairoSVG, RSVGConvert, ImageMagick, SVGExport}\n```\n\nFor now, we support : CairoSVG (python3-cairosvg), Inkscape, rsvgconvert (librsvg), Imagemagick and svgexport(npm library)\n\nCairo has some issues with converting SVG files that use CSS (see [#245](https://github.com/bil-elmoussaoui/Hardcode-Tray/issues/245)).\n\n- `--light-theme` and `--dark-theme`\n\nSome applications provide dark and light tray icons with the possibility to modify them using their UI. In order to use a dark theme for dark icons and a light one for light icons, you can use those two arguments. It only works if you use both of them at the same time.\n\n```bash\nhardcode-tray --dark-theme Numix-light --light-theme Numix\n```\n\n- `--only`\n\nYou can use the `--only` argument to fix/revert only one application; don't use the argument if you want to fix all applications your icon theme supports.\n\n```bash\nhardcode-tray --only android-messages-desktop.electron, skypeforlinux\n```\n\nIn order to get the names needed to fix only specific programs, you can look at the `app_name` key in the JSON files for the program. There you can find the corresponding name for the program you want to fix.\n\n- `--path`\n\nIf you installed your app in a non-standard location, you can override the path where the icons are stored using the `--path` argument. Only works in combination with the `--only` argument for a single application.\n\n```bash\nhardcode-tray --only dropbox --path /opt/dropbox-bin\n```\n\n- `--size`\n\nYou can also use `--size {24,22,16}` to force the script to use a different icon size or if the script does not detect your desktop environment.\n\n```bash\nhardcode-tray --size 24 --only dropbox\n```\n\n- `--theme`\n\nYou can fix your hardcoded icons using a different theme than the default one.\n\n```bash\nhardcode-tray --theme Numix --only dropbox\n```\n\n- `--version`\n\nYou can print the version of Hardcode-Tray using\n\n```bash\nhardcode-tray --version\n```\n\n## Config file\n\nHardcode-Tray also supports a JSON config file that can be placed under `~/.config`. The file must be named `hardcode-tray.json`. An example of the config file can be found [here](https://github.com/bil-elmoussaoui/Hardcode-Tray/blob/master/data/config.json).\nThe file supports the following options for now.\n\n- `blacklist`: a list of applications that you don't want to be fixed.\n- `conversion_tool`: the default tool to be used every time you use the script.\n- `icons` : An object, that contains `theme` and `size` for the Gtk icon theme and the icon size to be used.\n- `backup_ignore` : A boolean, to configure either you want default icons to be saved on the backup folder or not.\n- `scaling_factor` : Widgets scaling factor. Auto detected on GNOME, KDE and Cinnamon.\n\nPassing `--theme` `--conversion-tool` `--size` will overwrite those settings.\n\n### Node-WebKit JS applications\n\nIn order to fix those ugly tray icons on NWJS applications, you will need to download the SDK from [here](https://nwjs.io/downloads/). Extract the zip file in your home directory (or place it wherever you want) and add a new key to the config file that points to the NwJS SDK directory.\n\n\n\n## Credits\n\n- Modified version of `data_pack.py`, by The Chromium Authors released under a BSD-style license\n- Qt applications icons name by [elementaryPlus](https://github.com/mank319/elementaryPlus) team\n\n## Hardcode-Tray wiki\n\n- [Changelog](https://github.com/bil-elmoussaoui/Hardcode-Tray/wiki/Changelog)\n- [FAQ](https://github.com/bil-elmoussaoui/Hardcode-Tray/wiki/FAQ)\n- [How to contribute](https://github.com/bil-elmoussaoui/Hardcode-Tray/wiki/How-to-contribute)\n- [Supported applications](https://github.com/bil-elmoussaoui/Hardcode-Tray/wiki/Supported-applications)\n","funding_links":["https://www.paypal.me/BilalELMoussaoui"],"categories":["Utility","Python","Desktop Customization","Applications","应用"],"sub_categories":["Windows Manager","VoIP","Desktop Customization","桌面个性化"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbilelmoussaoui%2FHardcode-Tray","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbilelmoussaoui%2FHardcode-Tray","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbilelmoussaoui%2FHardcode-Tray/lists"}