{"action":"created","comment":{"url":"https://api.github.com/repos/awesomeWM/awesome/pulls/comments/100948607","pull_request_review_id":21664852,"id":100948607,"diff_hunk":"@@ -0,0 +1,629 @@\n+---------------------------------------------------------------------------\n+--\n+--\n+--\n+--@DOC_wibox_widget_defaults_grid_EXAMPLE@\n+-- @author getzze\n+-- @copyright 2017 getzze\n+-- @classmod wibox.layout.grid\n+---------------------------------------------------------------------------\n+\n+local setmetatable = setmetatable\n+local unpack = unpack or table.unpack -- luacheck: globals unpack (compatibility with Lua 5.1)\n+local table = table\n+local pairs = pairs\n+local ipairs = ipairs\n+local math = math\n+local util = require(\"awful.util\")\n+local base = require(\"wibox.widget.base\")\n+local beautiful = require(\"beautiful\")\n+\n+\n+local grid = { mt = {} }\n+\n+local properties = {\n+                    \"orientation\", \"superpose\",\n+                    \"forced_num_rows\", \"forced_num_cols\",\n+                    \"min_cols_size\", \"min_rows_size\",\n+                    --\"max_cols_size\", \"max_rows_size\",\n+                   }\n+\n+local dir_properties = { \"spacing\", \"padding\", \"fixed_size\", \"expand\" }\n+\n+\n+\n+--- Reset a grid layout. This removes all widgets from the layout.\n+-- **Signal:** widget::reset\n+-- @param layout The layout you are modifying.\n+-- @name reset\n+-- @class function\n+\n+\n+--- The preferred orientation for the grid.\n+-- @beautiful beautiful.grid_orientation\n+\n+--- If widget superposition is allowed.\n+-- @beautiful beautiful.grid_superpose\n+\n+--- The spacing between cells.\n+-- @beautiful beautiful.grid_[horizontal|vertical]_spacing\n+\n+--- The space between the grid and the surrounding area.\n+-- @beautiful beautiful.grid_[horizontal|vertical]_padding\n+\n+--- Controls if the columns/rows are expanded to use all the available width/height.\n+-- @beautiful beautiful.grid_[horizontal|vertical]_expand\n+\n+--- Controls if the columns/rows have the same size or if the size depend on the content.\n+-- @beautiful beautiful.grid_[horizontal|vertical]_fixed_size","path":"lib/wibox/layout/grid.lua","position":58,"original_position":58,"commit_id":"790641c2b4a14a5075a3630b52fc6b83165cc96d","original_commit_id":"790641c2b4a14a5075a3630b52fc6b83165cc96d","user":{"login":"Elv13","id":340384,"avatar_url":"https://avatars.githubusercontent.com/u/340384?v=3","gravatar_id":"","url":"https://api.github.com/users/Elv13","html_url":"https://github.com/Elv13","followers_url":"https://api.github.com/users/Elv13/followers","following_url":"https://api.github.com/users/Elv13/following{/other_user}","gists_url":"https://api.github.com/users/Elv13/gists{/gist_id}","starred_url":"https://api.github.com/users/Elv13/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Elv13/subscriptions","organizations_url":"https://api.github.com/users/Elv13/orgs","repos_url":"https://api.github.com/users/Elv13/repos","events_url":"https://api.github.com/users/Elv13/events{/privacy}","received_events_url":"https://api.github.com/users/Elv13/received_events","type":"User","site_admin":false},"body":"Also, I don't think all properties should have theme variables. This isn't very useful and may break some extensions that uses the grid but don't expect a theme to change it.","created_at":"2017-02-14T02:27:49Z","updated_at":"2017-02-14T02:38:09Z","html_url":"https://github.com/awesomeWM/awesome/pull/1550#discussion_r100948607","pull_request_url":"https://api.github.com/repos/awesomeWM/awesome/pulls/1550","_links":{"self":{"href":"https://api.github.com/repos/awesomeWM/awesome/pulls/comments/100948607"},"html":{"href":"https://github.com/awesomeWM/awesome/pull/1550#discussion_r100948607"},"pull_request":{"href":"https://api.github.com/repos/awesomeWM/awesome/pulls/1550"}}},"pull_request":{"url":"https://api.github.com/repos/awesomeWM/awesome/pulls/1550","id":105543945,"html_url":"https://github.com/awesomeWM/awesome/pull/1550","diff_url":"https://github.com/awesomeWM/awesome/pull/1550.diff","patch_url":"https://github.com/awesomeWM/awesome/pull/1550.patch","issue_url":"https://api.github.com/repos/awesomeWM/awesome/issues/1550","number":1550,"state":"open","locked":false,"title":"Add wibox grid layout (gtk style)","user":{"login":"getzze","id":6518000,"avatar_url":"https://avatars.githubusercontent.com/u/6518000?v=3","gravatar_id":"","url":"https://api.github.com/users/getzze","html_url":"https://github.com/getzze","followers_url":"https://api.github.com/users/getzze/followers","following_url":"https://api.github.com/users/getzze/following{/other_user}","gists_url":"https://api.github.com/users/getzze/gists{/gist_id}","starred_url":"https://api.github.com/users/getzze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/getzze/subscriptions","organizations_url":"https://api.github.com/users/getzze/orgs","repos_url":"https://api.github.com/users/getzze/repos","events_url":"https://api.github.com/users/getzze/events{/privacy}","received_events_url":"https://api.github.com/users/getzze/received_events","type":"User","site_admin":false},"body":"Using ideas form #1120 and how the grid layout works in qt and gtk.\r\nWidgets can span several columns/rows. They can be added automatically (depending of the `orientation` property: \"y\" from left to right, \"x\" from up to down).\r\nOne can define the `spacing` between columns/rows and the `padding`, which is the gap with the outer limit. There are two options, `expand` so the grid extends to all the available space and `fixed_size` which defines if the columns/rows all have the same size.\r\nI have a test file to test dynamical resizing of the widget with the mouse, but I didn't test dynamical removal/addition of a widget (only static).\r\nI use it for a calendar widget (like blingbling had).","created_at":"2017-02-10T00:32:14Z","updated_at":"2017-02-14T02:38:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"419c3fb7608bd2d8f01936047d1600297bf31f4c","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/awesomeWM/awesome/pulls/1550/commits","review_comments_url":"https://api.github.com/repos/awesomeWM/awesome/pulls/1550/comments","review_comment_url":"https://api.github.com/repos/awesomeWM/awesome/pulls/comments{/number}","comments_url":"https://api.github.com/repos/awesomeWM/awesome/issues/1550/comments","statuses_url":"https://api.github.com/repos/awesomeWM/awesome/statuses/790641c2b4a14a5075a3630b52fc6b83165cc96d","head":{"label":"getzze:grid_layout","ref":"grid_layout","sha":"790641c2b4a14a5075a3630b52fc6b83165cc96d","user":{"login":"getzze","id":6518000,"avatar_url":"https://avatars.githubusercontent.com/u/6518000?v=3","gravatar_id":"","url":"https://api.github.com/users/getzze","html_url":"https://github.com/getzze","followers_url":"https://api.github.com/users/getzze/followers","following_url":"https://api.github.com/users/getzze/following{/other_user}","gists_url":"https://api.github.com/users/getzze/gists{/gist_id}","starred_url":"https://api.github.com/users/getzze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/getzze/subscriptions","organizations_url":"https://api.github.com/users/getzze/orgs","repos_url":"https://api.github.com/users/getzze/repos","events_url":"https://api.github.com/users/getzze/events{/privacy}","received_events_url":"https://api.github.com/users/getzze/received_events","type":"User","site_admin":false},"repo":{"id":80647152,"name":"awesome","full_name":"getzze/awesome","owner":{"login":"getzze","id":6518000,"avatar_url":"https://avatars.githubusercontent.com/u/6518000?v=3","gravatar_id":"","url":"https://api.github.com/users/getzze","html_url":"https://github.com/getzze","followers_url":"https://api.github.com/users/getzze/followers","following_url":"https://api.github.com/users/getzze/following{/other_user}","gists_url":"https://api.github.com/users/getzze/gists{/gist_id}","starred_url":"https://api.github.com/users/getzze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/getzze/subscriptions","organizations_url":"https://api.github.com/users/getzze/orgs","repos_url":"https://api.github.com/users/getzze/repos","events_url":"https://api.github.com/users/getzze/events{/privacy}","received_events_url":"https://api.github.com/users/getzze/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/getzze/awesome","description":"awesome window manager","fork":true,"url":"https://api.github.com/repos/getzze/awesome","forks_url":"https://api.github.com/repos/getzze/awesome/forks","keys_url":"https://api.github.com/repos/getzze/awesome/keys{/key_id}","collaborators_url":"https://api.github.com/repos/getzze/awesome/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/getzze/awesome/teams","hooks_url":"https://api.github.com/repos/getzze/awesome/hooks","issue_events_url":"https://api.github.com/repos/getzze/awesome/issues/events{/number}","events_url":"https://api.github.com/repos/getzze/awesome/events","assignees_url":"https://api.github.com/repos/getzze/awesome/assignees{/user}","branches_url":"https://api.github.com/repos/getzze/awesome/branches{/branch}","tags_url":"https://api.github.com/repos/getzze/awesome/tags","blobs_url":"https://api.github.com/repos/getzze/awesome/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/getzze/awesome/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/getzze/awesome/git/refs{/sha}","trees_url":"https://api.github.com/repos/getzze/awesome/git/trees{/sha}","statuses_url":"https://api.github.com/repos/getzze/awesome/statuses/{sha}","languages_url":"https://api.github.com/repos/getzze/awesome/languages","stargazers_url":"https://api.github.com/repos/getzze/awesome/stargazers","contributors_url":"https://api.github.com/repos/getzze/awesome/contributors","subscribers_url":"https://api.github.com/repos/getzze/awesome/subscribers","subscription_url":"https://api.github.com/repos/getzze/awesome/subscription","commits_url":"https://api.github.com/repos/getzze/awesome/commits{/sha}","git_commits_url":"https://api.github.com/repos/getzze/awesome/git/commits{/sha}","comments_url":"https://api.github.com/repos/getzze/awesome/comments{/number}","issue_comment_url":"https://api.github.com/repos/getzze/awesome/issues/comments{/number}","contents_url":"https://api.github.com/repos/getzze/awesome/contents/{+path}","compare_url":"https://api.github.com/repos/getzze/awesome/compare/{base}...{head}","merges_url":"https://api.github.com/repos/getzze/awesome/merges","archive_url":"https://api.github.com/repos/getzze/awesome/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/getzze/awesome/downloads","issues_url":"https://api.github.com/repos/getzze/awesome/issues{/number}","pulls_url":"https://api.github.com/repos/getzze/awesome/pulls{/number}","milestones_url":"https://api.github.com/repos/getzze/awesome/milestones{/number}","notifications_url":"https://api.github.com/repos/getzze/awesome/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/getzze/awesome/labels{/name}","releases_url":"https://api.github.com/repos/getzze/awesome/releases{/id}","deployments_url":"https://api.github.com/repos/getzze/awesome/deployments","created_at":"2017-02-01T17:54:08Z","updated_at":"2017-02-01T17:54:11Z","pushed_at":"2017-02-12T00:32:21Z","git_url":"git://github.com/getzze/awesome.git","ssh_url":"git@github.com:getzze/awesome.git","clone_url":"https://github.com/getzze/awesome.git","svn_url":"https://github.com/getzze/awesome","homepage":"https://awesomewm.org/","size":12567,"stargazers_count":0,"watchers_count":0,"language":"Lua","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":"awesomeWM:master","ref":"master","sha":"d6412b96fd03fdab651a11e6b0fdd73994807488","user":{"login":"awesomeWM","id":6843364,"avatar_url":"https://avatars.githubusercontent.com/u/6843364?v=3","gravatar_id":"","url":"https://api.github.com/users/awesomeWM","html_url":"https://github.com/awesomeWM","followers_url":"https://api.github.com/users/awesomeWM/followers","following_url":"https://api.github.com/users/awesomeWM/following{/other_user}","gists_url":"https://api.github.com/users/awesomeWM/gists{/gist_id}","starred_url":"https://api.github.com/users/awesomeWM/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/awesomeWM/subscriptions","organizations_url":"https://api.github.com/users/awesomeWM/orgs","repos_url":"https://api.github.com/users/awesomeWM/repos","events_url":"https://api.github.com/users/awesomeWM/events{/privacy}","received_events_url":"https://api.github.com/users/awesomeWM/received_events","type":"Organization","site_admin":false},"repo":{"id":17378009,"name":"awesome","full_name":"awesomeWM/awesome","owner":{"login":"awesomeWM","id":6843364,"avatar_url":"https://avatars.githubusercontent.com/u/6843364?v=3","gravatar_id":"","url":"https://api.github.com/users/awesomeWM","html_url":"https://github.com/awesomeWM","followers_url":"https://api.github.com/users/awesomeWM/followers","following_url":"https://api.github.com/users/awesomeWM/following{/other_user}","gists_url":"https://api.github.com/users/awesomeWM/gists{/gist_id}","starred_url":"https://api.github.com/users/awesomeWM/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/awesomeWM/subscriptions","organizations_url":"https://api.github.com/users/awesomeWM/orgs","repos_url":"https://api.github.com/users/awesomeWM/repos","events_url":"https://api.github.com/users/awesomeWM/events{/privacy}","received_events_url":"https://api.github.com/users/awesomeWM/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/awesomeWM/awesome","description":"awesome window manager","fork":false,"url":"https://api.github.com/repos/awesomeWM/awesome","forks_url":"https://api.github.com/repos/awesomeWM/awesome/forks","keys_url":"https://api.github.com/repos/awesomeWM/awesome/keys{/key_id}","collaborators_url":"https://api.github.com/repos/awesomeWM/awesome/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/awesomeWM/awesome/teams","hooks_url":"https://api.github.com/repos/awesomeWM/awesome/hooks","issue_events_url":"https://api.github.com/repos/awesomeWM/awesome/issues/events{/number}","events_url":"https://api.github.com/repos/awesomeWM/awesome/events","assignees_url":"https://api.github.com/repos/awesomeWM/awesome/assignees{/user}","branches_url":"https://api.github.com/repos/awesomeWM/awesome/branches{/branch}","tags_url":"https://api.github.com/repos/awesomeWM/awesome/tags","blobs_url":"https://api.github.com/repos/awesomeWM/awesome/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/awesomeWM/awesome/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/awesomeWM/awesome/git/refs{/sha}","trees_url":"https://api.github.com/repos/awesomeWM/awesome/git/trees{/sha}","statuses_url":"https://api.github.com/repos/awesomeWM/awesome/statuses/{sha}","languages_url":"https://api.github.com/repos/awesomeWM/awesome/languages","stargazers_url":"https://api.github.com/repos/awesomeWM/awesome/stargazers","contributors_url":"https://api.github.com/repos/awesomeWM/awesome/contributors","subscribers_url":"https://api.github.com/repos/awesomeWM/awesome/subscribers","subscription_url":"https://api.github.com/repos/awesomeWM/awesome/subscription","commits_url":"https://api.github.com/repos/awesomeWM/awesome/commits{/sha}","git_commits_url":"https://api.github.com/repos/awesomeWM/awesome/git/commits{/sha}","comments_url":"https://api.github.com/repos/awesomeWM/awesome/comments{/number}","issue_comment_url":"https://api.github.com/repos/awesomeWM/awesome/issues/comments{/number}","contents_url":"https://api.github.com/repos/awesomeWM/awesome/contents/{+path}","compare_url":"https://api.github.com/repos/awesomeWM/awesome/compare/{base}...{head}","merges_url":"https://api.github.com/repos/awesomeWM/awesome/merges","archive_url":"https://api.github.com/repos/awesomeWM/awesome/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/awesomeWM/awesome/downloads","issues_url":"https://api.github.com/repos/awesomeWM/awesome/issues{/number}","pulls_url":"https://api.github.com/repos/awesomeWM/awesome/pulls{/number}","milestones_url":"https://api.github.com/repos/awesomeWM/awesome/milestones{/number}","notifications_url":"https://api.github.com/repos/awesomeWM/awesome/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/awesomeWM/awesome/labels{/name}","releases_url":"https://api.github.com/repos/awesomeWM/awesome/releases{/id}","deployments_url":"https://api.github.com/repos/awesomeWM/awesome/deployments","created_at":"2014-03-03T19:56:16Z","updated_at":"2017-02-14T00:05:04Z","pushed_at":"2017-02-14T02:00:16Z","git_url":"git://github.com/awesomeWM/awesome.git","ssh_url":"git@github.com:awesomeWM/awesome.git","clone_url":"https://github.com/awesomeWM/awesome.git","svn_url":"https://github.com/awesomeWM/awesome","homepage":"https://awesomewm.org/","size":12654,"stargazers_count":1137,"watchers_count":1137,"language":"Lua","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":172,"mirror_url":null,"open_issues_count":198,"forks":172,"open_issues":198,"watchers":1137,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/awesomeWM/awesome/pulls/1550"},"html":{"href":"https://github.com/awesomeWM/awesome/pull/1550"},"issue":{"href":"https://api.github.com/repos/awesomeWM/awesome/issues/1550"},"comments":{"href":"https://api.github.com/repos/awesomeWM/awesome/issues/1550/comments"},"review_comments":{"href":"https://api.github.com/repos/awesomeWM/awesome/pulls/1550/comments"},"review_comment":{"href":"https://api.github.com/repos/awesomeWM/awesome/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/awesomeWM/awesome/pulls/1550/commits"},"statuses":{"href":"https://api.github.com/repos/awesomeWM/awesome/statuses/790641c2b4a14a5075a3630b52fc6b83165cc96d"}}}}
{"actor":{"display_login":"Elv13"}}