-
Notifications
You must be signed in to change notification settings - Fork 726
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
“Enable support for indicators” not working properly, Nextcloud tray icon not visible #6143
Comments
See if this help: |
Hi @lestcape, the issue discussed in the owncloud forums is not the same issue I'm having. It's true that no icon appear if owncloud/nextcloud is started without delay during startup. I had this issue before and added a delay which solved that particular issue. However my current issue is that the button is there in the tray, but icon is not showing. Same thing happens regardless if during startup or if you start the application manually. As you can see in the screenshot it's possible to access the menu even though icon is not showing and the width of the button is very narrow + there are the error messages in the Looking Glas log. |
Ok, but the error message say that the service was not provided... So, this type of things could be related with the start-up time of the service. There are a master service that localized the particular service for an specific indicator. This procedure it's then automatically and then there are not a particular definition of how the service need to be called or where the service it's. The most probably thing then, will be not related with the cinnamon indicators procedure, as the service it's localized in the same way for others indicators in the master service, where all indicators are registered. If the client won't work as others clients, in first place, this need to be a fault of the client itself. This not mean that we can not do anything, but mean that we need to do different things for a particular indicator and of course this is not the best. |
@guzzard you do that: Now we change the lower ‘n’ to an upper ‘N’, otherwise no icon would appear in Ubuntu’s dashboard: sed -i 's/Icon=nextcloud/Icon=Nextcloud/g' src/gui/nextcloud.desktop Source: https://www.c-rieger.de/how-to-install-nextcloud-desktop-client-for-ubuntu/ They apparently have a different names for the icons... In windows this is no a problem, in linux it's. |
See what they do: nextcloud/client_theming@99841e9 You will need to revert this commit, and then install Nextcloud |
Also see this: owncloud/client#5311 |
Also see this: owncloud/client#4693 |
"Cinnamon also freezes for a split second every time it tries to add the icon." They know that (owncloud/client#4990) and they are working on it, please see: Nextcloud use the same code of owncloud. They only modify some things out of the owncloud code. And don't think this is only related with cinnamon: owncloud/client#5074 |
Hi @lestcape, I really appreciate that you spent time looking into this issue. I have looked at the various issues you linked. nextcloud/client_theming@99841e9 seem to be unrelated. The .desktop-file have the correct naming "Nextcloud". owncloud/client#5311 is related to another DE (Budgie Desktop). owncloud/client#4693 setting QT_QPA_PLATFORMTHEME=generic made no difference. The icon is still missing as in my screenshot. owncloud/client#4990 / owncloud/client#5389 (comment) I think this might be some other issue because I don't see any spikes or high usage of the CPU. It's only that Cinnamon visually freezes for lika 0.1 sec or so when the icon is trying to get added. I do think however that the issue is with the ownCloud/Nextcloud since there are messages regarding errors when building the menu. I will make a issue report in Nextcloud as well and link with this report. edit: I tested with OWNCLOUD_MINIMAL_TRAY_MENU=1 set. With that variable set the indicator is only added once, still without the icon visible as in my screenshot, but there are no errors in the Looking Glas log. |
@guzzard What i tray to say, it's that this is apparently an issue in the Nextcloud/owncloud side, not with cinnamon it self. You are wrong when you say: "nextcloud/client_theming@99841e9 seem to be unrelated. The .desktop-file have the correct naming "Nextcloud". This have nothing to be with the desktop file. This have to be with the fact that the indicator code it's in the owncloud side and if you change the icon name in the Nextcloud side and do nothing in the owncloud side, you have them an unmatched icons names... |
@guzzard An also see you report 2 things, a missing icon and "Cinnamon also freezes for a split second every time it tries to add the icon". The freezes have nothing to be with the icons, so of course i reference issues about the freezes, not about the icons... So, they have nothing to be and you can not found the solution to the icons there. For the icons problem, the solution it' s in my previous comment. |
@lestcape I tested in gnome-shell 3.22 with appindicator support enabled to see if the behavior was the same. Problem is that everything works fine. So I'm a bit confused. You say that changes done in the Nextcloud client code have broken the icon and made it stop working (if I understand you correct), but in that case the Nextcloud client should be broken when started in gnome-shell as well? But it's not as you can see in the screenshot. Appindicator icon/menu is working fine. |
@guzzard sorry, I suppose there are a problem then, because need to happen the same with gnome-shell... Just i don't want to install Nextcloud, i don't like it and has a lot of requirements, but i will need to do it now that i'm a little more sure about the problem... |
@guzzard i can not reproduced the problem that you mention, from the Nextcloud master bransh... |
Certainly, if you restart cinnamon you will lost the icon, but this occurs for transmission and more indicators also... You probably don't see the icon in the first image, but it's there... |
@lestcape thanks for spending the time to test nextcloud. I see that the icon is present in all of the screenshots. I tried several different version of nextcloud and owncloud clíent, binary packages and built from source. I get the same result for all of them. Appindicator does not work in Cinnamon, but it works in gnome-shell. I assume it must be due to something in my specific installation/configuration of Cinnamon that is causing the issues since it's working fine for you, and it's working fine for me in gnome-shell on the same computer. I don't know what else I can test at this point. If you have any suggestions please let me know. Thanks! |
I think there are problems in both side, and different versions have different problems... It's no easy at all make it work in this context. They are working on this so will appear more changes. So please, way a little, maybe they can find a way to get it running in a better way for more desktop environments... In my point of view indicators/status icons is probably the most problematic thing in cinnamon right now. @clefebvre also think to fork appindicator, because in fact it's difficult try to fix a thing where you can not modify the code... Probably this will happen and we can have more control of what client want, but also this will not be a complete solution, because the solution will be fix all client and of course this is impossible. But, thats is my opinion. |
some for Telegram and TeamSpeak 3 - tray icons are not visible! |
Nextcloud icon showed up when I first installed it. Now it never shows, but deamon is definitely running. [update] I included a 10sec startup delay, now dropbox icon shows, but not nextcloud =( Linuxmint 18.01, cinnamon 3.2.7, nextcloud 2.3.1, dropbox 26.4.24 |
@lestcape, @guzzard: I don't know if the analysis in nextcloud/client_theming#57 is correct, but if so, nextcloud/client_theming@99841e9 is definitely at fault here |
@Fjodor42 indicator works fine in Gnome Shell etc. If you look at the earlier comments @lestcape also seem to think the icon naming is not the issue after I confirmed that it works fine in Gnome Shell but not in Cinnamon. Anyway, I "solved" the issue by disabling indicator support in Cinnamon and installed the Colapsible Systray applet to get the tray icons to display nicely with correct size etc. |
@guzzard I'm still not sure that the Nextcloud client is really behaving as it should, but the difference you are seeing could stem from Cinnamon not having certain stock icons, as can be seen from the output of
|
Hmmm, I tried client_theming HEAD without and with reverting nextcloud/client_theming@99841e9 - no difference. Seems Cinnamon could be at fault after all... |
Same problem here as @guzzard . This may be a packaging issue, related to files names, albeit not the same as nextcloud/client_theming@99841e9 . From
|
More specifically, it seems that there's no images being installed to |
And a piece of the puzzle that truly makes no sense to me: running Nexcloud with |
Same issue. Nextcloud systray icon works, but indicator does not. |
Cinnamon 3.4.6, Ubuntu 16.04.3 base Interestingly, I have a laptop and a desktop both running the same Ubuntu-Mate 16.04.3 base, with Cinnamon from the same PPA, but the desktop exhibits the problem while the laptop does not! I've tried to identify the source of the problem, but the only common thing I've seen is that running with I;ve had this with Owncloud, Nextcloud, Skype, and most recently radeon-profile all exhibit this behavior... If anyone has anything they'd like me to compare between these two systems, please ask and I will gladly look into it, it would be great to have this solved. |
Hi @clefebvre and @mtwebster, Can one of you have a look at this issue since @lestcape is not working on Cinnamon anymore as I understand? I have done some more digging into this.. The issue is not due to naming issues or paths. Nextcloud/ownCloud packages the icon files into the executable using the Qt resource system. In indicatorManager.js, information such as 'iconName' and 'iconPixmap' among other is fetched through dbus. If the 'iconName' is available this is used to fetch the appropriate icon from /usr/share/icons/ (_createIconByName). If the 'iconName' is empty the 'iconPixmap' is used instead (_createIconFromPixmap ). For Nextcloud/ownCloud the 'iconName' is empty since they use the icons packaged into the executable. The problem occurs on line 1249 when trying to get the bytes representing the icon from the iconPixmap. This is because bytes is empty. The problem can be traced back to line 822 in the _getPropertyCallback function. When trying to get the IconPixmap property from the dbus response with However, using dbus-monitor you can see that the byte arrays are being returned in the response from Nextcloud.
I think the problem lies within the The gnome-shell-extension-appindicator also uses dbus to fetch the icons, and is successfully doing so. I looked briefly at the implementation, but the only thing different that I noticed was that they use an XML schema to define dbus interfaces etc whereas the Cinnamon implementation does it without XML schema. Anyway, hopefully this info can help in some way.. I don't think I can't get any further with the issue unfortunately. |
Ugly workaround until it's been fixed properly in Cinnamon.. In /usr/share/cinnamon/js/ui/indicatorManager.js: // updates the base icon
_updateIcon: function() {
// remove old icon
if (this._mainIcon.get_child()) {
let child = this._mainIcon.get_child();
if (child.inUse)
child.inUse = false;
else if (child.destroy)
child.destroy();
this._mainIcon.set_child(null);
}
// place to save the new icon
let newIcon = null;
// we might need to use the AttentionIcon*, which have precedence over the normal icons
if (this._indicator.status == SNIStatus.NEEDS_ATTENTION) {
let [ name, pixmap, theme ] = this._indicator.attentionIcon;
// workaround due to IconPixmap issue
if(name == ""){
if(Gtk.IconTheme.get_default().has_icon(this._indicator.id.toLowerCase())){
name = this._indicator.id.toLowerCase();
} else if(Gtk.IconTheme.get_default().has_icon(this._indicator.id)){
name = this._indicator.id;
} else {
name = "error";
}
}
// workaround end
if (name && name.length)
newIcon = this._cacheOrCreateIconByName(name, theme, this._iconSize);
if (!newIcon && pixmap)
newIcon = this._createIconFromPixmap(pixmap, this._iconSize);
}
if (!newIcon) {
let [ name, pixmap, theme ] = this._indicator.icon;
// workaround due to IconPixmap issue
if(name == ""){
if(Gtk.IconTheme.get_default().has_icon(this._indicator.id.toLowerCase())){
name = this._indicator.id.toLowerCase();
} else if(Gtk.IconTheme.get_default().has_icon(this._indicator.id)){
name = this._indicator.id;
} else {
name = "error";
}
}
// workaround end
if (name && name.length)
newIcon = this._cacheOrCreateIconByName(name, theme, this._iconSize);
if (!newIcon && pixmap)
newIcon = this._createIconFromPixmap(pixmap, this._iconSize);
}
this._mainIcon.set_child(newIcon);
}, |
Allow me to comment also, that the following workaround fixed all the missing icons on the system tray on Linux mint 18.3 Sylvia. |
Fixed it for me in Debian Stretch with cinnamon* packages in version 3.2.x. |
@guzzard Have you considered offering this patch as a pull request? It did not solve the problem for me with Dropbox and the Jetbrains Toolbox, but with this change I at least get a red no-entry icon instead of simply a blank space. That's a much better error condition handling and I would hope the maintainers would accept it. |
@proximous, my "fix" is just an ugly workaround. However, I have provided quite a lot of details about the problem above, so it should be fairly easy and quick for someone from the Cinnamon team such as @clefebvre, @mtwebster etc to fix it properly.. |
@proximous Try "dbus-launch dropbox stop" and "dbus-launch dropox start" from the command line you 'll see that the icon should now show up (ugly workaround but it works). This hack also worked for viber. |
@nem0nxt I did find that "dbus-launch XXX" fixes both dropbox and Jetbrains Toolbox. Does anyone know why? Does that mean the apps aren't using dbus correctly, or does that mean Cinnamon has some bug with dbus? @guzzard Understood. I'd love to see it fixed, but I stand by my statement that your "ugly workaround" is much better than the existing code, even for cases like mine where it doesn't fix the problem, since at least it fails gracefully. So your "ugly" is "pretty" to me :) |
@guzzard @proximous @nem0nxt @mtwebster @clefebvre Just commenting here that the same issue exists for 'goldendict' (qt5 app): namely that when disabling 'app indicators' the tray icon will show up, but when enabling 'app indicators', the icon won't show (well, it is 1 px wide and I can't get it to respond to a click). running "sudo goldendict" WILL have the app indicator show up in the tray??!!?? ALSO, running "dbus-launch goldendict" WILL have the app indicator show up in the tray??!!?? So for now I am going to edit the goldendict.desktop launcher to add "dbus-launch goldendict" as the exec statement. |
i realize this is kinda stale, but for the record, it is only working with the above patch by @guzzard for me on one machine (cinnamon 3.8.8). On another machine ( Cinnamon 4.0.10-2), it makes no difference, the icon is still invisible. additionally, where it is visible, it does not change with the state of the application.
|
Cinnamon version 3.2.7
With “Enable support for indicators” enabled the Nextcloud sync client icon is not visible in the system tray. However the button is there, and it's possible to open the menu etc.
In the Looking Glass log you can see that Cinnamon tries to add the Nextcloud tray icon over and over. And sometimes you see these DBus error messages. The log continues to be filled with these messages as long as the Nextcloud client is running. Cinnamon also freezes for a split second every time it tries to add the icon.
Above is also true for the ownCloud sync client which is basically the same application as the Nextcloud sync client.
With “Enable support for indicators” disabled the system tray icon works as expected, but is not running as an indicator icon.
The text was updated successfully, but these errors were encountered: