{"action":"created","issue":{"url":"https://api.github.com/repos/Sytten/Facebook-Messenger-Desktop/issues/8","labels_url":"https://api.github.com/repos/Sytten/Facebook-Messenger-Desktop/issues/8/labels{/name}","comments_url":"https://api.github.com/repos/Sytten/Facebook-Messenger-Desktop/issues/8/comments","events_url":"https://api.github.com/repos/Sytten/Facebook-Messenger-Desktop/issues/8/events","html_url":"https://github.com/Sytten/Facebook-Messenger-Desktop/pull/8","id":124770934,"number":8,"title":"[NOT tested] icon_tray: png to ico","user":{"login":"cassiodoroVicinetti","id":1621526,"avatar_url":"https://avatars.githubusercontent.com/u/1621526?v=3","gravatar_id":"","url":"https://api.github.com/users/cassiodoroVicinetti","html_url":"https://github.com/cassiodoroVicinetti","followers_url":"https://api.github.com/users/cassiodoroVicinetti/followers","following_url":"https://api.github.com/users/cassiodoroVicinetti/following{/other_user}","gists_url":"https://api.github.com/users/cassiodoroVicinetti/gists{/gist_id}","starred_url":"https://api.github.com/users/cassiodoroVicinetti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cassiodoroVicinetti/subscriptions","organizations_url":"https://api.github.com/users/cassiodoroVicinetti/orgs","repos_url":"https://api.github.com/users/cassiodoroVicinetti/repos","events_url":"https://api.github.com/users/cassiodoroVicinetti/events{/privacy}","received_events_url":"https://api.github.com/users/cassiodoroVicinetti/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Sytten/Facebook-Messenger-Desktop/labels/Platform%20Support","name":"Platform Support","color":"0052cc"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2016-01-04T14:42:38Z","updated_at":"2016-01-04T20:40:43Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/Sytten/Facebook-Messenger-Desktop/pulls/8","html_url":"https://github.com/Sytten/Facebook-Messenger-Desktop/pull/8","diff_url":"https://github.com/Sytten/Facebook-Messenger-Desktop/pull/8.diff","patch_url":"https://github.com/Sytten/Facebook-Messenger-Desktop/pull/8.patch"},"body":"As I already wrote in https://github.com/Aluxian/Facebook-Messenger-Desktop/issues/296#issuecomment-168070347, in Plasma 5, after installing the [`libappindicator1` package](http://blog.martin-graesslin.com/blog/2014/06/where-are-my-systray-icons/) (Debian/Ubuntu), the tray icon is not shown correctly: in particular, the 64x64 icon is cropped in the middle to a 24x24 square before being shown:\r\n![messengerfordesktop](https://cloud.githubusercontent.com/assets/1621526/12057079/b1083fc4-af3d-11e5-9929-d27a97737f06.png)\r\n\r\nThe crop doesn't change if the application bar height is changed.\r\n\r\nThe icon is currently a .png file, but .ico files should also work (https://github.com/nwjs/nw.js/issues/88#issuecomment-9663089), so I created a .ico file containing a 64x64 icon and a 24x24 icon.\r\n\r\nSadly I was not able to compile the application to test it, so I kindly ask @Sytten to compile it for me and provide me with the .deb so that I can test it."},"comment":{"url":"https://api.github.com/repos/Sytten/Facebook-Messenger-Desktop/issues/comments/168800715","html_url":"https://github.com/Sytten/Facebook-Messenger-Desktop/pull/8#issuecomment-168800715","issue_url":"https://api.github.com/repos/Sytten/Facebook-Messenger-Desktop/issues/8","id":168800715,"user":{"login":"cassiodoroVicinetti","id":1621526,"avatar_url":"https://avatars.githubusercontent.com/u/1621526?v=3","gravatar_id":"","url":"https://api.github.com/users/cassiodoroVicinetti","html_url":"https://github.com/cassiodoroVicinetti","followers_url":"https://api.github.com/users/cassiodoroVicinetti/followers","following_url":"https://api.github.com/users/cassiodoroVicinetti/following{/other_user}","gists_url":"https://api.github.com/users/cassiodoroVicinetti/gists{/gist_id}","starred_url":"https://api.github.com/users/cassiodoroVicinetti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cassiodoroVicinetti/subscriptions","organizations_url":"https://api.github.com/users/cassiodoroVicinetti/orgs","repos_url":"https://api.github.com/users/cassiodoroVicinetti/repos","events_url":"https://api.github.com/users/cassiodoroVicinetti/events{/privacy}","received_events_url":"https://api.github.com/users/cassiodoroVicinetti/received_events","type":"User","site_admin":false},"created_at":"2016-01-04T20:40:43Z","updated_at":"2016-01-04T20:40:43Z","body":"In Plasma 5 the icon does not appear at all and on the console it's written:\r\n> `[6345:0104/213610:WARNING:app_indicator_icon.cc(274)] Could not encode icon`\r\n\r\nI think a different icon should be loaded based on whether Plasma 5 is running.\r\n\r\nBy reading [here](https://techbase.kde.org/KDE_System_Administration/Environment_Variables#Automatically_Set_Variables), I discovered that it is possible to detect Plasma 5 by means of the following environment variables: `KDE_FULL_SESSION` and `KDE_SESSION_VERSION`.\r\n\r\nIn my KDE 4 system:\r\n* `KDE_FULL_SESSION=\"true\"`\r\n* `KDE_SESSION_VERSION=\"4\"`\r\n\r\nIn my Plasma 5 system:\r\n* `KDE_FULL_SESSION=\"true\"`\r\n* `KDE_SESSION_VERSION=\"5\"`\r\n\r\nThe detection should be performed as follows:\r\n1. check whether `KDE_FULL_SESSION` is not empty, in order to see if a KDE session is running;\r\n2. check whether `KDE_SESSION_VERSION` is equal to 5, meaning that Plasma 5 is running;\r\n3. load a 24x24 icon instead of the default 64x64 one.\r\n\r\nWhat do you think?\r\n\r\nIn the meanwhile, it would be great if you provided me with a .deb containing just the 24x24 icon (in .png), just to see if loading a 24x24 icon solves the issue or the icon is still cropped.\r\n\r\nOtherwise, if you want, I could try again to compile by myself the application, but I need your help because yesterday I had several problems (I've never used NodeJS or gulp)."}}