chillerlan-QRCode-Output-QRMarkupHTML.html 67 KB

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