{"action":"created","issue":{"url":"https://api.github.com/repos/sumpfork/dominiontabs/issues/150","repository_url":"https://api.github.com/repos/sumpfork/dominiontabs","labels_url":"https://api.github.com/repos/sumpfork/dominiontabs/issues/150/labels{/name}","comments_url":"https://api.github.com/repos/sumpfork/dominiontabs/issues/150/comments","events_url":"https://api.github.com/repos/sumpfork/dominiontabs/issues/150/events","html_url":"https://github.com/sumpfork/dominiontabs/pull/150","id":210261404,"node_id":"MDExOlB1bGxSZXF1ZXN0MTA3OTc2NjY5","number":150,"title":"Refactor of draw.py","user":{"login":"wvoigt","id":1182468,"node_id":"MDQ6VXNlcjExODI0Njg=","avatar_url":"https://avatars3.githubusercontent.com/u/1182468?v=4","gravatar_id":"","url":"https://api.github.com/users/wvoigt","html_url":"https://github.com/wvoigt","followers_url":"https://api.github.com/users/wvoigt/followers","following_url":"https://api.github.com/users/wvoigt/following{/other_user}","gists_url":"https://api.github.com/users/wvoigt/gists{/gist_id}","starred_url":"https://api.github.com/users/wvoigt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wvoigt/subscriptions","organizations_url":"https://api.github.com/users/wvoigt/orgs","repos_url":"https://api.github.com/users/wvoigt/repos","events_url":"https://api.github.com/users/wvoigt/events{/privacy}","received_events_url":"https://api.github.com/users/wvoigt/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"wvoigt","id":1182468,"node_id":"MDQ6VXNlcjExODI0Njg=","avatar_url":"https://avatars3.githubusercontent.com/u/1182468?v=4","gravatar_id":"","url":"https://api.github.com/users/wvoigt","html_url":"https://github.com/wvoigt","followers_url":"https://api.github.com/users/wvoigt/followers","following_url":"https://api.github.com/users/wvoigt/following{/other_user}","gists_url":"https://api.github.com/users/wvoigt/gists{/gist_id}","starred_url":"https://api.github.com/users/wvoigt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wvoigt/subscriptions","organizations_url":"https://api.github.com/users/wvoigt/orgs","repos_url":"https://api.github.com/users/wvoigt/repos","events_url":"https://api.github.com/users/wvoigt/events{/privacy}","received_events_url":"https://api.github.com/users/wvoigt/received_events","type":"User","site_admin":false},"assignees":[{"login":"wvoigt","id":1182468,"node_id":"MDQ6VXNlcjExODI0Njg=","avatar_url":"https://avatars3.githubusercontent.com/u/1182468?v=4","gravatar_id":"","url":"https://api.github.com/users/wvoigt","html_url":"https://github.com/wvoigt","followers_url":"https://api.github.com/users/wvoigt/followers","following_url":"https://api.github.com/users/wvoigt/following{/other_user}","gists_url":"https://api.github.com/users/wvoigt/gists{/gist_id}","starred_url":"https://api.github.com/users/wvoigt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wvoigt/subscriptions","organizations_url":"https://api.github.com/users/wvoigt/orgs","repos_url":"https://api.github.com/users/wvoigt/repos","events_url":"https://api.github.com/users/wvoigt/events{/privacy}","received_events_url":"https://api.github.com/users/wvoigt/received_events","type":"User","site_admin":false}],"milestone":null,"comments":16,"created_at":"2017-02-25T20:56:16Z","updated_at":"2018-12-19T23:52:36Z","closed_at":null,"author_association":"COLLABORATOR","pull_request":{"url":"https://api.github.com/repos/sumpfork/dominiontabs/pulls/150","html_url":"https://github.com/sumpfork/dominiontabs/pull/150","diff_url":"https://github.com/sumpfork/dominiontabs/pull/150.diff","patch_url":"https://github.com/sumpfork/dominiontabs/pull/150.patch"},"body":"Addresses Issue #70, Issue #85, Issue #120, partial to Issue #6\r\n\r\nI put a lot of work into Issue #6, but in the end while it worked, I was not happy with the layout/optimization code.  So I decided to take a step back and work on an intermediate step.  This not only sets up future optimization work, but more quickly addresses a number of open issues.\r\n\r\n**This is a work in progress and I am posting to allow for others to test, find bugs, give comments.\r\nI would not recommend a real pull until others are comfortable with these changes.**\r\n\r\nThis is a big update to draw.py.  At a high level, it introduces a `CardPlot `object.\r\nThe `CardPlot `object contains everything needed to print a divider somewhere on the page.  That includes the card information, the x,y on the page of the lower left corner of the divider, the rotation, the divider height (important for wrapper/sleeves), the tab location, what type of outline, what text is on the front, what text is on the back, if crop marks are needed (and where), etc..\r\n\r\nThis will make it easier in the future to move dividers around on a page (or even across pages) and to optimize placement so more dividers can fit on a page.  One aspect of moving the card around on a page is the fact that the cropmarks then also need to be tied to the object.  So methods were added to help determine when cropmarks are needed based upon rotation and if the object is near to an edge of the paper.  In addition, the outline routine was updated to include producing cropmarks.\r\n\r\nOther features included with these changes:\r\n\r\nThe `CardPlot `object also allows for flipping a divider from the front to the back of the page. It takes into account tab location, text, etc. `--tab_side` now includes options for left-flip and right-flip. This is used to address Issue #70.\r\n\r\nIn addition to using a line or cropmarks, one can now use dots to show end points of the divider outline.  And dots can be combined with cropmarks to help locate the dots. For those cutting out dividers/wrappers, this will make a cleaner divider without getting partial/full lines on the edges of the divider. `--linetype` was introduced to pick the type of outline (line, dot, cropmarks, dot-cropmarks). `--cropmarkLength` and `--cropmarkSpacing` was added to fine tune the length and spacing of cropmarks.\r\n\r\nThe number of tabs can be fully specified now with `--tab_number`. In the past, it was indirectly limited to either 1 (for left/right/center/full) or 2 for alternating tabs.  To be backwards compatible and to make common selections easier, the `--tab_side` option is still used for the common options.  These common options will override the `--tab_number` option.   This addresses Issue #85.\r\n\r\nFor --tab_number larger than 2, the dividers are evenly spaced from right/left to left/right and the `--tab_side` is used to indicate the starting side (right/left). \r\n\r\nIn addition, if the number of tabs is greater than 2, there are two ways to sweep through the tabs. The default is like an old typewriter.  It goes from start side to end side, then jumps back to the start side and repeats. The `--tab_serpentine` options changes the order to go from start side, to end side, to start side, etc. So the end effect will look like the tabs are snaking back and forth from one side to the other.  `--expansion_reset_tabs` was added to break up the sweep and reset to the starting side at expansion boundaries.\r\n\r\nIf `--expansion_reset_tabs` is set and `--tab_number` is larger than the number of cards in the expansion, then the effective `--tab_number` will be the number of cards in the expansion.  This creates the effect of tabs starting on the side specified by `--tab_side` and ending on the opposite side with the tabs all evenly spaced in between.\r\n\r\nAlso included, is my first attempt at addressing Issue #120. \r\n- `--info` will add a page to the end of the pdf with a formated version of argv. \r\n- `--info_all` includes --info and adds a copy of the --help output.\r\n\r\nOne other change was moving the main code of calculate_layout from main.py to calculatePages in draw.py.  This was done with a eye to the future when draw.py will need to provide that information since optimization information will need to be taken into account.\r\n\r\nHere is a full list of the new or changed options:\r\n\r\n`--tab_side {left, right, left-alternate, right-alternate, left-flip, right-flip, centre, full}`\r\nAlignment of tab (default: right-alternate):\r\n- 'left'/'right'/'centre' sets the starting side of the tabs; \r\n- 'full' will force all label tabs to be full width of the divider; sets --tab_number 1 \r\n- 'left-alternate' will start on the left and then toggle between left and right for the tabs, sets --tab_number 2; \r\n- 'right-alternate' will start on the right and then toggle between right and left for the tabs, sets --tab_number 2; \r\n- 'left-flip' like left-alternate, but the right will be flipped front/back with tab on left, sets --tab_number 2; \r\n- 'right-flip' like right-alternate, but the left will be flipped front/back with tab on right, sets --tab_number 2;\r\n\r\n\r\n`--tab_number TAB_NUMBER`\r\nThe number of tabs. May be overridden by some options of --tab_side. (default: 1)\r\n- When set to 1, all tabs are on the same side (specified by --tab_side). \r\n- When set to 2, tabs will alternate between left and right. (starting side specified by --tab_side). \r\n- When set > 2, the first tab will be on left/right side specified by --tab_side, then the rest of the tabs will be evenly spaced until ending on the opposite side. Then the cycle repeats. \r\n\r\n`--tab_serpentine`   \r\nEffects the order of tabs. (default: False)\r\n- When not selected, tabs will progress from the starting side (left/right) to the opposite side (right/left), and then repeat (e.g., left to right, left to right, etc.). \r\n- When selected, the order is changed to smoothly alternate between the two sides (e.g., left to right, to left, to right, etc.) Only valid if --tab_number > 2. \r\n\r\n`--expansion_reset_tabs`\r\nWhen set, the tabs are restarted (left/right) at the beginning of each expansion. If not set, the tab pattern will continue from one expansion to the next. (default: False)\r\n\r\n`--linetype {line, dot, cropmarks, dot-cropmarks}`\r\nThe divider outline type. (default: line)\r\n- 'line' will print a solid line outlining the divider; \r\n- 'dot' will print a dot at each corner of the divider; \r\n- 'cropmarks' will print cropmarks for the divider; \r\n- 'dot-cropmarks' will combine 'dot' and 'cropmarks' \r\n\r\n`--cropmarkLength CROPMARKLENGTH`\r\nLength of actual drawn cropmark in centimeters. (default: 0.2)\r\n\r\n`--cropmarkSpacing CROPMARKSPACING`\r\nSpacing between card and the start of the cropmark in centimeters. (default: 0.1)\r\n\r\n`--info`                \r\nAdd a page that has all the options used for the file. (default: False)\r\n\r\n`--info_all`\r\nSame as `--info`, but includes pages with all the possible options that can be used. (default: False)"},"comment":{"url":"https://api.github.com/repos/sumpfork/dominiontabs/issues/comments/448794587","html_url":"https://github.com/sumpfork/dominiontabs/pull/150#issuecomment-448794587","issue_url":"https://api.github.com/repos/sumpfork/dominiontabs/issues/150","id":448794587,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0ODc5NDU4Nw==","user":{"login":"sumpfork","id":9730025,"node_id":"MDQ6VXNlcjk3MzAwMjU=","avatar_url":"https://avatars1.githubusercontent.com/u/9730025?v=4","gravatar_id":"","url":"https://api.github.com/users/sumpfork","html_url":"https://github.com/sumpfork","followers_url":"https://api.github.com/users/sumpfork/followers","following_url":"https://api.github.com/users/sumpfork/following{/other_user}","gists_url":"https://api.github.com/users/sumpfork/gists{/gist_id}","starred_url":"https://api.github.com/users/sumpfork/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sumpfork/subscriptions","organizations_url":"https://api.github.com/users/sumpfork/orgs","repos_url":"https://api.github.com/users/sumpfork/repos","events_url":"https://api.github.com/users/sumpfork/events{/privacy}","received_events_url":"https://api.github.com/users/sumpfork/received_events","type":"User","site_admin":false},"created_at":"2018-12-19T23:52:36Z","updated_at":"2018-12-19T23:52:36Z","author_association":"OWNER","body":"> Can we get this deployed again to the staging area. Also, if I want to change the view in the staging area, where do I submit the changes?\r\n\r\nOk, deployed. And you want to change the django views file? I guess submit a pull request in the web repo and let me know to deploy that to staging."}}
{"actor":{"display_login":"sumpfork"}}