Created attachment 169675 [details] image1 When I double-click on any .ods files inside Desktop or Dolphin, they are opened and grouped under the generic icon. While opening Calc from Kickoff or pinned icons seems to force it to group under the correct Calc icon. See attached image1. Running "qdbus org.kde.KWin /KWin queryWindowInfo" on different windows shows: >>> Calc started from Kickoff or pinned icons activities: ea074252-adac-4b93-ad1a-4ff778d15031 caption: Untitled 6 — LibreOffice Calc clientMachine: desktopFile: libreoffice-calc desktops: 9e4d830a-ef53-4471-8c9c-3ce37ac65b32 fullscreen: false height: 736 keepAbove: false keepBelow: false layer: 2 localhost: true maximizeHorizontal: 2 maximizeVertical: 1 minimized: false noBorder: false resourceClass: libreoffice-calc resourceName: soffice.bin role: shaded: false skipPager: false skipSwitcher: false skipTaskbar: false type: 0 uuid: {5b6fea5f-a475-402a-a7f4-063cd47dcbda} width: 1366 x: 0 y: 0 >>> Calc started from double click inside Desktop of Dolphin activities: ea074252-adac-4b93-ad1a-4ff778d15031 caption: test.ods — LibreOffice Calc clientMachine: desktopFile: libreoffice-startcenter desktops: 9e4d830a-ef53-4471-8c9c-3ce37ac65b32 fullscreen: false height: 736 keepAbove: false keepBelow: false layer: 2 localhost: true maximizeHorizontal: 2 maximizeVertical: 1 minimized: false noBorder: false resourceClass: libreoffice-startcenter resourceName: soffice.bin role: shaded: false skipPager: false skipSwitcher: false skipTaskbar: false type: 0 uuid: {387ea3f8-f213-4ee1-9156-77c3f551d88c} width: 1366 x: 0 y: 0 It seems the double click start Calc with wrong "desktopFile" and "resourceClass" set to "libreoffice-startcenter" instead of "libreoffice-calc".
Cannot reproduce the issue with those steps, FWIW. KDE software is from git master, and LO is: Version: 24.2.3.2 (X86_64) Build ID: 420(Build:2) CPU threads: 8; OS: Linux 6.8; UI render: default; VCL: kf6 (cairo+wayland) Locale: en-US (en_US.UTF-8); UI: en-US Calc: threaded
I'm also not able to reproduce this on 6.1.4 or git-master Version: 24.2.5.2 (X86_64) / LibreOffice Community Build ID: 420(Build:2) CPU threads: 16; OS: Linux 6.9; UI render: default; VCL: kf6 (cairo+wayland) Locale: en-US (en_US.UTF-8); UI: en-US Calc: threaded If this is still an issue on your system can you copy the information from About this System into this issue?
(In reply to TraceyC from comment #2) > I'm also not able to reproduce this on 6.1.4 or git-master > > Version: 24.2.5.2 (X86_64) / LibreOffice Community > Build ID: 420(Build:2) > CPU threads: 16; OS: Linux 6.9; UI render: default; VCL: kf6 (cairo+wayland) > Locale: en-US (en_US.UTF-8); UI: en-US > Calc: threaded > > If this is still an issue on your system can you copy the information from > About this System into this issue? It's still happening with: Version: 24.2.5.2 (X86_64) / LibreOffice Community Build ID: 420(Build:2) CPU threads: 2; OS: Linux 6.10; UI render: default; VCL: kf6 (cairo+wayland) Locale: en-US (en_US.UTF-8); UI: en-US 24.2.5-2 Calc: threaded Operating System: Manjaro Linux KDE Plasma Version: 6.1.4 KDE Frameworks Version: 6.5.0 Qt Version: 6.7.2 Kernel Version: 6.10.6-1-MANJARO (64-bit) Graphics Platform: Wayland
Can you maybe attach a screen recording that shows it happening?
Created attachment 172830 [details] Calc instances opened and grouped under LO generic icon
Thanks. It looks like the way your launcher icon on the desktop launches LibreOffice Calc differs from how its standard launcher launches it. How did you create that launcher, and does it have any customizations, changed environment variables, etc? I ask because if I create a launcher for Calc by dragging it to the desktop from Kickoff and choose "Copy" or "Link", then opening it from that desktop launcher works as expected. Can you try creating a new one in this way and seeing if that works? If it does, then you should diff the working and broken desktop files to see what the differences are.
(In reply to Nate Graham from comment #6) > Thanks. It looks like the way your launcher icon on the desktop launches > LibreOffice Calc differs from how its standard launcher launches it. > > How did you create that launcher, and does it have any customizations, > changed environment variables, etc? > > I ask because if I create a launcher for Calc by dragging it to the desktop > from Kickoff and choose "Copy" or "Link", then opening it from that desktop > launcher works as expected. > > Can you try creating a new one in this way and seeing if that works? If it > does, then you should diff the working and broken desktop files to see what > the differences are. Sorry, I think I poorly reported the problem. Those are not application launchers, but just empty files I added on my desktop. After some testing, it seems this problem only happens with empty ods files created with desktop contextual menu. Steps to reproduce: 1. Right click on desktop, Create New> LibreOffice Calc, Name it and click on OK. 2. Double click on that newly created file That file will be opened under a generic icon instead of LibreOffice Calc one. This only happened with an empty Calc files created that way, it doesn't happen with Writer, Impress, Draw, Math... and it doesn't happen if you add something inside that ods file then save it to desktop.
Can confirm this on plasmashell from git master. Open Libreoffice Calc from Kickoff and it launches with the correct icon. Open the empty .ods file from the desktop and it will open in an existing Calc window. Open the empty .ods file from the desktop with no windows open and it shows the generic black(dark grey) LO icon.
Can someone attach an affected empty calc spreadsheet file?
Created attachment 173245 [details] it's compressed because the site doesn't allow empty files That contextual menu in desktop simply creates an empty textual file (0B) and adds ".ods", ".odt"... extension to it. While if you open LibreOffice Calc/Writer/Impress... and create a new empty file then save it to desktop, if you inspect that file with Okteta you will find some identification data stored inside it.
Got it. So here's the problem: > $ file --mime-type ~/Desktop/foo.ods > /home/nate/Desktop/foo.ods: inode/x-empty Despite the fact that LibreOffice happily opens the file due to the recognized filename extension, it isn't actually recognized as a valid file type by `file`, which means it's not in the MIME database. Which means it must trigger a different codepath in LibreOffice. Thus, the issue is with the templates; evidently they aren't actually valid files. Now the question is where do these templates come from? I actually don't have them on my Fedora 40 system. These don't come from KDE, do they?
(In reply to Nate Graham from comment #11) > Got it. So here's the problem: > > > $ file --mime-type ~/Desktop/foo.ods > > /home/nate/Desktop/foo.ods: inode/x-empty > > Despite the fact that LibreOffice happily opens the file due to the > recognized filename extension, it isn't actually recognized as a valid file > type by `file`, which means it's not in the MIME database. Which means it > must trigger a different codepath in LibreOffice. > > Thus, the issue is with the templates; evidently they aren't actually valid > files. Now the question is where do these templates come from? I actually > don't have them on my Fedora 40 system. These don't come from KDE, do they? The template of Calc uses : /usr/share/templates/soffice.ods.desktop /usr/share/templates/.source/soffice.ods Theses two files come from libreoffice-fresh package (Arch/Manjaro), and if soffice.ods is a 0B file it should be opened and processed based on its extension. https://bugs.documentfoundation.org/show_bug.cgi?id=123476 https://bugs.documentfoundation.org/show_bug.cgi?id=139962 https://bugs.documentfoundation.org/show_bug.cgi?id=139991
Since the template files some from LibreOffice too, then this is clearly a set of LibreOffice bugs. I see at least two: 1. The template files are broken and aren't identified by shared-mime-date as valid file types ( per the output of `file --mime-type` 2. Despite this, LibreOffice happily opens them anyway, but goes down a different codepath when doing so that ends up showing the wrong icon. I'd say it's time to report it as a new bug at https://bugs.documentfoundation.org/. Based on the older ones you found, it looks like this has repeatedly been a problem in the past, and keeps breaking.
https://bugs.documentfoundation.org/show_bug.cgi?id=162770
Thank you!