{"action":"created","comment":{"url":"https://api.github.com/repos/Guake/guake/pulls/comments/29157768","id":29157768,"diff_hunk":"@@ -693,21 +696,27 @@ def set_final_window_rect(self):\n         window_rect = screen.get_monitor_geometry(monitor)\n \n         if os.environ.get('DESKTOP_SESSION') == \"ubuntu\":\n-            unity_hide = self.client.get_int(KEY('/apps/compiz-1/plugins/'\n-                                                 'unityshell/screen0/options/launcher_hide_mode'))\n-            # launcher_hide_mode = 1 => autohide\n-            if unity_hide != 1:\n-                # Size of the icons for Unity in Ubuntu <= 12.04\n-                # TODO Ubuntu 12.10 use dconf :\n-                # /org/compiz/profiles/unity/plugins/unityshell/icon-size\n+\n+            # For Ubuntu 12.10 and above, use dconf :\n+            # For Ubuntu 12.04 and below, use\n+            # see if unity dock is hide => unity_hide\n+            # and the width of unity dock. => unity_dock\n+            if float(platform.dist()[1])>=12.10:\n+                unity_hide = int(subprocess.check_output(\n+                    ['/usr/bin/dconf', 'read',\n+                     '/org/compiz/profiles/unity/plugins/unityshell/launcher-hide-mode']))","path":"src/guake/guake_app.py","position":33,"original_position":33,"commit_id":"cbd8e1e692ce92e764964b769a4f29770edc0dd3","original_commit_id":"cbd8e1e692ce92e764964b769a4f29770edc0dd3","user":{"login":"scinart","id":4526363,"avatar_url":"https://avatars.githubusercontent.com/u/4526363?v=3","gravatar_id":"","url":"https://api.github.com/users/scinart","html_url":"https://github.com/scinart","followers_url":"https://api.github.com/users/scinart/followers","following_url":"https://api.github.com/users/scinart/following{/other_user}","gists_url":"https://api.github.com/users/scinart/gists{/gist_id}","starred_url":"https://api.github.com/users/scinart/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scinart/subscriptions","organizations_url":"https://api.github.com/users/scinart/orgs","repos_url":"https://api.github.com/users/scinart/repos","events_url":"https://api.github.com/users/scinart/events{/privacy}","received_events_url":"https://api.github.com/users/scinart/received_events","type":"User","site_admin":false},"body":"OK, what is the python way to do it then. I'm a python amateur.","created_at":"2015-04-27T15:36:04Z","updated_at":"2015-04-27T15:36:04Z","html_url":"https://github.com/Guake/guake/pull/509#discussion_r29157768","pull_request_url":"https://api.github.com/repos/Guake/guake/pulls/509","_links":{"self":{"href":"https://api.github.com/repos/Guake/guake/pulls/comments/29157768"},"html":{"href":"https://github.com/Guake/guake/pull/509#discussion_r29157768"},"pull_request":{"href":"https://api.github.com/repos/Guake/guake/pulls/509"}}},"pull_request":{"url":"https://api.github.com/repos/Guake/guake/pulls/509","id":34179938,"html_url":"https://github.com/Guake/guake/pull/509","diff_url":"https://github.com/Guake/guake/pull/509.diff","patch_url":"https://github.com/Guake/guake/pull/509.patch","issue_url":"https://api.github.com/repos/Guake/guake/issues/509","number":509,"state":"open","locked":false,"title":"use dconf for ubuntu launcher hide/width detection","user":{"login":"scinart","id":4526363,"avatar_url":"https://avatars.githubusercontent.com/u/4526363?v=3","gravatar_id":"","url":"https://api.github.com/users/scinart","html_url":"https://github.com/scinart","followers_url":"https://api.github.com/users/scinart/followers","following_url":"https://api.github.com/users/scinart/following{/other_user}","gists_url":"https://api.github.com/users/scinart/gists{/gist_id}","starred_url":"https://api.github.com/users/scinart/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scinart/subscriptions","organizations_url":"https://api.github.com/users/scinart/orgs","repos_url":"https://api.github.com/users/scinart/repos","events_url":"https://api.github.com/users/scinart/events{/privacy}","received_events_url":"https://api.github.com/users/scinart/received_events","type":"User","site_admin":false},"body":"The affected code is tested on my Ubunut 15.04 and documented.\r\n\r\ncurrent guake's detection about ubuntu launcher's hide state and icon size is not working.\r\nNow dconf is used to solve this problem. (for ubuntu >=12.10)\r\n\r\nI believe the change is quite straightforward.","created_at":"2015-04-27T15:26:54Z","updated_at":"2015-04-27T15:36:04Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8dd1ecb290f42187f8f59fb19de7d70d77e0c1e0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Guake/guake/pulls/509/commits","review_comments_url":"https://api.github.com/repos/Guake/guake/pulls/509/comments","review_comment_url":"https://api.github.com/repos/Guake/guake/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Guake/guake/issues/509/comments","statuses_url":"https://api.github.com/repos/Guake/guake/statuses/cbd8e1e692ce92e764964b769a4f29770edc0dd3","head":{"label":"scinart:master","ref":"master","sha":"cbd8e1e692ce92e764964b769a4f29770edc0dd3","user":{"login":"scinart","id":4526363,"avatar_url":"https://avatars.githubusercontent.com/u/4526363?v=3","gravatar_id":"","url":"https://api.github.com/users/scinart","html_url":"https://github.com/scinart","followers_url":"https://api.github.com/users/scinart/followers","following_url":"https://api.github.com/users/scinart/following{/other_user}","gists_url":"https://api.github.com/users/scinart/gists{/gist_id}","starred_url":"https://api.github.com/users/scinart/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scinart/subscriptions","organizations_url":"https://api.github.com/users/scinart/orgs","repos_url":"https://api.github.com/users/scinart/repos","events_url":"https://api.github.com/users/scinart/events{/privacy}","received_events_url":"https://api.github.com/users/scinart/received_events","type":"User","site_admin":false},"repo":{"id":34672173,"name":"guake","full_name":"scinart/guake","owner":{"login":"scinart","id":4526363,"avatar_url":"https://avatars.githubusercontent.com/u/4526363?v=3","gravatar_id":"","url":"https://api.github.com/users/scinart","html_url":"https://github.com/scinart","followers_url":"https://api.github.com/users/scinart/followers","following_url":"https://api.github.com/users/scinart/following{/other_user}","gists_url":"https://api.github.com/users/scinart/gists{/gist_id}","starred_url":"https://api.github.com/users/scinart/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scinart/subscriptions","organizations_url":"https://api.github.com/users/scinart/orgs","repos_url":"https://api.github.com/users/scinart/repos","events_url":"https://api.github.com/users/scinart/events{/privacy}","received_events_url":"https://api.github.com/users/scinart/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/scinart/guake","description":"Drop-down terminal for GNOME","fork":true,"url":"https://api.github.com/repos/scinart/guake","forks_url":"https://api.github.com/repos/scinart/guake/forks","keys_url":"https://api.github.com/repos/scinart/guake/keys{/key_id}","collaborators_url":"https://api.github.com/repos/scinart/guake/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/scinart/guake/teams","hooks_url":"https://api.github.com/repos/scinart/guake/hooks","issue_events_url":"https://api.github.com/repos/scinart/guake/issues/events{/number}","events_url":"https://api.github.com/repos/scinart/guake/events","assignees_url":"https://api.github.com/repos/scinart/guake/assignees{/user}","branches_url":"https://api.github.com/repos/scinart/guake/branches{/branch}","tags_url":"https://api.github.com/repos/scinart/guake/tags","blobs_url":"https://api.github.com/repos/scinart/guake/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/scinart/guake/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/scinart/guake/git/refs{/sha}","trees_url":"https://api.github.com/repos/scinart/guake/git/trees{/sha}","statuses_url":"https://api.github.com/repos/scinart/guake/statuses/{sha}","languages_url":"https://api.github.com/repos/scinart/guake/languages","stargazers_url":"https://api.github.com/repos/scinart/guake/stargazers","contributors_url":"https://api.github.com/repos/scinart/guake/contributors","subscribers_url":"https://api.github.com/repos/scinart/guake/subscribers","subscription_url":"https://api.github.com/repos/scinart/guake/subscription","commits_url":"https://api.github.com/repos/scinart/guake/commits{/sha}","git_commits_url":"https://api.github.com/repos/scinart/guake/git/commits{/sha}","comments_url":"https://api.github.com/repos/scinart/guake/comments{/number}","issue_comment_url":"https://api.github.com/repos/scinart/guake/issues/comments{/number}","contents_url":"https://api.github.com/repos/scinart/guake/contents/{+path}","compare_url":"https://api.github.com/repos/scinart/guake/compare/{base}...{head}","merges_url":"https://api.github.com/repos/scinart/guake/merges","archive_url":"https://api.github.com/repos/scinart/guake/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/scinart/guake/downloads","issues_url":"https://api.github.com/repos/scinart/guake/issues{/number}","pulls_url":"https://api.github.com/repos/scinart/guake/pulls{/number}","milestones_url":"https://api.github.com/repos/scinart/guake/milestones{/number}","notifications_url":"https://api.github.com/repos/scinart/guake/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/scinart/guake/labels{/name}","releases_url":"https://api.github.com/repos/scinart/guake/releases{/id}","created_at":"2015-04-27T14:40:41Z","updated_at":"2015-04-27T15:18:30Z","pushed_at":"2015-04-27T15:18:30Z","git_url":"git://github.com/scinart/guake.git","ssh_url":"git@github.com:scinart/guake.git","clone_url":"https://github.com/scinart/guake.git","svn_url":"https://github.com/scinart/guake","homepage":null,"size":3542,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"Guake:master","ref":"master","sha":"5eae4510bec1b2156949b18bcb454f310b04fb2e","user":{"login":"Guake","id":1741188,"avatar_url":"https://avatars.githubusercontent.com/u/1741188?v=3","gravatar_id":"","url":"https://api.github.com/users/Guake","html_url":"https://github.com/Guake","followers_url":"https://api.github.com/users/Guake/followers","following_url":"https://api.github.com/users/Guake/following{/other_user}","gists_url":"https://api.github.com/users/Guake/gists{/gist_id}","starred_url":"https://api.github.com/users/Guake/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Guake/subscriptions","organizations_url":"https://api.github.com/users/Guake/orgs","repos_url":"https://api.github.com/users/Guake/repos","events_url":"https://api.github.com/users/Guake/events{/privacy}","received_events_url":"https://api.github.com/users/Guake/received_events","type":"Organization","site_admin":false},"repo":{"id":4333252,"name":"guake","full_name":"Guake/guake","owner":{"login":"Guake","id":1741188,"avatar_url":"https://avatars.githubusercontent.com/u/1741188?v=3","gravatar_id":"","url":"https://api.github.com/users/Guake","html_url":"https://github.com/Guake","followers_url":"https://api.github.com/users/Guake/followers","following_url":"https://api.github.com/users/Guake/following{/other_user}","gists_url":"https://api.github.com/users/Guake/gists{/gist_id}","starred_url":"https://api.github.com/users/Guake/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Guake/subscriptions","organizations_url":"https://api.github.com/users/Guake/orgs","repos_url":"https://api.github.com/users/Guake/repos","events_url":"https://api.github.com/users/Guake/events{/privacy}","received_events_url":"https://api.github.com/users/Guake/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Guake/guake","description":"Drop-down terminal for GNOME","fork":false,"url":"https://api.github.com/repos/Guake/guake","forks_url":"https://api.github.com/repos/Guake/guake/forks","keys_url":"https://api.github.com/repos/Guake/guake/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Guake/guake/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Guake/guake/teams","hooks_url":"https://api.github.com/repos/Guake/guake/hooks","issue_events_url":"https://api.github.com/repos/Guake/guake/issues/events{/number}","events_url":"https://api.github.com/repos/Guake/guake/events","assignees_url":"https://api.github.com/repos/Guake/guake/assignees{/user}","branches_url":"https://api.github.com/repos/Guake/guake/branches{/branch}","tags_url":"https://api.github.com/repos/Guake/guake/tags","blobs_url":"https://api.github.com/repos/Guake/guake/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Guake/guake/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Guake/guake/git/refs{/sha}","trees_url":"https://api.github.com/repos/Guake/guake/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Guake/guake/statuses/{sha}","languages_url":"https://api.github.com/repos/Guake/guake/languages","stargazers_url":"https://api.github.com/repos/Guake/guake/stargazers","contributors_url":"https://api.github.com/repos/Guake/guake/contributors","subscribers_url":"https://api.github.com/repos/Guake/guake/subscribers","subscription_url":"https://api.github.com/repos/Guake/guake/subscription","commits_url":"https://api.github.com/repos/Guake/guake/commits{/sha}","git_commits_url":"https://api.github.com/repos/Guake/guake/git/commits{/sha}","comments_url":"https://api.github.com/repos/Guake/guake/comments{/number}","issue_comment_url":"https://api.github.com/repos/Guake/guake/issues/comments{/number}","contents_url":"https://api.github.com/repos/Guake/guake/contents/{+path}","compare_url":"https://api.github.com/repos/Guake/guake/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Guake/guake/merges","archive_url":"https://api.github.com/repos/Guake/guake/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Guake/guake/downloads","issues_url":"https://api.github.com/repos/Guake/guake/issues{/number}","pulls_url":"https://api.github.com/repos/Guake/guake/pulls{/number}","milestones_url":"https://api.github.com/repos/Guake/guake/milestones{/number}","notifications_url":"https://api.github.com/repos/Guake/guake/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Guake/guake/labels{/name}","releases_url":"https://api.github.com/repos/Guake/guake/releases{/id}","created_at":"2012-05-15T07:38:08Z","updated_at":"2015-04-27T10:17:51Z","pushed_at":"2015-04-27T15:26:54Z","git_url":"git://github.com/Guake/guake.git","ssh_url":"git@github.com:Guake/guake.git","clone_url":"https://github.com/Guake/guake.git","svn_url":"https://github.com/Guake/guake","homepage":null,"size":3542,"stargazers_count":654,"watchers_count":654,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":229,"mirror_url":null,"open_issues_count":111,"forks":229,"open_issues":111,"watchers":654,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Guake/guake/pulls/509"},"html":{"href":"https://github.com/Guake/guake/pull/509"},"issue":{"href":"https://api.github.com/repos/Guake/guake/issues/509"},"comments":{"href":"https://api.github.com/repos/Guake/guake/issues/509/comments"},"review_comments":{"href":"https://api.github.com/repos/Guake/guake/pulls/509/comments"},"review_comment":{"href":"https://api.github.com/repos/Guake/guake/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Guake/guake/pulls/509/commits"},"statuses":{"href":"https://api.github.com/repos/Guake/guake/statuses/cbd8e1e692ce92e764964b769a4f29770edc0dd3"}}}}