NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
16.49k stars 12.98k forks source link

Papirus-icon-theme LibreOffice Calc wrong icon #231862

Open sund3RRR opened 1 year ago

sund3RRR commented 1 year ago

Describe the bug

After installing Papirus-icon-theme i have noticed, that LibreOffice Calc has wrong icon (like calculator app).

Steps To Reproduce

Steps to reproduce the behavior:

  1. Install LibreOffice
  2. Install Papirus-icon-theme

image

hervyqa commented 1 year ago

I think it's not because of the papirus-icon issue, but because of an error in the libreoffice icon. should have used libreoffice-calc, not calc.

Screenshot_20230515_223604

i dual boot with void linux.

void linux /usr/share/applications/libreoffice-writer.desktop:

[Desktop Entry]
Version=1.0
Terminal=false
Icon=libreoffice-calc
Type=Application
...

nixos /var/run/current-system/sw/share/applications/calc.desktop:

[Desktop Entry]
Version=1.0
Terminal=false
Icon=calc
Type=Application
...

i don't know why the .desktop file name doesn't start with libreoffice-.

cc libreoffice maintainer: @7c6f434c

luis-caldas commented 1 year ago

https://github.com/NixOS/nixpkgs/blob/12f5b0f81f3d1b74f09bc179307eb38a0dd8b470/pkgs/applications/office/libreoffice/default.nix#L384

I looked over a couple of icon themes and most of them have their references with the prefix libreoffice-...

7c6f434c commented 1 year ago

Hmm, if I unpack the upstream tarball, it looks like the current upstream Icon= is actually calc?

(Note that I have zero clue about the .desktop entries for Libreoffice as I only ever launch it from command line)

luis-caldas commented 1 year ago

@7c6f434c you're right there, the upstream does indeed use calc for its icon, but the compiled .rpm & .dev all use libreoffice{version}-calc, which could be the ones that the icon themes are basing themselves on

I also had a look at a couple of themes

libreoffice-calc calc
papirus
flat-remix
luv
la-capitaine
numix

None of them related to the program as calc only as libreoffice-calc or libreoffice{version}-calc

7c6f434c commented 12 months ago

So basically the sed expression should be in the other direction now? I am fine merging it trusting the submitter's word that the submitted fix indeed works, of course.

I am even fine if the main expressions stays as it is with a TODO comment to drop the sed during the next bump, and it's just the wrapper that does the necessary magic (quick but annoying churnable things going to the wrapper reduces the debugging pain…)