chillerlan-QRCode-Output-QRGdImage.html 62 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>Documentation</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <base href="../">
  8. <link rel="icon" href="images/favicon.ico"/>
  9. <link rel="stylesheet" href="css/normalize.css">
  10. <link rel="stylesheet" href="css/base.css">
  11. <link rel="preconnect" href="https://fonts.gstatic.com">
  12. <link href="https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@400;600;700&display=swap" rel="stylesheet">
  13. <link href="https://fonts.googleapis.com/css2?family=Source+Code+Pro:wght@400;600;700&display=swap" rel="stylesheet">
  14. <link rel="stylesheet" href="css/template.css">
  15. <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.12.0/css/all.min.css" integrity="sha256-ybRkN9dBjhcS2qrW1z+hfCxq+1aBdwyQM5wlQoQVt/0=" crossorigin="anonymous" />
  16. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/themes/prism-okaidia.css">
  17. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.css">
  18. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.css">
  19. <script src="https://cdn.jsdelivr.net/npm/fuse.js@3.4.6"></script>
  20. <script src="https://cdn.jsdelivr.net/npm/css-vars-ponyfill@2"></script>
  21. <script src="js/search.js"></script>
  22. <script defer src="js/searchIndex.js"></script>
  23. </head>
  24. <body id="top">
  25. <header class="phpdocumentor-header phpdocumentor-section">
  26. <h1 class="phpdocumentor-title"><a href="" class="phpdocumentor-title__link">Documentation</a></h1>
  27. <input class="phpdocumentor-header__menu-button" type="checkbox" id="menu-button" name="menu-button" />
  28. <label class="phpdocumentor-header__menu-icon" for="menu-button">
  29. <i class="fas fa-bars"></i>
  30. </label>
  31. <section data-search-form class="phpdocumentor-search">
  32. <label>
  33. <span class="visually-hidden">Search for</span>
  34. <svg class="phpdocumentor-search__icon" width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
  35. <circle cx="7.5" cy="7.5" r="6.5" stroke="currentColor" stroke-width="2"/>
  36. <line x1="12.4892" y1="12.2727" x2="19.1559" y2="18.9393" stroke="currentColor" stroke-width="3"/>
  37. </svg>
  38. <input type="search" class="phpdocumentor-field phpdocumentor-search__field" placeholder="Loading .." disabled />
  39. </label>
  40. </section>
  41. <nav class="phpdocumentor-topnav">
  42. <ul class="phpdocumentor-topnav__menu">
  43. </ul>
  44. </nav>
  45. </header>
  46. <main class="phpdocumentor">
  47. <div class="phpdocumentor-section">
  48. <input class="phpdocumentor-sidebar__menu-button" type="checkbox" id="sidebar-button" name="sidebar-button" />
  49. <label class="phpdocumentor-sidebar__menu-icon" for="sidebar-button">
  50. Menu
  51. </label>
  52. <aside class="phpdocumentor-column -four phpdocumentor-sidebar">
  53. <section class="phpdocumentor-sidebar__category">
  54. <h2 class="phpdocumentor-sidebar__category-header">Namespaces</h2>
  55. <h4 class="phpdocumentor-sidebar__root-namespace">
  56. <a href="namespaces/chillerlan.html" class="">chillerlan</a>
  57. </h4>
  58. <ul class="phpdocumentor-list">
  59. <li>
  60. <a href="namespaces/chillerlan-qrcode.html" class="">QRCode</a>
  61. </li>
  62. <li>
  63. <a href="namespaces/chillerlan-qrcodetest.html" class="">QRCodeTest</a>
  64. </li>
  65. </ul>
  66. </section>
  67. <section class="phpdocumentor-sidebar__category">
  68. <h2 class="phpdocumentor-sidebar__category-header">Packages</h2>
  69. <h4 class="phpdocumentor-sidebar__root-namespace">
  70. <a href="packages/Application.html" class="">Application</a>
  71. </h4>
  72. </section>
  73. <section class="phpdocumentor-sidebar__category">
  74. <h2 class="phpdocumentor-sidebar__category-header">Reports</h2>
  75. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/deprecated.html">Deprecated</a></h3>
  76. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/errors.html">Errors</a></h3>
  77. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/markers.html">Markers</a></h3>
  78. </section>
  79. <section class="phpdocumentor-sidebar__category">
  80. <h2 class="phpdocumentor-sidebar__category-header">Indices</h2>
  81. <h3 class="phpdocumentor-sidebar__root-package"><a href="indices/files.html">Files</a></h3>
  82. </section>
  83. </aside>
  84. <div class="phpdocumentor-column -eight phpdocumentor-content">
  85. <ul class="phpdocumentor-breadcrumbs">
  86. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan.html">chillerlan</a></li>
  87. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan-qrcode.html">QRCode</a></li>
  88. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan-qrcode-output.html">Output</a></li>
  89. </ul>
  90. <article class="phpdocumentor-element -class">
  91. <h2 class="phpdocumentor-content__title">
  92. QRGdImage
  93. <span class="phpdocumentor-element__extends">
  94. extends <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html"><abbr title="\chillerlan\QRCode\Output\QROutputAbstract">QROutputAbstract</abbr></a>
  95. </span>
  96. <div class="phpdocumentor-element__package">
  97. in package
  98. <ul class="phpdocumentor-breadcrumbs">
  99. <li class="phpdocumentor-breadcrumb"><a href="packages/Application.html">Application</a></li>
  100. </ul>
  101. </div>
  102. </h2>
  103. <aside class="phpdocumentor-element-found-in">
  104. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRGdImage.php"><a href="files/src-output-qrgdimage.html"><abbr title="src/Output/QRGdImage.php">QRGdImage.php</abbr></a></abbr>
  105. :
  106. <span class="phpdocumentor-element-found-in__line">29</span>
  107. </aside>
  108. <p class="phpdocumentor-summary">Converts the matrix into GD images, raw or base64 output (requires ext-gd)</p>
  109. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  110. Tags
  111. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  112. </h5>
  113. <dl class="phpdocumentor-tag-list">
  114. <dt class="phpdocumentor-tag-list__entry">
  115. <span class="phpdocumentor-tag__name">see</span>
  116. </dt>
  117. <dd class="phpdocumentor-tag-list__definition">
  118. <span class="phpdocumentor-tag-link"><a href="http://php.net/manual/book.image.php"><abbr title="http://php.net/manual/book.image.php">http://php.net/manual/book.image.php</abbr></a></span>
  119. </dd>
  120. </dl>
  121. <h3 id="toc">
  122. Table of Contents
  123. <a href="#toc" class="headerlink"><i class="fas fa-link"></i></a>
  124. </h3>
  125. <dl class="phpdocumentor-table-of-contents">
  126. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  127. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#property_image">$image</a>
  128. <span>
  129. &nbsp;: resource|<abbr title="\GdImage">GdImage</abbr> </span>
  130. </dt>
  131. <dd>The GD image resource</dd>
  132. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  133. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_length">$length</a>
  134. <span>
  135. &nbsp;: int </span>
  136. </dt>
  137. <dd>the side length of the QR image (modules * scale)</dd>
  138. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  139. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_matrix">$matrix</a>
  140. <span>
  141. &nbsp;: <a href="classes/chillerlan-QRCode-Data-QRMatrix.html"><abbr title="\chillerlan\QRCode\Data\QRMatrix">QRMatrix</abbr></a> </span>
  142. </dt>
  143. <dd>the (filled) data matrix object</dd>
  144. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  145. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_moduleCount">$moduleCount</a>
  146. <span>
  147. &nbsp;: int </span>
  148. </dt>
  149. <dd>the current size of the QR matrix</dd>
  150. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  151. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_moduleValues">$moduleValues</a>
  152. <span>
  153. &nbsp;: array&lt;string|int, mixed&gt; </span>
  154. </dt>
  155. <dd>an (optional) array of color values for the several QR matrix parts</dd>
  156. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  157. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_options">$options</a>
  158. <span>
  159. &nbsp;: <abbr title="\chillerlan\Settings\SettingsContainerInterface">SettingsContainerInterface</abbr> </span>
  160. </dt>
  161. <dd></dd>
  162. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  163. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_scale">$scale</a>
  164. <span>
  165. &nbsp;: int </span>
  166. </dt>
  167. <dd>the current scaling for a QR pixel</dd>
  168. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  169. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method___construct">__construct()</a>
  170. <span>
  171. &nbsp;: mixed </span>
  172. </dt>
  173. <dd>QROutputAbstract constructor.</dd>
  174. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  175. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_dump">dump()</a>
  176. <span>
  177. &nbsp;: string|resource|<abbr title="\GdImage">GdImage</abbr> </span>
  178. </dt>
  179. <dd></dd>
  180. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  181. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_base64encode">base64encode()</a>
  182. <span>
  183. &nbsp;: string </span>
  184. </dt>
  185. <dd>Returns a base64 data URI for the given string and mime type</dd>
  186. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  187. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_collectModules">collectModules()</a>
  188. <span>
  189. &nbsp;: array&lt;string|int, mixed&gt; </span>
  190. </dt>
  191. <dd>collects the modules per QRMatrix::M_* type and runs a $transform functio on each module and
  192. returns an array with the transformed modules</dd>
  193. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  194. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_dumpImage">dumpImage()</a>
  195. <span>
  196. &nbsp;: string </span>
  197. </dt>
  198. <dd>Creates the final image by calling the desired GD output function</dd>
  199. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  200. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_getDefaultModuleValue">getDefaultModuleValue()</a>
  201. <span>
  202. &nbsp;: mixed </span>
  203. </dt>
  204. <dd>Returns a defualt value for either dark or light modules (return value depends on the output module)</dd>
  205. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  206. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_getModuleValue">getModuleValue()</a>
  207. <span>
  208. &nbsp;: mixed </span>
  209. </dt>
  210. <dd>Returns the final value for the given input (return value depends on the output module)</dd>
  211. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  212. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_moduleValueIsValid">moduleValueIsValid()</a>
  213. <span>
  214. &nbsp;: bool </span>
  215. </dt>
  216. <dd>Determines whether the given value is valid</dd>
  217. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  218. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_saveToFile">saveToFile()</a>
  219. <span>
  220. &nbsp;: void </span>
  221. </dt>
  222. <dd>saves the qr data to a file</dd>
  223. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  224. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_setModuleValues">setModuleValues()</a>
  225. <span>
  226. &nbsp;: void </span>
  227. </dt>
  228. <dd>Sets the initial module values</dd>
  229. <dt class="phpdocumentor-table-of-contents__entry -method -protected">
  230. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_setPixel">setPixel()</a>
  231. <span>
  232. &nbsp;: void </span>
  233. </dt>
  234. <dd>Creates a single QR pixel with the given settings</dd>
  235. </dl>
  236. <section class="phpdocumentor-properties">
  237. <h3 class="phpdocumentor-elements__header" id="properties">
  238. Properties
  239. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#properties" class="headerlink"><i class="fas fa-link"></i></a>
  240. </h3>
  241. <article
  242. class="
  243. phpdocumentor-element
  244. -property
  245. -protected
  246. "
  247. >
  248. <h4 class="phpdocumentor-element__name" id="property_image">
  249. $image
  250. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#property_image" class="headerlink"><i class="fas fa-link"></i></a>
  251. <span class="phpdocumentor-element__modifiers">
  252. </span>
  253. </h4>
  254. <aside class="phpdocumentor-element-found-in">
  255. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRGdImage.php"><a href="files/src-output-qrgdimage.html"><abbr title="src/Output/QRGdImage.php">QRGdImage.php</abbr></a></abbr>
  256. :
  257. <span class="phpdocumentor-element-found-in__line">37</span>
  258. </aside>
  259. <p class="phpdocumentor-summary">The GD image resource</p>
  260. <code class="phpdocumentor-code phpdocumentor-signature ">
  261. <span class="phpdocumentor-signature__visibility">protected</span>
  262. <span class="phpdocumentor-signature__type">resource|<abbr title="\GdImage">GdImage</abbr></span>
  263. <span class="phpdocumentor-signature__name">$image</span>
  264. </code>
  265. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  266. Tags
  267. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  268. </h5>
  269. <dl class="phpdocumentor-tag-list">
  270. <dt class="phpdocumentor-tag-list__entry">
  271. <span class="phpdocumentor-tag__name">see</span>
  272. </dt>
  273. <dd class="phpdocumentor-tag-list__definition">
  274. <span class="phpdocumentor-tag-link"><abbr title="\chillerlan\QRCode\Output\imagecreatetruecolor()">imagecreatetruecolor()</abbr></span>
  275. </dd>
  276. </dl>
  277. </article>
  278. <article
  279. class="
  280. phpdocumentor-element
  281. -property
  282. -protected
  283. "
  284. >
  285. <h4 class="phpdocumentor-element__name" id="property_length">
  286. $length
  287. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_length" class="headerlink"><i class="fas fa-link"></i></a>
  288. <span class="phpdocumentor-element__modifiers">
  289. </span>
  290. </h4>
  291. <aside class="phpdocumentor-element-found-in">
  292. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  293. :
  294. <span class="phpdocumentor-element-found-in__line">40</span>
  295. </aside>
  296. <p class="phpdocumentor-summary">the side length of the QR image (modules * scale)</p>
  297. <code class="phpdocumentor-code phpdocumentor-signature ">
  298. <span class="phpdocumentor-signature__visibility">protected</span>
  299. <span class="phpdocumentor-signature__type">int</span>
  300. <span class="phpdocumentor-signature__name">$length</span>
  301. </code>
  302. <section class="phpdocumentor-description"></section>
  303. </article>
  304. <article
  305. class="
  306. phpdocumentor-element
  307. -property
  308. -protected
  309. "
  310. >
  311. <h4 class="phpdocumentor-element__name" id="property_matrix">
  312. $matrix
  313. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_matrix" class="headerlink"><i class="fas fa-link"></i></a>
  314. <span class="phpdocumentor-element__modifiers">
  315. </span>
  316. </h4>
  317. <aside class="phpdocumentor-element-found-in">
  318. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  319. :
  320. <span class="phpdocumentor-element-found-in__line">50</span>
  321. </aside>
  322. <p class="phpdocumentor-summary">the (filled) data matrix object</p>
  323. <code class="phpdocumentor-code phpdocumentor-signature ">
  324. <span class="phpdocumentor-signature__visibility">protected</span>
  325. <span class="phpdocumentor-signature__type"><a href="classes/chillerlan-QRCode-Data-QRMatrix.html"><abbr title="\chillerlan\QRCode\Data\QRMatrix">QRMatrix</abbr></a></span>
  326. <span class="phpdocumentor-signature__name">$matrix</span>
  327. </code>
  328. <section class="phpdocumentor-description"></section>
  329. </article>
  330. <article
  331. class="
  332. phpdocumentor-element
  333. -property
  334. -protected
  335. "
  336. >
  337. <h4 class="phpdocumentor-element__name" id="property_moduleCount">
  338. $moduleCount
  339. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_moduleCount" class="headerlink"><i class="fas fa-link"></i></a>
  340. <span class="phpdocumentor-element__modifiers">
  341. </span>
  342. </h4>
  343. <aside class="phpdocumentor-element-found-in">
  344. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  345. :
  346. <span class="phpdocumentor-element-found-in__line">28</span>
  347. </aside>
  348. <p class="phpdocumentor-summary">the current size of the QR matrix</p>
  349. <code class="phpdocumentor-code phpdocumentor-signature ">
  350. <span class="phpdocumentor-signature__visibility">protected</span>
  351. <span class="phpdocumentor-signature__type">int</span>
  352. <span class="phpdocumentor-signature__name">$moduleCount</span>
  353. </code>
  354. <section class="phpdocumentor-description"></section>
  355. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  356. Tags
  357. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  358. </h5>
  359. <dl class="phpdocumentor-tag-list">
  360. <dt class="phpdocumentor-tag-list__entry">
  361. <span class="phpdocumentor-tag__name">see</span>
  362. </dt>
  363. <dd class="phpdocumentor-tag-list__definition">
  364. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Data-QRMatrix.html#method_size"><abbr title="\chillerlan\QRCode\Data\QRMatrix::size()">QRMatrix::size()</abbr></a></span>
  365. </dd>
  366. </dl>
  367. </article>
  368. <article
  369. class="
  370. phpdocumentor-element
  371. -property
  372. -protected
  373. "
  374. >
  375. <h4 class="phpdocumentor-element__name" id="property_moduleValues">
  376. $moduleValues
  377. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_moduleValues" class="headerlink"><i class="fas fa-link"></i></a>
  378. <span class="phpdocumentor-element__modifiers">
  379. </span>
  380. </h4>
  381. <aside class="phpdocumentor-element-found-in">
  382. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  383. :
  384. <span class="phpdocumentor-element-found-in__line">45</span>
  385. </aside>
  386. <p class="phpdocumentor-summary">an (optional) array of color values for the several QR matrix parts</p>
  387. <code class="phpdocumentor-code phpdocumentor-signature ">
  388. <span class="phpdocumentor-signature__visibility">protected</span>
  389. <span class="phpdocumentor-signature__type">array&lt;string|int, mixed&gt;</span>
  390. <span class="phpdocumentor-signature__name">$moduleValues</span>
  391. </code>
  392. <section class="phpdocumentor-description"></section>
  393. </article>
  394. <article
  395. class="
  396. phpdocumentor-element
  397. -property
  398. -protected
  399. "
  400. >
  401. <h4 class="phpdocumentor-element__name" id="property_options">
  402. $options
  403. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_options" class="headerlink"><i class="fas fa-link"></i></a>
  404. <span class="phpdocumentor-element__modifiers">
  405. </span>
  406. </h4>
  407. <aside class="phpdocumentor-element-found-in">
  408. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  409. :
  410. <span class="phpdocumentor-element-found-in__line">55</span>
  411. </aside>
  412. <code class="phpdocumentor-code phpdocumentor-signature ">
  413. <span class="phpdocumentor-signature__visibility">protected</span>
  414. <span class="phpdocumentor-signature__type"><abbr title="\chillerlan\Settings\SettingsContainerInterface">SettingsContainerInterface</abbr></span>
  415. <span class="phpdocumentor-signature__name">$options</span>
  416. </code>
  417. </article>
  418. <article
  419. class="
  420. phpdocumentor-element
  421. -property
  422. -protected
  423. "
  424. >
  425. <h4 class="phpdocumentor-element__name" id="property_scale">
  426. $scale
  427. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#property_scale" class="headerlink"><i class="fas fa-link"></i></a>
  428. <span class="phpdocumentor-element__modifiers">
  429. </span>
  430. </h4>
  431. <aside class="phpdocumentor-element-found-in">
  432. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  433. :
  434. <span class="phpdocumentor-element-found-in__line">35</span>
  435. </aside>
  436. <p class="phpdocumentor-summary">the current scaling for a QR pixel</p>
  437. <code class="phpdocumentor-code phpdocumentor-signature ">
  438. <span class="phpdocumentor-signature__visibility">protected</span>
  439. <span class="phpdocumentor-signature__type">int</span>
  440. <span class="phpdocumentor-signature__name">$scale</span>
  441. </code>
  442. <section class="phpdocumentor-description"></section>
  443. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  444. Tags
  445. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  446. </h5>
  447. <dl class="phpdocumentor-tag-list">
  448. <dt class="phpdocumentor-tag-list__entry">
  449. <span class="phpdocumentor-tag__name">see</span>
  450. </dt>
  451. <dd class="phpdocumentor-tag-list__definition">
  452. <span class="phpdocumentor-tag-link"><abbr title="\chillerlan\QRCode\QROptions::$scale">QROptions::$scale</abbr></span>
  453. </dd>
  454. </dl>
  455. </article>
  456. </section>
  457. <section class="phpdocumentor-methods">
  458. <h3 class="phpdocumentor-elements__header" id="methods">
  459. Methods
  460. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#methods" class="headerlink"><i class="fas fa-link"></i></a>
  461. </h3>
  462. <article
  463. class="phpdocumentor-element
  464. -method
  465. -public
  466. "
  467. >
  468. <h4 class="phpdocumentor-element__name" id="method___construct">
  469. __construct()
  470. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method___construct" class="headerlink"><i class="fas fa-link"></i></a>
  471. </h4>
  472. <aside class="phpdocumentor-element-found-in">
  473. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRGdImage.php"><a href="files/src-output-qrgdimage.html"><abbr title="src/Output/QRGdImage.php">QRGdImage.php</abbr></a></abbr>
  474. :
  475. <span class="phpdocumentor-element-found-in__line">44</span>
  476. </aside>
  477. <p class="phpdocumentor-summary">QROutputAbstract constructor.</p>
  478. <code class="phpdocumentor-code phpdocumentor-signature ">
  479. <span class="phpdocumentor-signature__visibility">public</span>
  480. <span class="phpdocumentor-signature__name">__construct</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><abbr title="\chillerlan\Settings\SettingsContainerInterface">SettingsContainerInterface</abbr>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$options</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Data-QRMatrix.html"><abbr title="\chillerlan\QRCode\Data\QRMatrix">QRMatrix</abbr></a>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$matrix</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
  481. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  482. <dl class="phpdocumentor-argument-list">
  483. <dt class="phpdocumentor-argument-list__entry">
  484. <span class="phpdocumentor-signature__argument__name">$options</span>
  485. : <span class="phpdocumentor-signature__argument__return-type"><abbr title="\chillerlan\Settings\SettingsContainerInterface">SettingsContainerInterface</abbr></span>
  486. </dt>
  487. <dd class="phpdocumentor-argument-list__definition">
  488. <section class="phpdocumentor-description"></section>
  489. </dd>
  490. <dt class="phpdocumentor-argument-list__entry">
  491. <span class="phpdocumentor-signature__argument__name">$matrix</span>
  492. : <span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Data-QRMatrix.html"><abbr title="\chillerlan\QRCode\Data\QRMatrix">QRMatrix</abbr></a></span>
  493. </dt>
  494. <dd class="phpdocumentor-argument-list__definition">
  495. <section class="phpdocumentor-description"></section>
  496. </dd>
  497. </dl>
  498. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  499. Tags
  500. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  501. </h5>
  502. <dl class="phpdocumentor-tag-list">
  503. <dt class="phpdocumentor-tag-list__entry">
  504. <span class="phpdocumentor-tag__name">inheritDoc</span>
  505. </dt>
  506. <dd class="phpdocumentor-tag-list__definition">
  507. </dd>
  508. <dt class="phpdocumentor-tag-list__entry">
  509. <span class="phpdocumentor-tag__name">throws</span>
  510. </dt>
  511. <dd class="phpdocumentor-tag-list__definition">
  512. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Output-QRCodeOutputException.html"><abbr title="\chillerlan\QRCode\Output\QRCodeOutputException">QRCodeOutputException</abbr></a></span>
  513. </dd>
  514. </dl>
  515. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  516. <span class="phpdocumentor-signature__response_type">mixed</span>
  517. &mdash;
  518. </article>
  519. <article
  520. class="phpdocumentor-element
  521. -method
  522. -public
  523. "
  524. >
  525. <h4 class="phpdocumentor-element__name" id="method_dump">
  526. dump()
  527. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_dump" class="headerlink"><i class="fas fa-link"></i></a>
  528. </h4>
  529. <aside class="phpdocumentor-element-found-in">
  530. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRGdImage.php"><a href="files/src-output-qrgdimage.html"><abbr title="src/Output/QRGdImage.php">QRGdImage.php</abbr></a></abbr>
  531. :
  532. <span class="phpdocumentor-element-found-in__line">82</span>
  533. </aside>
  534. <code class="phpdocumentor-code phpdocumentor-signature ">
  535. <span class="phpdocumentor-signature__visibility">public</span>
  536. <span class="phpdocumentor-signature__name">dump</span><span>(</span><span class="phpdocumentor-signature__argument"><span>[</span><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$file</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">null</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string|resource|<abbr title="\GdImage">GdImage</abbr></span></code>
  537. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  538. <dl class="phpdocumentor-argument-list">
  539. <dt class="phpdocumentor-argument-list__entry">
  540. <span class="phpdocumentor-signature__argument__name">$file</span>
  541. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  542. = <span class="phpdocumentor-signature__argument__default-value">null</span> </dt>
  543. <dd class="phpdocumentor-argument-list__definition">
  544. <section class="phpdocumentor-description"></section>
  545. </dd>
  546. </dl>
  547. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  548. Tags
  549. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  550. </h5>
  551. <dl class="phpdocumentor-tag-list">
  552. <dt class="phpdocumentor-tag-list__entry">
  553. <span class="phpdocumentor-tag__name">inheritDoc</span>
  554. </dt>
  555. <dd class="phpdocumentor-tag-list__definition">
  556. </dd>
  557. <dt class="phpdocumentor-tag-list__entry">
  558. <span class="phpdocumentor-tag__name">phan-suppress</span>
  559. </dt>
  560. <dd class="phpdocumentor-tag-list__definition">
  561. <section class="phpdocumentor-description"><p>PhanUndeclaredTypeReturnType, PhanTypeMismatchReturn</p>
  562. </section>
  563. </dd>
  564. <dt class="phpdocumentor-tag-list__entry">
  565. <span class="phpdocumentor-tag__name">throws</span>
  566. </dt>
  567. <dd class="phpdocumentor-tag-list__definition">
  568. <span class="phpdocumentor-tag-link"><abbr title="\ErrorException">ErrorException</abbr></span>
  569. </dd>
  570. </dl>
  571. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  572. <span class="phpdocumentor-signature__response_type">string|resource|<abbr title="\GdImage">GdImage</abbr></span>
  573. &mdash;
  574. </article>
  575. <article
  576. class="phpdocumentor-element
  577. -method
  578. -protected
  579. "
  580. >
  581. <h4 class="phpdocumentor-element__name" id="method_base64encode">
  582. base64encode()
  583. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_base64encode" class="headerlink"><i class="fas fa-link"></i></a>
  584. </h4>
  585. <aside class="phpdocumentor-element-found-in">
  586. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  587. :
  588. <span class="phpdocumentor-element-found-in__line">111</span>
  589. </aside>
  590. <p class="phpdocumentor-summary">Returns a base64 data URI for the given string and mime type</p>
  591. <code class="phpdocumentor-code phpdocumentor-signature ">
  592. <span class="phpdocumentor-signature__visibility">protected</span>
  593. <span class="phpdocumentor-signature__name">base64encode</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$data</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$mime</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
  594. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  595. <dl class="phpdocumentor-argument-list">
  596. <dt class="phpdocumentor-argument-list__entry">
  597. <span class="phpdocumentor-signature__argument__name">$data</span>
  598. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  599. </dt>
  600. <dd class="phpdocumentor-argument-list__definition">
  601. <section class="phpdocumentor-description"></section>
  602. </dd>
  603. <dt class="phpdocumentor-argument-list__entry">
  604. <span class="phpdocumentor-signature__argument__name">$mime</span>
  605. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  606. </dt>
  607. <dd class="phpdocumentor-argument-list__definition">
  608. <section class="phpdocumentor-description"></section>
  609. </dd>
  610. </dl>
  611. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  612. <span class="phpdocumentor-signature__response_type">string</span>
  613. &mdash;
  614. </article>
  615. <article
  616. class="phpdocumentor-element
  617. -method
  618. -protected
  619. "
  620. >
  621. <h4 class="phpdocumentor-element__name" id="method_collectModules">
  622. collectModules()
  623. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_collectModules" class="headerlink"><i class="fas fa-link"></i></a>
  624. </h4>
  625. <aside class="phpdocumentor-element-found-in">
  626. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  627. :
  628. <span class="phpdocumentor-element-found-in__line">138</span>
  629. </aside>
  630. <p class="phpdocumentor-summary">collects the modules per QRMatrix::M_* type and runs a $transform functio on each module and
  631. returns an array with the transformed modules</p>
  632. <code class="phpdocumentor-code phpdocumentor-signature ">
  633. <span class="phpdocumentor-signature__visibility">protected</span>
  634. <span class="phpdocumentor-signature__name">collectModules</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><abbr title="\Closure">Closure</abbr>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$transform</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span></code>
  635. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  636. <dl class="phpdocumentor-argument-list">
  637. <dt class="phpdocumentor-argument-list__entry">
  638. <span class="phpdocumentor-signature__argument__name">$transform</span>
  639. : <span class="phpdocumentor-signature__argument__return-type"><abbr title="\Closure">Closure</abbr></span>
  640. </dt>
  641. <dd class="phpdocumentor-argument-list__definition">
  642. <section class="phpdocumentor-description"></section>
  643. </dd>
  644. </dl>
  645. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  646. <span class="phpdocumentor-signature__response_type">array&lt;string|int, mixed&gt;</span>
  647. &mdash;
  648. </article>
  649. <article
  650. class="phpdocumentor-element
  651. -method
  652. -protected
  653. "
  654. >
  655. <h4 class="phpdocumentor-element__name" id="method_dumpImage">
  656. dumpImage()
  657. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_dumpImage" class="headerlink"><i class="fas fa-link"></i></a>
  658. </h4>
  659. <aside class="phpdocumentor-element-found-in">
  660. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRGdImage.php"><a href="files/src-output-qrgdimage.html"><abbr title="src/Output/QRGdImage.php">QRGdImage.php</abbr></a></abbr>
  661. :
  662. <span class="phpdocumentor-element-found-in__line">174</span>
  663. </aside>
  664. <p class="phpdocumentor-summary">Creates the final image by calling the desired GD output function</p>
  665. <code class="phpdocumentor-code phpdocumentor-signature ">
  666. <span class="phpdocumentor-signature__visibility">protected</span>
  667. <span class="phpdocumentor-signature__name">dumpImage</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
  668. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  669. Tags
  670. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  671. </h5>
  672. <dl class="phpdocumentor-tag-list">
  673. <dt class="phpdocumentor-tag-list__entry">
  674. <span class="phpdocumentor-tag__name">throws</span>
  675. </dt>
  676. <dd class="phpdocumentor-tag-list__definition">
  677. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Output-QRCodeOutputException.html"><abbr title="\chillerlan\QRCode\Output\QRCodeOutputException">QRCodeOutputException</abbr></a></span>
  678. </dd>
  679. </dl>
  680. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  681. <span class="phpdocumentor-signature__response_type">string</span>
  682. &mdash;
  683. </article>
  684. <article
  685. class="phpdocumentor-element
  686. -method
  687. -protected
  688. "
  689. >
  690. <h4 class="phpdocumentor-element__name" id="method_getDefaultModuleValue">
  691. getDefaultModuleValue()
  692. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_getDefaultModuleValue" class="headerlink"><i class="fas fa-link"></i></a>
  693. </h4>
  694. <aside class="phpdocumentor-element-found-in">
  695. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRGdImage.php"><a href="files/src-output-qrgdimage.html"><abbr title="src/Output/QRGdImage.php">QRGdImage.php</abbr></a></abbr>
  696. :
  697. <span class="phpdocumentor-element-found-in__line">70</span>
  698. </aside>
  699. <p class="phpdocumentor-summary">Returns a defualt value for either dark or light modules (return value depends on the output module)</p>
  700. <code class="phpdocumentor-code phpdocumentor-signature ">
  701. <span class="phpdocumentor-signature__visibility">protected</span>
  702. <span class="phpdocumentor-signature__name">getDefaultModuleValue</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">bool&nbsp;</span><span class="phpdocumentor-signature__argument__name">$isDark</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
  703. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  704. <dl class="phpdocumentor-argument-list">
  705. <dt class="phpdocumentor-argument-list__entry">
  706. <span class="phpdocumentor-signature__argument__name">$isDark</span>
  707. : <span class="phpdocumentor-signature__argument__return-type">bool</span>
  708. </dt>
  709. <dd class="phpdocumentor-argument-list__definition">
  710. <section class="phpdocumentor-description"></section>
  711. </dd>
  712. </dl>
  713. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  714. Tags
  715. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  716. </h5>
  717. <dl class="phpdocumentor-tag-list">
  718. <dt class="phpdocumentor-tag-list__entry">
  719. <span class="phpdocumentor-tag__name">inheritDoc</span>
  720. </dt>
  721. <dd class="phpdocumentor-tag-list__definition">
  722. </dd>
  723. </dl>
  724. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  725. <span class="phpdocumentor-signature__response_type">mixed</span>
  726. &mdash;
  727. </article>
  728. <article
  729. class="phpdocumentor-element
  730. -method
  731. -protected
  732. "
  733. >
  734. <h4 class="phpdocumentor-element__name" id="method_getModuleValue">
  735. getModuleValue()
  736. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_getModuleValue" class="headerlink"><i class="fas fa-link"></i></a>
  737. </h4>
  738. <aside class="phpdocumentor-element-found-in">
  739. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRGdImage.php"><a href="files/src-output-qrgdimage.html"><abbr title="src/Output/QRGdImage.php">QRGdImage.php</abbr></a></abbr>
  740. :
  741. <span class="phpdocumentor-element-found-in__line">63</span>
  742. </aside>
  743. <p class="phpdocumentor-summary">Returns the final value for the given input (return value depends on the output module)</p>
  744. <code class="phpdocumentor-code phpdocumentor-signature ">
  745. <span class="phpdocumentor-signature__visibility">protected</span>
  746. <span class="phpdocumentor-signature__name">getModuleValue</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">mixed&nbsp;</span><span class="phpdocumentor-signature__argument__name">$value</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
  747. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  748. <dl class="phpdocumentor-argument-list">
  749. <dt class="phpdocumentor-argument-list__entry">
  750. <span class="phpdocumentor-signature__argument__name">$value</span>
  751. : <span class="phpdocumentor-signature__argument__return-type">mixed</span>
  752. </dt>
  753. <dd class="phpdocumentor-argument-list__definition">
  754. </dd>
  755. </dl>
  756. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  757. Tags
  758. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  759. </h5>
  760. <dl class="phpdocumentor-tag-list">
  761. <dt class="phpdocumentor-tag-list__entry">
  762. <span class="phpdocumentor-tag__name">inheritDoc</span>
  763. </dt>
  764. <dd class="phpdocumentor-tag-list__definition">
  765. </dd>
  766. </dl>
  767. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  768. <span class="phpdocumentor-signature__response_type">mixed</span>
  769. &mdash;
  770. </article>
  771. <article
  772. class="phpdocumentor-element
  773. -method
  774. -protected
  775. "
  776. >
  777. <h4 class="phpdocumentor-element__name" id="method_moduleValueIsValid">
  778. moduleValueIsValid()
  779. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_moduleValueIsValid" class="headerlink"><i class="fas fa-link"></i></a>
  780. </h4>
  781. <aside class="phpdocumentor-element-found-in">
  782. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRGdImage.php"><a href="files/src-output-qrgdimage.html"><abbr title="src/Output/QRGdImage.php">QRGdImage.php</abbr></a></abbr>
  783. :
  784. <span class="phpdocumentor-element-found-in__line">56</span>
  785. </aside>
  786. <p class="phpdocumentor-summary">Determines whether the given value is valid</p>
  787. <code class="phpdocumentor-code phpdocumentor-signature ">
  788. <span class="phpdocumentor-signature__visibility">protected</span>
  789. <span class="phpdocumentor-signature__name">moduleValueIsValid</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">mixed&nbsp;</span><span class="phpdocumentor-signature__argument__name">$value</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
  790. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  791. <dl class="phpdocumentor-argument-list">
  792. <dt class="phpdocumentor-argument-list__entry">
  793. <span class="phpdocumentor-signature__argument__name">$value</span>
  794. : <span class="phpdocumentor-signature__argument__return-type">mixed</span>
  795. </dt>
  796. <dd class="phpdocumentor-argument-list__definition">
  797. </dd>
  798. </dl>
  799. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  800. Tags
  801. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  802. </h5>
  803. <dl class="phpdocumentor-tag-list">
  804. <dt class="phpdocumentor-tag-list__entry">
  805. <span class="phpdocumentor-tag__name">inheritDoc</span>
  806. </dt>
  807. <dd class="phpdocumentor-tag-list__definition">
  808. </dd>
  809. </dl>
  810. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  811. <span class="phpdocumentor-signature__response_type">bool</span>
  812. &mdash;
  813. </article>
  814. <article
  815. class="phpdocumentor-element
  816. -method
  817. -protected
  818. "
  819. >
  820. <h4 class="phpdocumentor-element__name" id="method_saveToFile">
  821. saveToFile()
  822. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_saveToFile" class="headerlink"><i class="fas fa-link"></i></a>
  823. </h4>
  824. <aside class="phpdocumentor-element-found-in">
  825. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  826. :
  827. <span class="phpdocumentor-element-found-in__line">123</span>
  828. </aside>
  829. <p class="phpdocumentor-summary">saves the qr data to a file</p>
  830. <code class="phpdocumentor-code phpdocumentor-signature ">
  831. <span class="phpdocumentor-signature__visibility">protected</span>
  832. <span class="phpdocumentor-signature__name">saveToFile</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$data</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">string&nbsp;</span><span class="phpdocumentor-signature__argument__name">$file</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  833. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  834. <dl class="phpdocumentor-argument-list">
  835. <dt class="phpdocumentor-argument-list__entry">
  836. <span class="phpdocumentor-signature__argument__name">$data</span>
  837. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  838. </dt>
  839. <dd class="phpdocumentor-argument-list__definition">
  840. <section class="phpdocumentor-description"></section>
  841. </dd>
  842. <dt class="phpdocumentor-argument-list__entry">
  843. <span class="phpdocumentor-signature__argument__name">$file</span>
  844. : <span class="phpdocumentor-signature__argument__return-type">string</span>
  845. </dt>
  846. <dd class="phpdocumentor-argument-list__definition">
  847. <section class="phpdocumentor-description"></section>
  848. </dd>
  849. </dl>
  850. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  851. Tags
  852. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  853. </h5>
  854. <dl class="phpdocumentor-tag-list">
  855. <dt class="phpdocumentor-tag-list__entry">
  856. <span class="phpdocumentor-tag__name">see</span>
  857. </dt>
  858. <dd class="phpdocumentor-tag-list__definition">
  859. <span class="phpdocumentor-tag-link"><abbr title="\chillerlan\QRCode\Output\file_put_contents()">file_put_contents()</abbr></span>
  860. </dd>
  861. <dt class="phpdocumentor-tag-list__entry">
  862. <span class="phpdocumentor-tag__name">see</span>
  863. </dt>
  864. <dd class="phpdocumentor-tag-list__definition">
  865. <span class="phpdocumentor-tag-link"><abbr title="\chillerlan\QRCode\QROptions::cachefile">QROptions::cachefile</abbr></span>
  866. </dd>
  867. <dt class="phpdocumentor-tag-list__entry">
  868. <span class="phpdocumentor-tag__name">throws</span>
  869. </dt>
  870. <dd class="phpdocumentor-tag-list__definition">
  871. <span class="phpdocumentor-tag-link"><a href="classes/chillerlan-QRCode-Output-QRCodeOutputException.html"><abbr title="\chillerlan\QRCode\Output\QRCodeOutputException">QRCodeOutputException</abbr></a></span>
  872. </dd>
  873. </dl>
  874. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  875. <span class="phpdocumentor-signature__response_type">void</span>
  876. &mdash;
  877. </article>
  878. <article
  879. class="phpdocumentor-element
  880. -method
  881. -protected
  882. "
  883. >
  884. <h4 class="phpdocumentor-element__name" id="method_setModuleValues">
  885. setModuleValues()
  886. <a href="classes/chillerlan-QRCode-Output-QROutputAbstract.html#method_setModuleValues" class="headerlink"><i class="fas fa-link"></i></a>
  887. </h4>
  888. <aside class="phpdocumentor-element-found-in">
  889. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QROutputAbstract.php"><a href="files/src-output-qroutputabstract.html"><abbr title="src/Output/QROutputAbstract.php">QROutputAbstract.php</abbr></a></abbr>
  890. :
  891. <span class="phpdocumentor-element-found-in__line">73</span>
  892. </aside>
  893. <p class="phpdocumentor-summary">Sets the initial module values</p>
  894. <code class="phpdocumentor-code phpdocumentor-signature ">
  895. <span class="phpdocumentor-signature__visibility">protected</span>
  896. <span class="phpdocumentor-signature__name">setModuleValues</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  897. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  898. <span class="phpdocumentor-signature__response_type">void</span>
  899. &mdash;
  900. </article>
  901. <article
  902. class="phpdocumentor-element
  903. -method
  904. -protected
  905. "
  906. >
  907. <h4 class="phpdocumentor-element__name" id="method_setPixel">
  908. setPixel()
  909. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#method_setPixel" class="headerlink"><i class="fas fa-link"></i></a>
  910. </h4>
  911. <aside class="phpdocumentor-element-found-in">
  912. <abbr class="phpdocumentor-element-found-in__file" title="src/Output/QRGdImage.php"><a href="files/src-output-qrgdimage.html"><abbr title="src/Output/QRGdImage.php">QRGdImage.php</abbr></a></abbr>
  913. :
  914. <span class="phpdocumentor-element-found-in__line">146</span>
  915. </aside>
  916. <p class="phpdocumentor-summary">Creates a single QR pixel with the given settings</p>
  917. <code class="phpdocumentor-code phpdocumentor-signature ">
  918. <span class="phpdocumentor-signature__visibility">protected</span>
  919. <span class="phpdocumentor-signature__name">setPixel</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$x</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$y</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$M_TYPE</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
  920. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  921. <dl class="phpdocumentor-argument-list">
  922. <dt class="phpdocumentor-argument-list__entry">
  923. <span class="phpdocumentor-signature__argument__name">$x</span>
  924. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  925. </dt>
  926. <dd class="phpdocumentor-argument-list__definition">
  927. <section class="phpdocumentor-description"></section>
  928. </dd>
  929. <dt class="phpdocumentor-argument-list__entry">
  930. <span class="phpdocumentor-signature__argument__name">$y</span>
  931. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  932. </dt>
  933. <dd class="phpdocumentor-argument-list__definition">
  934. <section class="phpdocumentor-description"></section>
  935. </dd>
  936. <dt class="phpdocumentor-argument-list__entry">
  937. <span class="phpdocumentor-signature__argument__name">$M_TYPE</span>
  938. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  939. </dt>
  940. <dd class="phpdocumentor-argument-list__definition">
  941. <section class="phpdocumentor-description"></section>
  942. </dd>
  943. </dl>
  944. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  945. <span class="phpdocumentor-signature__response_type">void</span>
  946. &mdash;
  947. </article>
  948. </section>
  949. <script type="text/javascript">
  950. function loadExternalCodeSnippets(line) {
  951. Array.prototype.slice.call(document.querySelectorAll('pre[data-src]')).forEach((pre) => {
  952. var src = pre.getAttribute('data-src').replace( /\\/g, '/');
  953. var extension = (src.match(/\.(\w+)$/) || [, ''])[1];
  954. var language = 'php';
  955. var code = document.createElement('code');
  956. code.className = 'language-' + language;
  957. pre.textContent = '';
  958. pre.setAttribute('data-line', line)
  959. code.textContent = 'Loading…';
  960. pre.appendChild(code);
  961. var xhr = new XMLHttpRequest();
  962. xhr.open('GET', src, true);
  963. xhr.onreadystatechange = function () {
  964. if (xhr.readyState == 4) {
  965. if (xhr.status < 400 && xhr.responseText) {
  966. code.textContent = xhr.responseText;
  967. Prism.highlightElement(code);
  968. }
  969. else if (xhr.status >= 400) {
  970. code.textContent = '✖ Error ' + xhr.status + ' while fetching file: ' + xhr.statusText;
  971. }
  972. else {
  973. code.textContent = '✖ Error: File does not exist, is empty or trying to view from localhost';
  974. }
  975. }
  976. };
  977. xhr.send(null);
  978. });
  979. }
  980. var modals = document.querySelectorAll("[data-modal]");
  981. modals.forEach(function (trigger) {
  982. trigger.addEventListener("click", function (event) {
  983. //event.preventDefault();
  984. const modal = document.getElementById(trigger.dataset.modal);
  985. modal.classList.add("phpdocumentor-modal__open");
  986. loadExternalCodeSnippets(trigger.dataset.line)
  987. const exits = modal.querySelectorAll("[data-exit-button]");
  988. exits.forEach(function (exit) {
  989. exit.addEventListener("click", function (event) {
  990. event.preventDefault();
  991. modal.classList.remove("phpdocumentor-modal__open");
  992. });
  993. });
  994. });
  995. });
  996. </script>
  997. </article>
  998. <section data-search-results class="phpdocumentor-search-results phpdocumentor-search-results--hidden">
  999. <section class="phpdocumentor-search-results__dialog">
  1000. <header class="phpdocumentor-search-results__header">
  1001. <h2 class="phpdocumentor-search-results__title">Search results</h2>
  1002. <button class="phpdocumentor-search-results__close"><i class="fas fa-times"></i></button>
  1003. </header>
  1004. <section class="phpdocumentor-search-results__body">
  1005. <ul class="phpdocumentor-search-results__entries"></ul>
  1006. </section>
  1007. </section>
  1008. </section>
  1009. </div>
  1010. </div>
  1011. <a href="classes/chillerlan-QRCode-Output-QRGdImage.html#top" class="phpdocumentor-back-to-top"><i class="fas fa-chevron-circle-up"></i></a>
  1012. </main>
  1013. <script>
  1014. cssVars({});
  1015. </script>
  1016. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/prism.min.js"></script>
  1017. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/autoloader/prism-autoloader.min.js"></script>
  1018. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.min.js"></script>
  1019. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.min.js"></script>
  1020. </body>
  1021. </html>