{"action":"created","comment":{"url":"https://api.github.com/repos/zealfire/printable/pulls/comments/34117555","id":34117555,"diff_hunk":"@@ -0,0 +1,150 @@\n+<?php\n+\n+/**\n+ * @file\n+ * Contains \\Drupal\\printable\\Form\\FormatConfigurationFormPdf\n+ */\n+\n+namespace Drupal\\printable\\Form;\n+\n+use Drupal\\printable\\PrintableEntityManagerInterface;\n+use Drupal\\Core\\Form\\FormBase;\n+use Drupal\\Core\\Form\\FormStateInterface;\n+use Drupal\\pdf_api\\PdfGeneratorPluginManager;\n+use Symfony\\Component\\DependencyInjection\\ContainerInterface;\n+\n+/**\n+ * Provides shared configuration form for all printable formats.\n+ */\n+class FormatConfigurationFormPdf extends FormBase {\n+\n+  /**\n+   * The printable entity manager.\n+   *\n+   * @var \\Drupal\\printable\\PrintableEntityManagerInterface\n+   */\n+  protected $printableEntityManager;\n+\n+  /**\n+   * Constructs a new form object.\n+   *\n+   * @param \\Drupal\\printable\\PrintableEntityManagerInterface $printable_entity_manager\n+   *   The printable entity manager.\n+   */\n+  public function __construct(PrintableEntityManagerInterface $printable_entity_manager) {\n+    $this->printableEntityManager = $printable_entity_manager;\n+  }\n+\n+  /**\n+   * {@inheritdoc}\n+   */\n+  public static function create(ContainerInterface $container) {\n+    return new static(\n+      $container->get('printable.entity_manager')\n+    );\n+  }\n+\n+  /**\n+   * {@inheritdoc}\n+   */\n+  public function getFormId() {\n+    return 'printable_configuration_pdf';\n+  }\n+\n+  /**\n+   * {@inheritdoc}\n+   */\n+  public function buildForm(array $form, FormStateInterface $form_state, $printable_format = NULL) {\n+    $form['settings'] = array(\n+      '#type' => 'fieldset',\n+      '#title' => $this->t('PDF options'),\n+    );\n+    $form['settings']['print_pdf_pdf_tool'] = array(\n+      '#type' => 'radios',\n+      '#title' => $this->t('PDF generation tool'),\n+      '#options' => array('mPDF' => 'mPDF', 'wkhtmltopdf' => 'wkhtmltopdf', 'TCPDF' => 'TCPDF'),\n+      '#default_value' => (string)$this->config('printable.settings')->get('pdf_tool'),","path":"src/Form/FormatConfigurationFormPdf.php","position":66,"original_position":66,"commit_id":"81b1dacce33aacf1b3951c7f33c34bba816cb2ad","original_commit_id":"7bee5a58de2ad75fcca399291b218028578ba26c","user":{"login":"Sutharsan","id":259953,"avatar_url":"https://avatars.githubusercontent.com/u/259953?v=3","gravatar_id":"","url":"https://api.github.com/users/Sutharsan","html_url":"https://github.com/Sutharsan","followers_url":"https://api.github.com/users/Sutharsan/followers","following_url":"https://api.github.com/users/Sutharsan/following{/other_user}","gists_url":"https://api.github.com/users/Sutharsan/gists{/gist_id}","starred_url":"https://api.github.com/users/Sutharsan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sutharsan/subscriptions","organizations_url":"https://api.github.com/users/Sutharsan/orgs","repos_url":"https://api.github.com/users/Sutharsan/repos","events_url":"https://api.github.com/users/Sutharsan/events{/privacy}","received_events_url":"https://api.github.com/users/Sutharsan/received_events","type":"User","site_admin":false},"body":"Why cast to string? The config schema already defines the type, I expect the config system to take care of providing the right type. If it is an integer, never mind PHP is forgiving.","created_at":"2015-07-08T05:50:44Z","updated_at":"2015-07-08T05:50:44Z","html_url":"https://github.com/zealfire/printable/pull/17#discussion_r34117555","pull_request_url":"https://api.github.com/repos/zealfire/printable/pulls/17","_links":{"self":{"href":"https://api.github.com/repos/zealfire/printable/pulls/comments/34117555"},"html":{"href":"https://github.com/zealfire/printable/pull/17#discussion_r34117555"},"pull_request":{"href":"https://api.github.com/repos/zealfire/printable/pulls/17"}}},"pull_request":{"url":"https://api.github.com/repos/zealfire/printable/pulls/17","id":39344090,"html_url":"https://github.com/zealfire/printable/pull/17","diff_url":"https://github.com/zealfire/printable/pull/17.diff","patch_url":"https://github.com/zealfire/printable/pull/17.patch","issue_url":"https://api.github.com/repos/zealfire/printable/issues/17","number":17,"state":"open","locked":false,"title":"Merge Pdf module","user":{"login":"Sutharsan","id":259953,"avatar_url":"https://avatars.githubusercontent.com/u/259953?v=3","gravatar_id":"","url":"https://api.github.com/users/Sutharsan","html_url":"https://github.com/Sutharsan","followers_url":"https://api.github.com/users/Sutharsan/followers","following_url":"https://api.github.com/users/Sutharsan/following{/other_user}","gists_url":"https://api.github.com/users/Sutharsan/gists{/gist_id}","starred_url":"https://api.github.com/users/Sutharsan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sutharsan/subscriptions","organizations_url":"https://api.github.com/users/Sutharsan/orgs","repos_url":"https://api.github.com/users/Sutharsan/repos","events_url":"https://api.github.com/users/Sutharsan/events{/privacy}","received_events_url":"https://api.github.com/users/Sutharsan/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-07-07T08:03:39Z","updated_at":"2015-07-08T05:50:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/zealfire/printable/pulls/17/commits","review_comments_url":"https://api.github.com/repos/zealfire/printable/pulls/17/comments","review_comment_url":"https://api.github.com/repos/zealfire/printable/pulls/comments{/number}","comments_url":"https://api.github.com/repos/zealfire/printable/issues/17/comments","statuses_url":"https://api.github.com/repos/zealfire/printable/statuses/81b1dacce33aacf1b3951c7f33c34bba816cb2ad","head":{"label":"zealfire:pdf","ref":"pdf","sha":"81b1dacce33aacf1b3951c7f33c34bba816cb2ad","user":{"login":"zealfire","id":5805013,"avatar_url":"https://avatars.githubusercontent.com/u/5805013?v=3","gravatar_id":"","url":"https://api.github.com/users/zealfire","html_url":"https://github.com/zealfire","followers_url":"https://api.github.com/users/zealfire/followers","following_url":"https://api.github.com/users/zealfire/following{/other_user}","gists_url":"https://api.github.com/users/zealfire/gists{/gist_id}","starred_url":"https://api.github.com/users/zealfire/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zealfire/subscriptions","organizations_url":"https://api.github.com/users/zealfire/orgs","repos_url":"https://api.github.com/users/zealfire/repos","events_url":"https://api.github.com/users/zealfire/events{/privacy}","received_events_url":"https://api.github.com/users/zealfire/received_events","type":"User","site_admin":false},"repo":{"id":36915514,"name":"printable","full_name":"zealfire/printable","owner":{"login":"zealfire","id":5805013,"avatar_url":"https://avatars.githubusercontent.com/u/5805013?v=3","gravatar_id":"","url":"https://api.github.com/users/zealfire","html_url":"https://github.com/zealfire","followers_url":"https://api.github.com/users/zealfire/followers","following_url":"https://api.github.com/users/zealfire/following{/other_user}","gists_url":"https://api.github.com/users/zealfire/gists{/gist_id}","starred_url":"https://api.github.com/users/zealfire/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zealfire/subscriptions","organizations_url":"https://api.github.com/users/zealfire/orgs","repos_url":"https://api.github.com/users/zealfire/repos","events_url":"https://api.github.com/users/zealfire/events{/privacy}","received_events_url":"https://api.github.com/users/zealfire/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/zealfire/printable","description":"Porting print module to Drupal 8 as part of GSoC 2015","fork":false,"url":"https://api.github.com/repos/zealfire/printable","forks_url":"https://api.github.com/repos/zealfire/printable/forks","keys_url":"https://api.github.com/repos/zealfire/printable/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zealfire/printable/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zealfire/printable/teams","hooks_url":"https://api.github.com/repos/zealfire/printable/hooks","issue_events_url":"https://api.github.com/repos/zealfire/printable/issues/events{/number}","events_url":"https://api.github.com/repos/zealfire/printable/events","assignees_url":"https://api.github.com/repos/zealfire/printable/assignees{/user}","branches_url":"https://api.github.com/repos/zealfire/printable/branches{/branch}","tags_url":"https://api.github.com/repos/zealfire/printable/tags","blobs_url":"https://api.github.com/repos/zealfire/printable/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zealfire/printable/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zealfire/printable/git/refs{/sha}","trees_url":"https://api.github.com/repos/zealfire/printable/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zealfire/printable/statuses/{sha}","languages_url":"https://api.github.com/repos/zealfire/printable/languages","stargazers_url":"https://api.github.com/repos/zealfire/printable/stargazers","contributors_url":"https://api.github.com/repos/zealfire/printable/contributors","subscribers_url":"https://api.github.com/repos/zealfire/printable/subscribers","subscription_url":"https://api.github.com/repos/zealfire/printable/subscription","commits_url":"https://api.github.com/repos/zealfire/printable/commits{/sha}","git_commits_url":"https://api.github.com/repos/zealfire/printable/git/commits{/sha}","comments_url":"https://api.github.com/repos/zealfire/printable/comments{/number}","issue_comment_url":"https://api.github.com/repos/zealfire/printable/issues/comments{/number}","contents_url":"https://api.github.com/repos/zealfire/printable/contents/{+path}","compare_url":"https://api.github.com/repos/zealfire/printable/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zealfire/printable/merges","archive_url":"https://api.github.com/repos/zealfire/printable/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zealfire/printable/downloads","issues_url":"https://api.github.com/repos/zealfire/printable/issues{/number}","pulls_url":"https://api.github.com/repos/zealfire/printable/pulls{/number}","milestones_url":"https://api.github.com/repos/zealfire/printable/milestones{/number}","notifications_url":"https://api.github.com/repos/zealfire/printable/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zealfire/printable/labels{/name}","releases_url":"https://api.github.com/repos/zealfire/printable/releases{/id}","created_at":"2015-06-05T06:16:58Z","updated_at":"2015-06-05T07:22:49Z","pushed_at":"2015-07-07T20:55:10Z","git_url":"git://github.com/zealfire/printable.git","ssh_url":"git@github.com:zealfire/printable.git","clone_url":"https://github.com/zealfire/printable.git","svn_url":"https://github.com/zealfire/printable","homepage":null,"size":376,"stargazers_count":1,"watchers_count":1,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":1,"default_branch":"master"}},"base":{"label":"zealfire:master","ref":"master","sha":"e80938d01cdb639d0307755b507c8d140fd27c8c","user":{"login":"zealfire","id":5805013,"avatar_url":"https://avatars.githubusercontent.com/u/5805013?v=3","gravatar_id":"","url":"https://api.github.com/users/zealfire","html_url":"https://github.com/zealfire","followers_url":"https://api.github.com/users/zealfire/followers","following_url":"https://api.github.com/users/zealfire/following{/other_user}","gists_url":"https://api.github.com/users/zealfire/gists{/gist_id}","starred_url":"https://api.github.com/users/zealfire/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zealfire/subscriptions","organizations_url":"https://api.github.com/users/zealfire/orgs","repos_url":"https://api.github.com/users/zealfire/repos","events_url":"https://api.github.com/users/zealfire/events{/privacy}","received_events_url":"https://api.github.com/users/zealfire/received_events","type":"User","site_admin":false},"repo":{"id":36915514,"name":"printable","full_name":"zealfire/printable","owner":{"login":"zealfire","id":5805013,"avatar_url":"https://avatars.githubusercontent.com/u/5805013?v=3","gravatar_id":"","url":"https://api.github.com/users/zealfire","html_url":"https://github.com/zealfire","followers_url":"https://api.github.com/users/zealfire/followers","following_url":"https://api.github.com/users/zealfire/following{/other_user}","gists_url":"https://api.github.com/users/zealfire/gists{/gist_id}","starred_url":"https://api.github.com/users/zealfire/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zealfire/subscriptions","organizations_url":"https://api.github.com/users/zealfire/orgs","repos_url":"https://api.github.com/users/zealfire/repos","events_url":"https://api.github.com/users/zealfire/events{/privacy}","received_events_url":"https://api.github.com/users/zealfire/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/zealfire/printable","description":"Porting print module to Drupal 8 as part of GSoC 2015","fork":false,"url":"https://api.github.com/repos/zealfire/printable","forks_url":"https://api.github.com/repos/zealfire/printable/forks","keys_url":"https://api.github.com/repos/zealfire/printable/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zealfire/printable/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zealfire/printable/teams","hooks_url":"https://api.github.com/repos/zealfire/printable/hooks","issue_events_url":"https://api.github.com/repos/zealfire/printable/issues/events{/number}","events_url":"https://api.github.com/repos/zealfire/printable/events","assignees_url":"https://api.github.com/repos/zealfire/printable/assignees{/user}","branches_url":"https://api.github.com/repos/zealfire/printable/branches{/branch}","tags_url":"https://api.github.com/repos/zealfire/printable/tags","blobs_url":"https://api.github.com/repos/zealfire/printable/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zealfire/printable/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zealfire/printable/git/refs{/sha}","trees_url":"https://api.github.com/repos/zealfire/printable/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zealfire/printable/statuses/{sha}","languages_url":"https://api.github.com/repos/zealfire/printable/languages","stargazers_url":"https://api.github.com/repos/zealfire/printable/stargazers","contributors_url":"https://api.github.com/repos/zealfire/printable/contributors","subscribers_url":"https://api.github.com/repos/zealfire/printable/subscribers","subscription_url":"https://api.github.com/repos/zealfire/printable/subscription","commits_url":"https://api.github.com/repos/zealfire/printable/commits{/sha}","git_commits_url":"https://api.github.com/repos/zealfire/printable/git/commits{/sha}","comments_url":"https://api.github.com/repos/zealfire/printable/comments{/number}","issue_comment_url":"https://api.github.com/repos/zealfire/printable/issues/comments{/number}","contents_url":"https://api.github.com/repos/zealfire/printable/contents/{+path}","compare_url":"https://api.github.com/repos/zealfire/printable/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zealfire/printable/merges","archive_url":"https://api.github.com/repos/zealfire/printable/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zealfire/printable/downloads","issues_url":"https://api.github.com/repos/zealfire/printable/issues{/number}","pulls_url":"https://api.github.com/repos/zealfire/printable/pulls{/number}","milestones_url":"https://api.github.com/repos/zealfire/printable/milestones{/number}","notifications_url":"https://api.github.com/repos/zealfire/printable/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zealfire/printable/labels{/name}","releases_url":"https://api.github.com/repos/zealfire/printable/releases{/id}","created_at":"2015-06-05T06:16:58Z","updated_at":"2015-06-05T07:22:49Z","pushed_at":"2015-07-07T20:55:10Z","git_url":"git://github.com/zealfire/printable.git","ssh_url":"git@github.com:zealfire/printable.git","clone_url":"https://github.com/zealfire/printable.git","svn_url":"https://github.com/zealfire/printable","homepage":null,"size":376,"stargazers_count":1,"watchers_count":1,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/zealfire/printable/pulls/17"},"html":{"href":"https://github.com/zealfire/printable/pull/17"},"issue":{"href":"https://api.github.com/repos/zealfire/printable/issues/17"},"comments":{"href":"https://api.github.com/repos/zealfire/printable/issues/17/comments"},"review_comments":{"href":"https://api.github.com/repos/zealfire/printable/pulls/17/comments"},"review_comment":{"href":"https://api.github.com/repos/zealfire/printable/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/zealfire/printable/pulls/17/commits"},"statuses":{"href":"https://api.github.com/repos/zealfire/printable/statuses/81b1dacce33aacf1b3951c7f33c34bba816cb2ad"}}}}