1 | <!DOCTYPE html>
|
2 |
|
3 | <html lang="en">
|
4 | <head>
|
5 | <meta charset="utf-8">
|
6 | <meta name="viewport" content="width=device-width">
|
7 | <title>CrossBrowdy API documentation [printable] Class: CB_Canvas</title>
|
8 |
|
9 | |
10 |
|
11 |
|
12 | <link type="text/css" rel="stylesheet" href="styles/sunlight.default.css">
|
13 |
|
14 | <link type="text/css" rel="stylesheet" href="styles/site.yeti.css">
|
15 |
|
16 | </head>
|
17 |
|
18 | <body style="min-width:800px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
19 |
|
20 | <div class="navbar navbar-default navbar-fixed-top ">
|
21 | <div class="container">
|
22 | <div class="navbar-header">
|
23 | <a class="navbar-brand" href="index.html">CrossBrowdy API documentation [printable]</a>
|
24 | <button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#topNavigation">
|
25 | <span class="icon-bar"></span>
|
26 | <span class="icon-bar"></span>
|
27 | <span class="icon-bar"></span>
|
28 | </button>
|
29 | </div>
|
30 | <div class="navbar-collapse collapse" id="topNavigation">
|
31 | <ul class="nav navbar-nav">
|
32 |
|
33 | <li class="dropdown">
|
34 | <a href="namespaces.list.html" class="dropdown-toggle" data-toggle="dropdown">Namespaces<b class="caret"></b></a>
|
35 | <ul class="dropdown-menu inline">
|
36 | <li><a href="CB_Arrays.html">CB_Arrays</a></li><li><a href="CB_AudioDetector.html">CB_AudioDetector</a></li><li><a href="CB_Client.html">CB_Client</a></li><li><a href="CB_Collisions.html">CB_Collisions</a></li><li><a href="CB_Configuration.html">CB_Configuration</a></li><li><a href="CB_Configuration.CrossBase.html">CB_Configuration.CrossBase</a></li><li><a href="CB_Configuration.CrossBrowdy.html">CB_Configuration.CrossBrowdy</a></li><li><a href="CB_Controllers.html">CB_Controllers</a></li><li><a href="CB_Controllers_Proprietary.html">CB_Controllers_Proprietary</a></li><li><a href="CB_Controllers_Proprietary.WII.html">CB_Controllers_Proprietary.WII</a></li><li><a href="CB_Controllers_Proprietary.WII_U.html">CB_Controllers_Proprietary.WII_U</a></li><li><a href="CB_Device.html">CB_Device</a></li><li><a href="CB_Device.AmbientLight.html">CB_Device.AmbientLight</a></li><li><a href="CB_Device.Battery.html">CB_Device.Battery</a></li><li><a href="CB_Device.Location.html">CB_Device.Location</a></li><li><a href="CB_Device.Motion.html">CB_Device.Motion</a></li><li><a href="CB_Device.Orientation.html">CB_Device.Orientation</a></li><li><a href="CB_Device.Proximity.html">CB_Device.Proximity</a></li><li><a href="CB_Device.Vibration.html">CB_Device.Vibration</a></li><li><a href="CB_Elements.html">CB_Elements</a></li><li><a href="CB_Events.html">CB_Events</a></li><li><a href="CB_Keyboard.html">CB_Keyboard</a></li><li><a href="CB_Keyboard.chars.html">CB_Keyboard.chars</a></li><li><a href="CB_Keyboard.extended.html">CB_Keyboard.extended</a></li><li><a href="CB_Keyboard.keys.html">CB_Keyboard.keys</a></li><li><a href="CB_Modules.html">CB_Modules</a></li><li><a href="CB_Mouse.html">CB_Mouse</a></li><li><a href="CB_Mouse.CursorImage.html">CB_Mouse.CursorImage</a></li><li><a href="CB_Net.html">CB_Net</a></li><li><a href="CB_Net.Fetch.html">CB_Net.Fetch</a></li><li><a href="CB_Net.REST.html">CB_Net.REST</a></li><li><a href="CB_Net.Sockets.html">CB_Net.Sockets</a></li><li><a href="CB_Net.Sockets.SockJS.html">CB_Net.Sockets.SockJS</a></li><li><a href="CB_Net.XHR.html">CB_Net.XHR</a></li><li><a href="CB_Pointer.html">CB_Pointer</a></li><li><a href="CB_Screen.html">CB_Screen</a></li><li><a href="CB_Speaker.html">CB_Speaker</a></li><li><a href="CB_Touch.html">CB_Touch</a></li><li><a href="CB_baseSymbols.html">CB_baseSymbols</a></li>
|
37 | </ul>
|
38 | </li>
|
39 |
|
40 | <li class="dropdown">
|
41 | <a href="classes.list.html" class="dropdown-toggle" data-toggle="dropdown">Classes<b class="caret"></b></a>
|
42 | <ul class="dropdown-menu inline">
|
43 | <li><a href="CB_AudioFile.html">CB_AudioFile</a></li><li><a href="CB_AudioFileCache.html">CB_AudioFileCache</a></li><li><a href="CB_AudioFileSprites.html">CB_AudioFileSprites</a></li><li><a href="CB_AudioFileSpritesPool.html">CB_AudioFileSpritesPool</a></li><li><a href="CB_AudioFile_API.AAPI.html">CB_AudioFile_API.AAPI</a></li><li><a href="CB_AudioFile_API.ACMP.html">CB_AudioFile_API.ACMP</a></li><li><a href="CB_AudioFile_API.SM2.html">CB_AudioFile_API.SM2</a></li><li><a href="CB_AudioFile_API.WAAPI.html">CB_AudioFile_API.WAAPI</a></li><li><a href="CB_Canvas.html">CB_Canvas</a></li><li><a href="CB_GraphicSprites.html">CB_GraphicSprites</a></li><li><a href="CB_GraphicSpritesScene.html">CB_GraphicSpritesScene</a></li>
|
44 | </ul>
|
45 | </li>
|
46 |
|
47 | <li class="dropdown">
|
48 | <a href="global.html" class="dropdown-toggle" data-toggle="dropdown">Global<b class="caret"></b></a>
|
49 | <ul class="dropdown-menu inline">
|
50 | <li><a href="global.html#CB_BASE_NAME">CB_BASE_NAME</a></li><li><a href="global.html#CB_CREDITS_DEFAULT">CB_CREDITS_DEFAULT</a></li><li><a href="global.html#CB_NAME">CB_NAME</a></li><li><a href="global.html#CB_OPTIONS">CB_OPTIONS</a></li><li><a href="global.html#CB_VERSION">CB_VERSION</a></li><li><a href="global.html#CB_addCredits">CB_addCredits</a></li><li><a href="global.html#CB_baseToBase">CB_baseToBase</a></li><li><a href="global.html#CB_baseToInt">CB_baseToInt</a></li><li><a href="global.html#CB_br2nl">CB_br2nl</a></li><li><a href="global.html#CB_brToNl">CB_brToNl</a></li><li><a href="global.html#CB_combineArraysOrObjects">CB_combineArraysOrObjects</a></li><li><a href="global.html#CB_combineAutomatically">CB_combineAutomatically</a></li><li><a href="global.html#CB_combineJSON">CB_combineJSON</a></li><li><a href="global.html#CB_combineURIParameters">CB_combineURIParameters</a></li><li><a href="global.html#CB_combineURLParameters">CB_combineURLParameters</a></li><li><a href="global.html#CB_console">CB_console</a></li><li><a href="global.html#CB_copyObject">CB_copyObject</a></li><li><a href="global.html#CB_countDecimalDigits">CB_countDecimalDigits</a></li><li><a href="global.html#CB_countDecimalPart">CB_countDecimalPart</a></li><li><a href="global.html#CB_countDecimals">CB_countDecimals</a></li><li><a href="global.html#CB_countIntegerDigits">CB_countIntegerDigits</a></li><li><a href="global.html#CB_countIntegerPart">CB_countIntegerPart</a></li><li><a href="global.html#CB_credits">CB_credits</a></li><li><a href="global.html#CB_forEach">CB_forEach</a></li><li><a href="global.html#CB_forceString">CB_forceString</a></li><li><a href="global.html#CB_getBase64StringObject">CB_getBase64StringObject</a></li><li><a href="global.html#CB_getCookie">CB_getCookie</a></li><li><a href="global.html#CB_getDatum">CB_getDatum</a></li><li><a href="global.html#CB_getJSONPropertyValue">CB_getJSONPropertyValue</a></li><li><a href="global.html#CB_getLZStringObject">CB_getLZStringObject</a></li><li><a href="global.html#CB_getValueIndex">CB_getValueIndex</a></li><li><a href="global.html#CB_getValuePath">CB_getValuePath</a></li><li><a href="global.html#CB_includeJSFile">CB_includeJSFile</a></li><li><a href="global.html#CB_indexOf">CB_indexOf</a></li><li><a href="global.html#CB_init">CB_init</a></li><li><a href="global.html#CB_intToBase">CB_intToBase</a></li><li><a href="global.html#CB_isArray">CB_isArray</a></li><li><a href="global.html#CB_isEmail">CB_isEmail</a></li><li><a href="global.html#CB_isFileLocal">CB_isFileLocal</a></li><li><a href="global.html#CB_isString">CB_isString</a></li><li><a href="global.html#CB_lastIndexOf">CB_lastIndexOf</a></li><li><a href="global.html#CB_ltrim">CB_ltrim</a></li><li><a href="global.html#CB_nl2br">CB_nl2br</a></li><li><a href="global.html#CB_nlToBr">CB_nlToBr</a></li><li><a href="global.html#CB_numberFormat">CB_numberFormat</a></li><li><a href="global.html#CB_numberOfDecimalDigits">CB_numberOfDecimalDigits</a></li><li><a href="global.html#CB_numberOfDecimals">CB_numberOfDecimals</a></li><li><a href="global.html#CB_numberOfIntegerDigits">CB_numberOfIntegerDigits</a></li><li><a href="global.html#CB_parseJSON">CB_parseJSON</a></li><li><a href="global.html#CB_parseString">CB_parseString</a></li><li><a href="global.html#CB_regularExpressionString">CB_regularExpressionString</a></li><li><a href="global.html#CB_renderString">CB_renderString</a></li><li><a href="global.html#CB_replaceAll">CB_replaceAll</a></li><li><a href="global.html#CB_rtrim">CB_rtrim</a></li><li><a href="global.html#CB_scriptPath">CB_scriptPath</a></li><li><a href="global.html#CB_scriptPathCalculate">CB_scriptPathCalculate</a></li><li><a href="global.html#CB_setCookie">CB_setCookie</a></li><li><a href="global.html#CB_setDatum">CB_setDatum</a></li><li><a href="global.html#CB_sizeOf">CB_sizeOf</a></li><li><a href="global.html#CB_sizeof">CB_sizeof</a></li><li><a href="global.html#CB_stringifyJSON">CB_stringifyJSON</a></li><li><a href="global.html#CB_symmetricCall">CB_symmetricCall</a></li><li><a href="global.html#CB_symmetricCallClear">CB_symmetricCallClear</a></li><li><a href="global.html#CB_this">CB_this</a></li><li><a href="global.html#CB_trim">CB_trim</a></li>
|
51 | </ul>
|
52 | </li>
|
53 |
|
54 | </ul>
|
55 |
|
56 | <div class="col-sm-3 col-md-3">
|
57 | <form class="navbar-form" role="search">
|
58 | <div class="input-group">
|
59 | <input type="text" class="form-control" placeholder="Search" name="q" id="search-input">
|
60 | <div class="input-group-btn">
|
61 | <button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button>
|
62 | </div>
|
63 | </div>
|
64 | </form>
|
65 | </div>
|
66 |
|
67 | </div>
|
68 |
|
69 | </div>
|
70 | </div>
|
71 |
|
72 |
|
73 | <div class="container" id="toc-content" style="width:100%;">
|
74 | <div class="row" style="width:100%;">
|
75 |
|
76 |
|
77 | <div class="col-md-8" style="width:85%;">
|
78 |
|
79 | <div id="main">
|
80 |
|
81 |
|
82 |
|
83 | <h1 class="page-title">Class: CB_Canvas</h1>
|
84 |
|
85 | <section>
|
86 |
|
87 | <header>
|
88 |
|
89 | <h2>
|
90 | CB_Canvas
|
91 | </h2>
|
92 |
|
93 | <div class="class-description"><p>Class to manage a canvas. For clients which do not support native <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas">canvas</a>, it provides <a href="https://en.wikipedia.org/wiki/Adobe_Flash_Player">Adobe Flash (formerly Macromedia Flash)</a> emulation with <a href="https://github.com/everlaat/flashcanvas">FlashCanvas</a>, Microsoft Silverlight emulation with <a href="https://slcanvas.codeplex.com/">SLCanvas</a>, VML emulation with <a href="https://github.com/arv/explorercanvas">ExplorerCanvas</a> (reinforced with <a href="https://github.com/PhenX/canvas-text">canvas-text</a>) and DHTML (DOM elements) emulation with <a href="https://github.com/robertinglin/CanBox">CanBox</a>.<br>
|
94 | NOTE:<br>
|
95 | To make the VML emulation work without errors (using <a href="https://github.com/arv/explorercanvas">ExplorerCanvas</a>), it is recommended to always load <a href="https://github.com/everlaat/flashcanvas">FlashCanvas</a> (which already includes <a href="https://github.com/arv/explorercanvas">ExplorerCanvas</a>) in your HTML code (without using lazy-load, as <a href="https://github.com/arv/explorercanvas">ExplorerCanvas</a> does not support it). This is recommended even when we are not going to use <a href="https://en.wikipedia.org/wiki/Adobe_Flash_Player">Adobe Flash (formerly Macromedia Flash)</a> emulation with <a href="https://github.com/everlaat/flashcanvas">FlashCanvas</a>.<br>
|
96 | This is an example (should be placed before loading the main "CrossBrowdy" script):<br>
|
97 | <!-- Loads FlashCanvas (Flash emulation) before CrossBrowdy. Needed also to use ExplorerCanvas (VML emulation) without problems: --><br>
|
98 | <script type="text/javascript" src="CrossBrowdy/CrossBase/audiovisual/image/canvas/FlashCanvas/pro/bin/flashcanvas.js"></script><!-- FlashCanvas/ExplorerCanvas do not support lazy load. --></p></div>
|
99 |
|
100 |
|
101 | </header>
|
102 |
|
103 |
|
104 | <article>
|
105 | <div class="container-overview">
|
106 |
|
107 |
|
108 | <hr>
|
109 | <dt>
|
110 | <h4 class="name" id="CB_Canvas"><span class="type-signature"></span>new CB_Canvas<span class="signature">(canvasId [, contextType] [, canvasWidth] [, canvasHeight] [, onLoad] [, onError] [, canvasParent] [, alternativeCanvasEmulationPreferredOrder] [, forceFirstEmulationMethod] [, addOtherMethods] [, allowFlashCanvasLocally])</span><span class="type-signature"> → {<a href="CB_Canvas.html">CB_Canvas</a>}</span></h4>
|
111 |
|
112 |
|
113 | </dt>
|
114 | <dd>
|
115 |
|
116 |
|
117 | <div class="description">
|
118 | <p>Class to manage a canvas.</p>
|
119 | </div>
|
120 |
|
121 |
|
122 |
|
123 |
|
124 |
|
125 |
|
126 |
|
127 |
|
128 | <h5>Parameters:</h5>
|
129 |
|
130 |
|
131 | <table class="params table table-striped">
|
132 | <thead>
|
133 | <tr>
|
134 |
|
135 | <th style="width:12%; min-width:110px;">Name</th>
|
136 |
|
137 |
|
138 | <th style="width:12%; min-width:110px;">Type</th>
|
139 |
|
140 |
|
141 | <th style="width:12%; min-width:110px;">Argument</th>
|
142 |
|
143 |
|
144 |
|
145 | <th style="width:12%; min-width:110px;">Default</th>
|
146 |
|
147 |
|
148 | <th class="last" style="min-width:310px;">Description</th>
|
149 | </tr>
|
150 | </thead>
|
151 |
|
152 | <tbody>
|
153 |
|
154 |
|
155 | <tr>
|
156 |
|
157 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasId</code></td>
|
158 |
|
159 |
|
160 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
161 |
|
162 |
|
163 | <span class="param-type">string</span>
|
164 |
|
165 |
|
166 |
|
167 |
|
168 | </td>
|
169 |
|
170 |
|
171 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
172 |
|
173 |
|
174 |
|
175 |
|
176 |
|
177 | </td>
|
178 |
|
179 |
|
180 |
|
181 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
182 |
|
183 | </td>
|
184 |
|
185 |
|
186 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The desired ID for the canvas.</p></td>
|
187 | </tr>
|
188 |
|
189 |
|
190 |
|
191 | <tr>
|
192 |
|
193 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>contextType</code></td>
|
194 |
|
195 |
|
196 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
197 |
|
198 |
|
199 | <span class="param-type">'2d'</span>
|
200 | |
|
201 |
|
202 | <span class="param-type">'webgl'</span>
|
203 | |
|
204 |
|
205 | <span class="param-type">'experimental-webgl'</span>
|
206 | |
|
207 |
|
208 | <span class="param-type">'webgl2'</span>
|
209 | |
|
210 |
|
211 | <span class="param-type">'experimental-webgl2'</span>
|
212 | |
|
213 |
|
214 | <span class="param-type">'bitmaprenderer'</span>
|
215 |
|
216 |
|
217 |
|
218 |
|
219 | </td>
|
220 |
|
221 |
|
222 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
223 |
|
224 | <optional><br>
|
225 |
|
226 |
|
227 |
|
228 |
|
229 |
|
230 | </td>
|
231 |
|
232 |
|
233 |
|
234 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
235 |
|
236 | '2d'
|
237 |
|
238 | </td>
|
239 |
|
240 |
|
241 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The contextType desired by default. More information: <a href="https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/getContext">HTMLCanvasElement.getContext</a>. Note that most emulation methods will only support "2d".</p></td>
|
242 | </tr>
|
243 |
|
244 |
|
245 |
|
246 | <tr>
|
247 |
|
248 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasWidth</code></td>
|
249 |
|
250 |
|
251 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
252 |
|
253 |
|
254 | <span class="param-type">integer</span>
|
255 |
|
256 |
|
257 |
|
258 |
|
259 | </td>
|
260 |
|
261 |
|
262 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
263 |
|
264 | <optional><br>
|
265 |
|
266 |
|
267 |
|
268 |
|
269 |
|
270 | </td>
|
271 |
|
272 |
|
273 |
|
274 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
275 |
|
276 | <a href="CB_Canvas.html#.WIDTH_DEFAULT"><code>CB_Canvas.WIDTH_DEFAULT</code></a>
|
277 |
|
278 | </td>
|
279 |
|
280 |
|
281 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The desired width (horizontal size) in pixels for the canvas.</p></td>
|
282 | </tr>
|
283 |
|
284 |
|
285 |
|
286 | <tr>
|
287 |
|
288 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasHeight</code></td>
|
289 |
|
290 |
|
291 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
292 |
|
293 |
|
294 | <span class="param-type">integer</span>
|
295 |
|
296 |
|
297 |
|
298 |
|
299 | </td>
|
300 |
|
301 |
|
302 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
303 |
|
304 | <optional><br>
|
305 |
|
306 |
|
307 |
|
308 |
|
309 |
|
310 | </td>
|
311 |
|
312 |
|
313 |
|
314 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
315 |
|
316 | <a href="CB_Canvas.html#.HEIGHT_DEFAULT"><code>CB_Canvas.HEIGHT_DEFAULT</code></a>
|
317 |
|
318 | </td>
|
319 |
|
320 |
|
321 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The desired height (vertical size) in pixels for the canvas.</p></td>
|
322 | </tr>
|
323 |
|
324 |
|
325 |
|
326 | <tr>
|
327 |
|
328 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onLoad</code></td>
|
329 |
|
330 |
|
331 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
332 |
|
333 |
|
334 | <span class="param-type">function</span>
|
335 |
|
336 |
|
337 |
|
338 |
|
339 | </td>
|
340 |
|
341 |
|
342 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
343 |
|
344 | <optional><br>
|
345 |
|
346 |
|
347 |
|
348 |
|
349 |
|
350 | </td>
|
351 |
|
352 |
|
353 |
|
354 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
355 |
|
356 | </td>
|
357 |
|
358 |
|
359 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback function that will be called when the canvas is finally loaded. It will not receive parameters, being "this" the <a href="CB_Canvas.html"><code>CB_Canvas</code></a> object itself.</p></td>
|
360 | </tr>
|
361 |
|
362 |
|
363 |
|
364 | <tr>
|
365 |
|
366 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onError</code></td>
|
367 |
|
368 |
|
369 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
370 |
|
371 |
|
372 | <span class="param-type">function</span>
|
373 |
|
374 |
|
375 |
|
376 |
|
377 | </td>
|
378 |
|
379 |
|
380 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
381 |
|
382 | <optional><br>
|
383 |
|
384 |
|
385 |
|
386 |
|
387 |
|
388 | </td>
|
389 |
|
390 |
|
391 |
|
392 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
393 |
|
394 | </td>
|
395 |
|
396 |
|
397 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback function that will be called when there is an error creating or loading the canvas. Being "this" the <a href="CB_Canvas.html"><code>CB_Canvas</code></a> object itself, the unique parameter received will be a string describing the error (if it could be determined).</p></td>
|
398 | </tr>
|
399 |
|
400 |
|
401 |
|
402 | <tr>
|
403 |
|
404 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasParent</code></td>
|
405 |
|
406 |
|
407 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
408 |
|
409 |
|
410 | <span class="param-type">Element</span>
|
411 |
|
412 |
|
413 |
|
414 |
|
415 | </td>
|
416 |
|
417 |
|
418 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
419 |
|
420 | <optional><br>
|
421 |
|
422 |
|
423 |
|
424 |
|
425 |
|
426 | </td>
|
427 |
|
428 |
|
429 |
|
430 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
431 |
|
432 | document.body
|
433 |
|
434 | </td>
|
435 |
|
436 |
|
437 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The parent element desired to adopt the canvas.</p></td>
|
438 | </tr>
|
439 |
|
440 |
|
441 |
|
442 | <tr>
|
443 |
|
444 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>alternativeCanvasEmulationPreferredOrder</code></td>
|
445 |
|
446 |
|
447 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
448 |
|
449 |
|
450 | <span class="param-type">array</span>
|
451 |
|
452 |
|
453 |
|
454 |
|
455 | </td>
|
456 |
|
457 |
|
458 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
459 |
|
460 | <optional><br>
|
461 |
|
462 |
|
463 |
|
464 |
|
465 |
|
466 | </td>
|
467 |
|
468 |
|
469 |
|
470 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
471 |
|
472 | <a href="CB_Configuration.CrossBase.html#.CB_Canvas_PREFERRED_EMULATION_METHODS"><code>CB_Configuration.CrossBase.CB_Canvas_PREFERRED_EMULATION_METHODS</code></a>
|
473 |
|
474 | </td>
|
475 |
|
476 |
|
477 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Numeric array listing the desired alternative emulation methods for rendering the canvas, in order of preference. Supported emulation methods: "FLASH", "VML", "DHTML" and "SILVERLIGHT".</p></td>
|
478 | </tr>
|
479 |
|
480 |
|
481 |
|
482 | <tr>
|
483 |
|
484 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>forceFirstEmulationMethod</code></td>
|
485 |
|
486 |
|
487 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
488 |
|
489 |
|
490 | <span class="param-type">boolean</span>
|
491 |
|
492 |
|
493 |
|
494 |
|
495 | </td>
|
496 |
|
497 |
|
498 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
499 |
|
500 | <optional><br>
|
501 |
|
502 |
|
503 |
|
504 |
|
505 |
|
506 | </td>
|
507 |
|
508 |
|
509 |
|
510 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
511 |
|
512 | false
|
513 |
|
514 | </td>
|
515 |
|
516 |
|
517 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, it will force to use the first alternative emulation method desired (even when this alternative emulation method could be not supported and even when native <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas">canvas</a> support could be supported).</p></td>
|
518 | </tr>
|
519 |
|
520 |
|
521 |
|
522 | <tr>
|
523 |
|
524 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>addOtherMethods</code></td>
|
525 |
|
526 |
|
527 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
528 |
|
529 |
|
530 | <span class="param-type">boolean</span>
|
531 |
|
532 |
|
533 |
|
534 |
|
535 | </td>
|
536 |
|
537 |
|
538 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
539 |
|
540 | <optional><br>
|
541 |
|
542 |
|
543 |
|
544 |
|
545 |
|
546 | </td>
|
547 |
|
548 |
|
549 |
|
550 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
551 |
|
552 | true
|
553 |
|
554 | </td>
|
555 |
|
556 |
|
557 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, it will add other alternative methods (if any is missing) at the end of the desired alternative emulation methods so they will also be checked and used if the previous ones are not finally used. The order they will be added will be the one used in the <a href="CB_Configuration.CrossBase.html#.CB_Canvas_PREFERRED_EMULATION_METHODS"><code>CB_Configuration.CrossBase.CB_Canvas_PREFERRED_EMULATION_METHODS</code></a> constant.</p></td>
|
558 | </tr>
|
559 |
|
560 |
|
561 |
|
562 | <tr>
|
563 |
|
564 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>allowFlashCanvasLocally</code></td>
|
565 |
|
566 |
|
567 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
568 |
|
569 |
|
570 | <span class="param-type">boolean</span>
|
571 |
|
572 |
|
573 |
|
574 |
|
575 | </td>
|
576 |
|
577 |
|
578 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
579 |
|
580 | <optional><br>
|
581 |
|
582 |
|
583 |
|
584 |
|
585 |
|
586 | </td>
|
587 |
|
588 |
|
589 |
|
590 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
591 |
|
592 | <a href="CB_Configuration.CrossBase.html#.FLASHCANVAS_ALLOW_RUN_LOCALLY_DEFAULT"><code>CB_Configuration.CrossBase.FLASHCANVAS_ALLOW_RUN_LOCALLY_DEFAULT</code></a>
|
593 |
|
594 | </td>
|
595 |
|
596 |
|
597 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, it will allow to use <a href="https://en.wikipedia.org/wiki/Adobe_Flash_Player">Adobe Flash (formerly Macromedia Flash)</a> emulation (if needed) even when it is running locally. Uses the <a href="CB_Client.html#.isRunningLocally"><code>CB_Client.isRunningLocally</code></a> function internally.</p></td>
|
598 | </tr>
|
599 |
|
600 |
|
601 | </tbody>
|
602 | </table>
|
603 |
|
604 |
|
605 |
|
606 |
|
607 | <dl class="details">
|
608 |
|
609 |
|
610 |
|
611 |
|
612 |
|
613 |
|
614 |
|
615 |
|
616 |
|
617 |
|
618 |
|
619 |
|
620 |
|
621 |
|
622 |
|
623 |
|
624 |
|
625 |
|
626 |
|
627 |
|
628 |
|
629 |
|
630 |
|
631 |
|
632 |
|
633 |
|
634 |
|
635 |
|
636 |
|
637 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
638 | <dd class="tag-source">
|
639 | <ul class="dummy">
|
640 | <li>
|
641 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
642 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-30">line 30</a>
|
643 | </li>
|
644 | </ul>
|
645 | </dd>
|
646 |
|
647 |
|
648 |
|
649 |
|
650 |
|
651 |
|
652 |
|
653 | </dl>
|
654 |
|
655 |
|
656 |
|
657 |
|
658 |
|
659 |
|
660 |
|
661 |
|
662 |
|
663 |
|
664 |
|
665 |
|
666 |
|
667 | <h5>Returns:</h5>
|
668 |
|
669 |
|
670 | <div class="param-desc">
|
671 | <p>Returns a new <a href="CB_Canvas.html"><code>CB_Canvas</code></a> object.</p>
|
672 | </div>
|
673 |
|
674 |
|
675 |
|
676 | <dl>
|
677 | <dt>
|
678 | Type
|
679 | </dt>
|
680 | <dd>
|
681 |
|
682 | <span class="param-type"><a href="CB_Canvas.html">CB_Canvas</a></span>
|
683 |
|
684 |
|
685 |
|
686 | </dd>
|
687 | </dl>
|
688 |
|
689 |
|
690 |
|
691 |
|
692 |
|
693 | </dd>
|
694 |
|
695 |
|
696 | </div>
|
697 |
|
698 |
|
699 |
|
700 |
|
701 |
|
702 |
|
703 |
|
704 |
|
705 |
|
706 |
|
707 |
|
708 |
|
709 | <h3 class="subsection-title">Members</h3>
|
710 |
|
711 | <dl>
|
712 |
|
713 | <hr>
|
714 | <dt class="name" id=".HEIGHT_DEFAULT">
|
715 | <h4 id=".HEIGHT_DEFAULT"><span class="type-signature"><static, constant> </span>HEIGHT_DEFAULT<span class="type-signature"> :integer</span></h4>
|
716 |
|
717 |
|
718 | </dt>
|
719 | <dd>
|
720 |
|
721 | <div class="description">
|
722 | <p>Default canvas height in pixels.</p>
|
723 | </div>
|
724 |
|
725 |
|
726 |
|
727 | <h5>Type:</h5>
|
728 | <ul>
|
729 | <li>
|
730 |
|
731 | <span class="param-type">integer</span>
|
732 |
|
733 |
|
734 |
|
735 | </li>
|
736 | </ul>
|
737 |
|
738 |
|
739 |
|
740 | <dl class="details">
|
741 |
|
742 |
|
743 |
|
744 |
|
745 |
|
746 |
|
747 |
|
748 |
|
749 |
|
750 |
|
751 |
|
752 |
|
753 |
|
754 |
|
755 |
|
756 |
|
757 |
|
758 |
|
759 |
|
760 |
|
761 |
|
762 |
|
763 |
|
764 |
|
765 |
|
766 | <dt class="tag-default method-doc-label method-doc-details-label">Default Value:</dt>
|
767 | <dd class="tag-default">
|
768 | <ul class="dummy">
|
769 | <li>240</li>
|
770 | </ul>
|
771 | </dd>
|
772 |
|
773 |
|
774 |
|
775 |
|
776 |
|
777 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
778 | <dd class="tag-source">
|
779 | <ul class="dummy">
|
780 | <li>
|
781 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
782 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-81">line 81</a>
|
783 | </li>
|
784 | </ul>
|
785 | </dd>
|
786 |
|
787 |
|
788 |
|
789 |
|
790 |
|
791 |
|
792 |
|
793 | </dl>
|
794 |
|
795 |
|
796 |
|
797 | </dd>
|
798 |
|
799 |
|
800 |
|
801 | <hr>
|
802 | <dt class="name" id=".WIDTH_DEFAULT">
|
803 | <h4 id=".WIDTH_DEFAULT"><span class="type-signature"><static, constant> </span>WIDTH_DEFAULT<span class="type-signature"> :integer</span></h4>
|
804 |
|
805 |
|
806 | </dt>
|
807 | <dd>
|
808 |
|
809 | <div class="description">
|
810 | <p>Default canvas width in pixels.</p>
|
811 | </div>
|
812 |
|
813 |
|
814 |
|
815 | <h5>Type:</h5>
|
816 | <ul>
|
817 | <li>
|
818 |
|
819 | <span class="param-type">integer</span>
|
820 |
|
821 |
|
822 |
|
823 | </li>
|
824 | </ul>
|
825 |
|
826 |
|
827 |
|
828 | <dl class="details">
|
829 |
|
830 |
|
831 |
|
832 |
|
833 |
|
834 |
|
835 |
|
836 |
|
837 |
|
838 |
|
839 |
|
840 |
|
841 |
|
842 |
|
843 |
|
844 |
|
845 |
|
846 |
|
847 |
|
848 |
|
849 |
|
850 |
|
851 |
|
852 |
|
853 |
|
854 | <dt class="tag-default method-doc-label method-doc-details-label">Default Value:</dt>
|
855 | <dd class="tag-default">
|
856 | <ul class="dummy">
|
857 | <li>320</li>
|
858 | </ul>
|
859 | </dd>
|
860 |
|
861 |
|
862 |
|
863 |
|
864 |
|
865 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
866 | <dd class="tag-source">
|
867 | <ul class="dummy">
|
868 | <li>
|
869 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
870 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-74">line 74</a>
|
871 | </li>
|
872 | </ul>
|
873 | </dd>
|
874 |
|
875 |
|
876 |
|
877 |
|
878 |
|
879 |
|
880 |
|
881 | </dl>
|
882 |
|
883 |
|
884 |
|
885 | </dd>
|
886 |
|
887 | </dl>
|
888 |
|
889 |
|
890 |
|
891 | <h3 class="subsection-title">Methods</h3>
|
892 |
|
893 | <dl>
|
894 |
|
895 | <hr>
|
896 | <dt>
|
897 | <h4 class="name" id="clear"><span class="type-signature"></span>clear<span class="signature">( [keepTransform] [, backgroundFillStyle])</span><span class="type-signature"> → {boolean}</span></h4>
|
898 |
|
899 |
|
900 | </dt>
|
901 | <dd>
|
902 |
|
903 |
|
904 | <div class="description">
|
905 | <p>Clear the canvas entirely.</p>
|
906 | </div>
|
907 |
|
908 |
|
909 |
|
910 |
|
911 |
|
912 |
|
913 |
|
914 |
|
915 | <h5>Parameters:</h5>
|
916 |
|
917 |
|
918 | <table class="params table table-striped">
|
919 | <thead>
|
920 | <tr>
|
921 |
|
922 | <th style="width:12%; min-width:110px;">Name</th>
|
923 |
|
924 |
|
925 | <th style="width:12%; min-width:110px;">Type</th>
|
926 |
|
927 |
|
928 | <th style="width:12%; min-width:110px;">Argument</th>
|
929 |
|
930 |
|
931 |
|
932 | <th style="width:12%; min-width:110px;">Default</th>
|
933 |
|
934 |
|
935 | <th class="last" style="min-width:310px;">Description</th>
|
936 | </tr>
|
937 | </thead>
|
938 |
|
939 | <tbody>
|
940 |
|
941 |
|
942 | <tr>
|
943 |
|
944 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>keepTransform</code></td>
|
945 |
|
946 |
|
947 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
948 |
|
949 |
|
950 | <span class="param-type">boolean</span>
|
951 |
|
952 |
|
953 |
|
954 |
|
955 | </td>
|
956 |
|
957 |
|
958 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
959 |
|
960 | <optional><br>
|
961 |
|
962 |
|
963 |
|
964 |
|
965 |
|
966 | </td>
|
967 |
|
968 |
|
969 |
|
970 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
971 |
|
972 | false
|
973 |
|
974 | </td>
|
975 |
|
976 |
|
977 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, it will <a href="https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/save">save</a> and <a href="https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/restore">restore</a> the current transformation.</p></td>
|
978 | </tr>
|
979 |
|
980 |
|
981 |
|
982 | <tr>
|
983 |
|
984 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>backgroundFillStyle</code></td>
|
985 |
|
986 |
|
987 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
988 |
|
989 |
|
990 | <span class="param-type">string</span>
|
991 |
|
992 |
|
993 |
|
994 |
|
995 | </td>
|
996 |
|
997 |
|
998 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
999 |
|
1000 | <optional><br>
|
1001 |
|
1002 |
|
1003 |
|
1004 |
|
1005 |
|
1006 | </td>
|
1007 |
|
1008 |
|
1009 |
|
1010 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1011 |
|
1012 | </td>
|
1013 |
|
1014 |
|
1015 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The style used (color, gradient, pattern...) to fill the canvas background. If defined, it will be used as the value for the <a href="https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/fillStyle">fillStyle</a> property of the <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> object, internally.</p></td>
|
1016 | </tr>
|
1017 |
|
1018 |
|
1019 | </tbody>
|
1020 | </table>
|
1021 |
|
1022 |
|
1023 |
|
1024 |
|
1025 | <dl class="details">
|
1026 |
|
1027 |
|
1028 |
|
1029 |
|
1030 |
|
1031 |
|
1032 |
|
1033 |
|
1034 |
|
1035 |
|
1036 |
|
1037 |
|
1038 |
|
1039 |
|
1040 |
|
1041 |
|
1042 |
|
1043 |
|
1044 |
|
1045 |
|
1046 |
|
1047 |
|
1048 |
|
1049 |
|
1050 |
|
1051 |
|
1052 |
|
1053 |
|
1054 |
|
1055 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1056 | <dd class="tag-source">
|
1057 | <ul class="dummy">
|
1058 | <li>
|
1059 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
1060 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-840">line 840</a>
|
1061 | </li>
|
1062 | </ul>
|
1063 | </dd>
|
1064 |
|
1065 |
|
1066 |
|
1067 |
|
1068 |
|
1069 |
|
1070 |
|
1071 | </dl>
|
1072 |
|
1073 |
|
1074 |
|
1075 |
|
1076 |
|
1077 |
|
1078 |
|
1079 |
|
1080 |
|
1081 |
|
1082 |
|
1083 |
|
1084 |
|
1085 | <h5>Returns:</h5>
|
1086 |
|
1087 |
|
1088 | <div class="param-desc">
|
1089 | <p>Returns true if the action could be performed or false otherwise.</p>
|
1090 | </div>
|
1091 |
|
1092 |
|
1093 |
|
1094 | <dl>
|
1095 | <dt>
|
1096 | Type
|
1097 | </dt>
|
1098 | <dd>
|
1099 |
|
1100 | <span class="param-type">boolean</span>
|
1101 |
|
1102 |
|
1103 |
|
1104 | </dd>
|
1105 | </dl>
|
1106 |
|
1107 |
|
1108 |
|
1109 |
|
1110 |
|
1111 | </dd>
|
1112 |
|
1113 |
|
1114 |
|
1115 | <hr>
|
1116 | <dt>
|
1117 | <h4 class="name" id="clearCanvas"><span class="type-signature"></span>clearCanvas<span class="signature">()</span><span class="type-signature"></span></h4>
|
1118 |
|
1119 |
|
1120 | </dt>
|
1121 | <dd>
|
1122 |
|
1123 |
|
1124 | <div class="description">
|
1125 | <p>Alias for <a href="CB_Canvas.html#clear"><code>CB_Canvas#clear</code></a>.</p>
|
1126 | </div>
|
1127 |
|
1128 |
|
1129 |
|
1130 |
|
1131 |
|
1132 |
|
1133 |
|
1134 |
|
1135 |
|
1136 |
|
1137 | <dl class="details">
|
1138 |
|
1139 |
|
1140 |
|
1141 |
|
1142 |
|
1143 |
|
1144 |
|
1145 |
|
1146 |
|
1147 |
|
1148 |
|
1149 |
|
1150 |
|
1151 |
|
1152 |
|
1153 |
|
1154 |
|
1155 |
|
1156 |
|
1157 |
|
1158 |
|
1159 |
|
1160 |
|
1161 |
|
1162 |
|
1163 |
|
1164 |
|
1165 |
|
1166 |
|
1167 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1168 | <dd class="tag-source">
|
1169 | <ul class="dummy">
|
1170 | <li>
|
1171 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
1172 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-828">line 828</a>
|
1173 | </li>
|
1174 | </ul>
|
1175 | </dd>
|
1176 |
|
1177 |
|
1178 |
|
1179 |
|
1180 |
|
1181 | <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
|
1182 | <dd class="tag-see">
|
1183 | <ul>
|
1184 | <li><a href="CB_Canvas.html#clear"><code>CB_Canvas#clear</code></a></li>
|
1185 | </ul>
|
1186 | </dd>
|
1187 |
|
1188 |
|
1189 |
|
1190 | </dl>
|
1191 |
|
1192 |
|
1193 |
|
1194 |
|
1195 |
|
1196 |
|
1197 |
|
1198 |
|
1199 |
|
1200 |
|
1201 |
|
1202 |
|
1203 |
|
1204 |
|
1205 |
|
1206 | </dd>
|
1207 |
|
1208 |
|
1209 |
|
1210 | <hr>
|
1211 | <dt>
|
1212 | <h4 class="name" id="disableAntiAliasing"><span class="type-signature"></span>disableAntiAliasing<span class="signature">( [performTranslate])</span><span class="type-signature"> → {boolean}</span></h4>
|
1213 |
|
1214 |
|
1215 | </dt>
|
1216 | <dd>
|
1217 |
|
1218 |
|
1219 | <div class="description">
|
1220 | <p>Disables anti-aliasing. Useful to work with image sprites (to avoid problems showing adjacent ones), for example.</p>
|
1221 | </div>
|
1222 |
|
1223 |
|
1224 |
|
1225 |
|
1226 |
|
1227 |
|
1228 |
|
1229 |
|
1230 | <h5>Parameters:</h5>
|
1231 |
|
1232 |
|
1233 | <table class="params table table-striped">
|
1234 | <thead>
|
1235 | <tr>
|
1236 |
|
1237 | <th style="width:12%; min-width:110px;">Name</th>
|
1238 |
|
1239 |
|
1240 | <th style="width:12%; min-width:110px;">Type</th>
|
1241 |
|
1242 |
|
1243 | <th style="width:12%; min-width:110px;">Argument</th>
|
1244 |
|
1245 |
|
1246 |
|
1247 | <th style="width:12%; min-width:110px;">Default</th>
|
1248 |
|
1249 |
|
1250 | <th class="last" style="min-width:310px;">Description</th>
|
1251 | </tr>
|
1252 | </thead>
|
1253 |
|
1254 | <tbody>
|
1255 |
|
1256 |
|
1257 | <tr>
|
1258 |
|
1259 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>performTranslate</code></td>
|
1260 |
|
1261 |
|
1262 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1263 |
|
1264 |
|
1265 | <span class="param-type">boolean</span>
|
1266 |
|
1267 |
|
1268 |
|
1269 |
|
1270 | </td>
|
1271 |
|
1272 |
|
1273 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1274 |
|
1275 | <optional><br>
|
1276 |
|
1277 |
|
1278 |
|
1279 |
|
1280 |
|
1281 | </td>
|
1282 |
|
1283 |
|
1284 |
|
1285 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1286 |
|
1287 | false
|
1288 |
|
1289 | </td>
|
1290 |
|
1291 |
|
1292 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, it will also call the <a href="https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/transform">transform</a> method.</p></td>
|
1293 | </tr>
|
1294 |
|
1295 |
|
1296 | </tbody>
|
1297 | </table>
|
1298 |
|
1299 |
|
1300 |
|
1301 |
|
1302 | <dl class="details">
|
1303 |
|
1304 |
|
1305 |
|
1306 |
|
1307 |
|
1308 |
|
1309 |
|
1310 |
|
1311 |
|
1312 |
|
1313 |
|
1314 |
|
1315 |
|
1316 |
|
1317 |
|
1318 |
|
1319 |
|
1320 |
|
1321 |
|
1322 |
|
1323 |
|
1324 |
|
1325 |
|
1326 |
|
1327 |
|
1328 |
|
1329 |
|
1330 |
|
1331 |
|
1332 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1333 | <dd class="tag-source">
|
1334 | <ul class="dummy">
|
1335 | <li>
|
1336 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
1337 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-889">line 889</a>
|
1338 | </li>
|
1339 | </ul>
|
1340 | </dd>
|
1341 |
|
1342 |
|
1343 |
|
1344 |
|
1345 |
|
1346 |
|
1347 |
|
1348 | </dl>
|
1349 |
|
1350 |
|
1351 |
|
1352 |
|
1353 |
|
1354 |
|
1355 |
|
1356 |
|
1357 |
|
1358 |
|
1359 |
|
1360 |
|
1361 |
|
1362 | <h5>Returns:</h5>
|
1363 |
|
1364 |
|
1365 | <div class="param-desc">
|
1366 | <p>Returns true if the action could be performed or false otherwise.</p>
|
1367 | </div>
|
1368 |
|
1369 |
|
1370 |
|
1371 | <dl>
|
1372 | <dt>
|
1373 | Type
|
1374 | </dt>
|
1375 | <dd>
|
1376 |
|
1377 | <span class="param-type">boolean</span>
|
1378 |
|
1379 |
|
1380 |
|
1381 | </dd>
|
1382 | </dl>
|
1383 |
|
1384 |
|
1385 |
|
1386 |
|
1387 |
|
1388 | </dd>
|
1389 |
|
1390 |
|
1391 |
|
1392 | <hr>
|
1393 | <dt>
|
1394 | <h4 class="name" id="get"><span class="type-signature"></span>get<span class="signature">()</span><span class="type-signature"> → {Element|null}</span></h4>
|
1395 |
|
1396 |
|
1397 | </dt>
|
1398 | <dd>
|
1399 |
|
1400 |
|
1401 | <div class="description">
|
1402 | <p>Returns the canvas element (if any).</p>
|
1403 | </div>
|
1404 |
|
1405 |
|
1406 |
|
1407 |
|
1408 |
|
1409 |
|
1410 |
|
1411 |
|
1412 |
|
1413 |
|
1414 | <dl class="details">
|
1415 |
|
1416 |
|
1417 |
|
1418 |
|
1419 |
|
1420 |
|
1421 |
|
1422 |
|
1423 |
|
1424 |
|
1425 |
|
1426 |
|
1427 |
|
1428 |
|
1429 |
|
1430 |
|
1431 |
|
1432 |
|
1433 |
|
1434 |
|
1435 |
|
1436 |
|
1437 |
|
1438 |
|
1439 |
|
1440 |
|
1441 |
|
1442 |
|
1443 |
|
1444 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1445 | <dd class="tag-source">
|
1446 | <ul class="dummy">
|
1447 | <li>
|
1448 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
1449 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-602">line 602</a>
|
1450 | </li>
|
1451 | </ul>
|
1452 | </dd>
|
1453 |
|
1454 |
|
1455 |
|
1456 |
|
1457 |
|
1458 |
|
1459 |
|
1460 | </dl>
|
1461 |
|
1462 |
|
1463 |
|
1464 |
|
1465 |
|
1466 |
|
1467 |
|
1468 |
|
1469 |
|
1470 |
|
1471 |
|
1472 |
|
1473 |
|
1474 | <h5>Returns:</h5>
|
1475 |
|
1476 |
|
1477 | <div class="param-desc">
|
1478 | <p>Returns the canvas element (if any). If not found, null will be returned.</p>
|
1479 | </div>
|
1480 |
|
1481 |
|
1482 |
|
1483 | <dl>
|
1484 | <dt>
|
1485 | Type
|
1486 | </dt>
|
1487 | <dd>
|
1488 |
|
1489 | <span class="param-type">Element</span>
|
1490 | |
|
1491 |
|
1492 | <span class="param-type">null</span>
|
1493 |
|
1494 |
|
1495 |
|
1496 | </dd>
|
1497 | </dl>
|
1498 |
|
1499 |
|
1500 |
|
1501 |
|
1502 |
|
1503 | </dd>
|
1504 |
|
1505 |
|
1506 |
|
1507 | <hr>
|
1508 | <dt>
|
1509 | <h4 class="name" id="getContext"><span class="type-signature"></span>getContext<span class="signature">( [contextType])</span><span class="type-signature"> → {RenderingContext|Object}</span></h4>
|
1510 |
|
1511 |
|
1512 | </dt>
|
1513 | <dd>
|
1514 |
|
1515 |
|
1516 | <div class="description">
|
1517 | <p>Defines and returns the canvas <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a>. It could call the <a href="CB_Canvas.html#prepareContext"><code>CB_Canvas#prepareContext</code></a> method internally.</p>
|
1518 | </div>
|
1519 |
|
1520 |
|
1521 |
|
1522 |
|
1523 |
|
1524 |
|
1525 |
|
1526 |
|
1527 | <h5>Parameters:</h5>
|
1528 |
|
1529 |
|
1530 | <table class="params table table-striped">
|
1531 | <thead>
|
1532 | <tr>
|
1533 |
|
1534 | <th style="width:12%; min-width:110px;">Name</th>
|
1535 |
|
1536 |
|
1537 | <th style="width:12%; min-width:110px;">Type</th>
|
1538 |
|
1539 |
|
1540 | <th style="width:12%; min-width:110px;">Argument</th>
|
1541 |
|
1542 |
|
1543 |
|
1544 | <th style="width:12%; min-width:110px;">Default</th>
|
1545 |
|
1546 |
|
1547 | <th class="last" style="min-width:310px;">Description</th>
|
1548 | </tr>
|
1549 | </thead>
|
1550 |
|
1551 | <tbody>
|
1552 |
|
1553 |
|
1554 | <tr>
|
1555 |
|
1556 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>contextType</code></td>
|
1557 |
|
1558 |
|
1559 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1560 |
|
1561 |
|
1562 | <span class="param-type">'2d'</span>
|
1563 | |
|
1564 |
|
1565 | <span class="param-type">'webgl'</span>
|
1566 | |
|
1567 |
|
1568 | <span class="param-type">'experimental-webgl'</span>
|
1569 | |
|
1570 |
|
1571 | <span class="param-type">'webgl2'</span>
|
1572 | |
|
1573 |
|
1574 | <span class="param-type">'experimental-webgl2'</span>
|
1575 | |
|
1576 |
|
1577 | <span class="param-type">'bitmaprenderer'</span>
|
1578 |
|
1579 |
|
1580 |
|
1581 |
|
1582 | </td>
|
1583 |
|
1584 |
|
1585 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1586 |
|
1587 | <optional><br>
|
1588 |
|
1589 |
|
1590 |
|
1591 |
|
1592 |
|
1593 | </td>
|
1594 |
|
1595 |
|
1596 |
|
1597 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
1598 |
|
1599 | CB_Canvas#._contextType|'2d'
|
1600 |
|
1601 | </td>
|
1602 |
|
1603 |
|
1604 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> type desired. More information: <a href="https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/getContext">HTMLCanvasElement.getContext</a>. Note that most emulation methods will only support "2d".</p></td>
|
1605 | </tr>
|
1606 |
|
1607 |
|
1608 | </tbody>
|
1609 | </table>
|
1610 |
|
1611 |
|
1612 |
|
1613 |
|
1614 | <dl class="details">
|
1615 |
|
1616 |
|
1617 |
|
1618 |
|
1619 |
|
1620 |
|
1621 |
|
1622 |
|
1623 |
|
1624 |
|
1625 |
|
1626 |
|
1627 |
|
1628 |
|
1629 |
|
1630 |
|
1631 |
|
1632 |
|
1633 |
|
1634 |
|
1635 |
|
1636 |
|
1637 |
|
1638 |
|
1639 |
|
1640 |
|
1641 |
|
1642 |
|
1643 |
|
1644 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1645 | <dd class="tag-source">
|
1646 | <ul class="dummy">
|
1647 | <li>
|
1648 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
1649 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-614">line 614</a>
|
1650 | </li>
|
1651 | </ul>
|
1652 | </dd>
|
1653 |
|
1654 |
|
1655 |
|
1656 |
|
1657 |
|
1658 |
|
1659 |
|
1660 | </dl>
|
1661 |
|
1662 |
|
1663 |
|
1664 |
|
1665 |
|
1666 |
|
1667 |
|
1668 |
|
1669 |
|
1670 |
|
1671 |
|
1672 |
|
1673 |
|
1674 | <h5>Returns:</h5>
|
1675 |
|
1676 |
|
1677 | <div class="param-desc">
|
1678 | <p>Returns the canvas <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> (different type if a canvas emulation method is being used).</p>
|
1679 | </div>
|
1680 |
|
1681 |
|
1682 |
|
1683 | <dl>
|
1684 | <dt>
|
1685 | Type
|
1686 | </dt>
|
1687 | <dd>
|
1688 |
|
1689 | <span class="param-type">RenderingContext</span>
|
1690 | |
|
1691 |
|
1692 | <span class="param-type">Object</span>
|
1693 |
|
1694 |
|
1695 |
|
1696 | </dd>
|
1697 | </dl>
|
1698 |
|
1699 |
|
1700 |
|
1701 |
|
1702 |
|
1703 | </dd>
|
1704 |
|
1705 |
|
1706 |
|
1707 | <hr>
|
1708 | <dt>
|
1709 | <h4 class="name" id="getContextType"><span class="type-signature"></span>getContextType<span class="signature">()</span><span class="type-signature"> → {string}</span></h4>
|
1710 |
|
1711 |
|
1712 | </dt>
|
1713 | <dd>
|
1714 |
|
1715 |
|
1716 | <div class="description">
|
1717 | <p>Tells the current canvas <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> type used. Internally, it returns the value of the <code>CB_Canvas#._contextType</code> property.</p>
|
1718 | </div>
|
1719 |
|
1720 |
|
1721 |
|
1722 |
|
1723 |
|
1724 |
|
1725 |
|
1726 |
|
1727 |
|
1728 |
|
1729 | <dl class="details">
|
1730 |
|
1731 |
|
1732 |
|
1733 |
|
1734 |
|
1735 |
|
1736 |
|
1737 |
|
1738 |
|
1739 |
|
1740 |
|
1741 |
|
1742 |
|
1743 |
|
1744 |
|
1745 |
|
1746 |
|
1747 |
|
1748 |
|
1749 |
|
1750 |
|
1751 |
|
1752 |
|
1753 |
|
1754 |
|
1755 |
|
1756 |
|
1757 |
|
1758 |
|
1759 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1760 | <dd class="tag-source">
|
1761 | <ul class="dummy">
|
1762 | <li>
|
1763 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
1764 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-668">line 668</a>
|
1765 | </li>
|
1766 | </ul>
|
1767 | </dd>
|
1768 |
|
1769 |
|
1770 |
|
1771 |
|
1772 |
|
1773 |
|
1774 |
|
1775 | </dl>
|
1776 |
|
1777 |
|
1778 |
|
1779 |
|
1780 |
|
1781 |
|
1782 |
|
1783 |
|
1784 |
|
1785 |
|
1786 |
|
1787 |
|
1788 |
|
1789 | <h5>Returns:</h5>
|
1790 |
|
1791 |
|
1792 | <div class="param-desc">
|
1793 | <p>Tells the current canvas <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> type used. More information: <a href="https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/getContext">HTMLCanvasElement.getContext</a>.</p>
|
1794 | </div>
|
1795 |
|
1796 |
|
1797 |
|
1798 | <dl>
|
1799 | <dt>
|
1800 | Type
|
1801 | </dt>
|
1802 | <dd>
|
1803 |
|
1804 | <span class="param-type">string</span>
|
1805 |
|
1806 |
|
1807 |
|
1808 | </dd>
|
1809 | </dl>
|
1810 |
|
1811 |
|
1812 |
|
1813 |
|
1814 |
|
1815 | </dd>
|
1816 |
|
1817 |
|
1818 |
|
1819 | <hr>
|
1820 | <dt>
|
1821 | <h4 class="name" id="getHeight"><span class="type-signature"></span>getHeight<span class="signature">()</span><span class="type-signature"> → {number}</span></h4>
|
1822 |
|
1823 |
|
1824 | </dt>
|
1825 | <dd>
|
1826 |
|
1827 |
|
1828 | <div class="description">
|
1829 | <p>Tells the canvas height (vertical size) being used in pixels.</p>
|
1830 | </div>
|
1831 |
|
1832 |
|
1833 |
|
1834 |
|
1835 |
|
1836 |
|
1837 |
|
1838 |
|
1839 |
|
1840 |
|
1841 | <dl class="details">
|
1842 |
|
1843 |
|
1844 |
|
1845 |
|
1846 |
|
1847 |
|
1848 |
|
1849 |
|
1850 |
|
1851 |
|
1852 |
|
1853 |
|
1854 |
|
1855 |
|
1856 |
|
1857 |
|
1858 |
|
1859 |
|
1860 |
|
1861 |
|
1862 |
|
1863 |
|
1864 |
|
1865 |
|
1866 |
|
1867 |
|
1868 |
|
1869 |
|
1870 |
|
1871 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1872 | <dd class="tag-source">
|
1873 | <ul class="dummy">
|
1874 | <li>
|
1875 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
1876 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-789">line 789</a>
|
1877 | </li>
|
1878 | </ul>
|
1879 | </dd>
|
1880 |
|
1881 |
|
1882 |
|
1883 |
|
1884 |
|
1885 |
|
1886 |
|
1887 | </dl>
|
1888 |
|
1889 |
|
1890 |
|
1891 |
|
1892 |
|
1893 |
|
1894 |
|
1895 |
|
1896 |
|
1897 |
|
1898 |
|
1899 |
|
1900 |
|
1901 | <h5>Returns:</h5>
|
1902 |
|
1903 |
|
1904 | <div class="param-desc">
|
1905 | <p>Returns the canvas height (vertical size) being used in pixels. It could return zero (0) if cannot be calculated.</p>
|
1906 | </div>
|
1907 |
|
1908 |
|
1909 |
|
1910 | <dl>
|
1911 | <dt>
|
1912 | Type
|
1913 | </dt>
|
1914 | <dd>
|
1915 |
|
1916 | <span class="param-type">number</span>
|
1917 |
|
1918 |
|
1919 |
|
1920 | </dd>
|
1921 | </dl>
|
1922 |
|
1923 |
|
1924 |
|
1925 |
|
1926 |
|
1927 | </dd>
|
1928 |
|
1929 |
|
1930 |
|
1931 | <hr>
|
1932 | <dt>
|
1933 | <h4 class="name" id="getId"><span class="type-signature"></span>getId<span class="signature">()</span><span class="type-signature"> → {string}</span></h4>
|
1934 |
|
1935 |
|
1936 | </dt>
|
1937 | <dd>
|
1938 |
|
1939 |
|
1940 | <div class="description">
|
1941 | <p>Returns the identifier (ID) of the canvas element.</p>
|
1942 | </div>
|
1943 |
|
1944 |
|
1945 |
|
1946 |
|
1947 |
|
1948 |
|
1949 |
|
1950 |
|
1951 |
|
1952 |
|
1953 | <dl class="details">
|
1954 |
|
1955 |
|
1956 |
|
1957 |
|
1958 |
|
1959 |
|
1960 |
|
1961 |
|
1962 |
|
1963 |
|
1964 |
|
1965 |
|
1966 |
|
1967 |
|
1968 |
|
1969 |
|
1970 |
|
1971 |
|
1972 |
|
1973 |
|
1974 |
|
1975 |
|
1976 |
|
1977 |
|
1978 |
|
1979 |
|
1980 |
|
1981 |
|
1982 |
|
1983 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
1984 | <dd class="tag-source">
|
1985 | <ul class="dummy">
|
1986 | <li>
|
1987 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
1988 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-319">line 319</a>
|
1989 | </li>
|
1990 | </ul>
|
1991 | </dd>
|
1992 |
|
1993 |
|
1994 |
|
1995 |
|
1996 |
|
1997 |
|
1998 |
|
1999 | </dl>
|
2000 |
|
2001 |
|
2002 |
|
2003 |
|
2004 |
|
2005 |
|
2006 |
|
2007 |
|
2008 |
|
2009 |
|
2010 |
|
2011 |
|
2012 |
|
2013 | <h5>Returns:</h5>
|
2014 |
|
2015 |
|
2016 | <div class="param-desc">
|
2017 | <p>Returns the identifier (ID) of the canvas element.</p>
|
2018 | </div>
|
2019 |
|
2020 |
|
2021 |
|
2022 | <dl>
|
2023 | <dt>
|
2024 | Type
|
2025 | </dt>
|
2026 | <dd>
|
2027 |
|
2028 | <span class="param-type">string</span>
|
2029 |
|
2030 |
|
2031 |
|
2032 | </dd>
|
2033 | </dl>
|
2034 |
|
2035 |
|
2036 |
|
2037 |
|
2038 |
|
2039 | </dd>
|
2040 |
|
2041 |
|
2042 |
|
2043 | <hr>
|
2044 | <dt>
|
2045 | <h4 class="name" id="getMode"><span class="type-signature"></span>getMode<span class="signature">()</span><span class="type-signature"> → {'NONE'|'NORMAL'|'FLASH'|'SILVERLIGHT'|'VML'|'DHTML'}</span></h4>
|
2046 |
|
2047 |
|
2048 | </dt>
|
2049 | <dd>
|
2050 |
|
2051 |
|
2052 | <div class="description">
|
2053 | <p>Tells the mode used to create the canvas.</p>
|
2054 | </div>
|
2055 |
|
2056 |
|
2057 |
|
2058 |
|
2059 |
|
2060 |
|
2061 |
|
2062 |
|
2063 |
|
2064 |
|
2065 | <dl class="details">
|
2066 |
|
2067 |
|
2068 |
|
2069 |
|
2070 |
|
2071 |
|
2072 |
|
2073 |
|
2074 |
|
2075 |
|
2076 |
|
2077 |
|
2078 |
|
2079 |
|
2080 |
|
2081 |
|
2082 |
|
2083 |
|
2084 |
|
2085 |
|
2086 |
|
2087 |
|
2088 |
|
2089 |
|
2090 |
|
2091 |
|
2092 |
|
2093 |
|
2094 |
|
2095 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2096 | <dd class="tag-source">
|
2097 | <ul class="dummy">
|
2098 | <li>
|
2099 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
2100 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-800">line 800</a>
|
2101 | </li>
|
2102 | </ul>
|
2103 | </dd>
|
2104 |
|
2105 |
|
2106 |
|
2107 |
|
2108 |
|
2109 |
|
2110 |
|
2111 | </dl>
|
2112 |
|
2113 |
|
2114 |
|
2115 |
|
2116 |
|
2117 |
|
2118 |
|
2119 |
|
2120 |
|
2121 |
|
2122 |
|
2123 |
|
2124 |
|
2125 | <h5>Returns:</h5>
|
2126 |
|
2127 |
|
2128 | <div class="param-desc">
|
2129 | <p>Returns the mode used to create the canvas. Returns "NONE" if no method is used yet (possible when no method is supported at all or when it is still loading). Returns "NORMAL" if native <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas">canvas</a> is used (no canvas emulation method).</p>
|
2130 | </div>
|
2131 |
|
2132 |
|
2133 |
|
2134 | <dl>
|
2135 | <dt>
|
2136 | Type
|
2137 | </dt>
|
2138 | <dd>
|
2139 |
|
2140 | <span class="param-type">'NONE'</span>
|
2141 | |
|
2142 |
|
2143 | <span class="param-type">'NORMAL'</span>
|
2144 | |
|
2145 |
|
2146 | <span class="param-type">'FLASH'</span>
|
2147 | |
|
2148 |
|
2149 | <span class="param-type">'SILVERLIGHT'</span>
|
2150 | |
|
2151 |
|
2152 | <span class="param-type">'VML'</span>
|
2153 | |
|
2154 |
|
2155 | <span class="param-type">'DHTML'</span>
|
2156 |
|
2157 |
|
2158 |
|
2159 | </dd>
|
2160 | </dl>
|
2161 |
|
2162 |
|
2163 |
|
2164 |
|
2165 |
|
2166 | </dd>
|
2167 |
|
2168 |
|
2169 |
|
2170 | <hr>
|
2171 | <dt>
|
2172 | <h4 class="name" id="getWidth"><span class="type-signature"></span>getWidth<span class="signature">()</span><span class="type-signature"> → {number}</span></h4>
|
2173 |
|
2174 |
|
2175 | </dt>
|
2176 | <dd>
|
2177 |
|
2178 |
|
2179 | <div class="description">
|
2180 | <p>Tells the canvas width (horizontal size) being used in pixels.</p>
|
2181 | </div>
|
2182 |
|
2183 |
|
2184 |
|
2185 |
|
2186 |
|
2187 |
|
2188 |
|
2189 |
|
2190 |
|
2191 |
|
2192 | <dl class="details">
|
2193 |
|
2194 |
|
2195 |
|
2196 |
|
2197 |
|
2198 |
|
2199 |
|
2200 |
|
2201 |
|
2202 |
|
2203 |
|
2204 |
|
2205 |
|
2206 |
|
2207 |
|
2208 |
|
2209 |
|
2210 |
|
2211 |
|
2212 |
|
2213 |
|
2214 |
|
2215 |
|
2216 |
|
2217 |
|
2218 |
|
2219 |
|
2220 |
|
2221 |
|
2222 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2223 | <dd class="tag-source">
|
2224 | <ul class="dummy">
|
2225 | <li>
|
2226 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
2227 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-739">line 739</a>
|
2228 | </li>
|
2229 | </ul>
|
2230 | </dd>
|
2231 |
|
2232 |
|
2233 |
|
2234 |
|
2235 |
|
2236 |
|
2237 |
|
2238 | </dl>
|
2239 |
|
2240 |
|
2241 |
|
2242 |
|
2243 |
|
2244 |
|
2245 |
|
2246 |
|
2247 |
|
2248 |
|
2249 |
|
2250 |
|
2251 |
|
2252 | <h5>Returns:</h5>
|
2253 |
|
2254 |
|
2255 | <div class="param-desc">
|
2256 | <p>Returns the canvas width (horizontal size) being used in pixels. It could return zero (0) if cannot be calculated.</p>
|
2257 | </div>
|
2258 |
|
2259 |
|
2260 |
|
2261 | <dl>
|
2262 | <dt>
|
2263 | Type
|
2264 | </dt>
|
2265 | <dd>
|
2266 |
|
2267 | <span class="param-type">number</span>
|
2268 |
|
2269 |
|
2270 |
|
2271 | </dd>
|
2272 | </dl>
|
2273 |
|
2274 |
|
2275 |
|
2276 |
|
2277 |
|
2278 | </dd>
|
2279 |
|
2280 |
|
2281 |
|
2282 | <hr>
|
2283 | <dt>
|
2284 | <h4 class="name" id="isLoading"><span class="type-signature"></span>isLoading<span class="signature">()</span><span class="type-signature"> → {boolean}</span></h4>
|
2285 |
|
2286 |
|
2287 | </dt>
|
2288 | <dd>
|
2289 |
|
2290 |
|
2291 | <div class="description">
|
2292 | <p>Tells whether the canvas is loading or not. Some canvas emulation methods can take some time until they finish loading.</p>
|
2293 | </div>
|
2294 |
|
2295 |
|
2296 |
|
2297 |
|
2298 |
|
2299 |
|
2300 |
|
2301 |
|
2302 |
|
2303 |
|
2304 | <dl class="details">
|
2305 |
|
2306 |
|
2307 |
|
2308 |
|
2309 |
|
2310 |
|
2311 |
|
2312 |
|
2313 |
|
2314 |
|
2315 |
|
2316 |
|
2317 |
|
2318 |
|
2319 |
|
2320 |
|
2321 |
|
2322 |
|
2323 |
|
2324 |
|
2325 |
|
2326 |
|
2327 |
|
2328 |
|
2329 |
|
2330 |
|
2331 |
|
2332 |
|
2333 |
|
2334 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2335 | <dd class="tag-source">
|
2336 | <ul class="dummy">
|
2337 | <li>
|
2338 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
2339 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-822">line 822</a>
|
2340 | </li>
|
2341 | </ul>
|
2342 | </dd>
|
2343 |
|
2344 |
|
2345 |
|
2346 |
|
2347 |
|
2348 |
|
2349 |
|
2350 | </dl>
|
2351 |
|
2352 |
|
2353 |
|
2354 |
|
2355 |
|
2356 |
|
2357 |
|
2358 |
|
2359 |
|
2360 |
|
2361 |
|
2362 |
|
2363 |
|
2364 | <h5>Returns:</h5>
|
2365 |
|
2366 |
|
2367 | <div class="param-desc">
|
2368 | <p>Returns whether the canvas is loading or not.</p>
|
2369 | </div>
|
2370 |
|
2371 |
|
2372 |
|
2373 | <dl>
|
2374 | <dt>
|
2375 | Type
|
2376 | </dt>
|
2377 | <dd>
|
2378 |
|
2379 | <span class="param-type">boolean</span>
|
2380 |
|
2381 |
|
2382 |
|
2383 | </dd>
|
2384 | </dl>
|
2385 |
|
2386 |
|
2387 |
|
2388 |
|
2389 |
|
2390 | </dd>
|
2391 |
|
2392 |
|
2393 |
|
2394 | <hr>
|
2395 | <dt>
|
2396 | <h4 class="name" id="isReady"><span class="type-signature"></span>isReady<span class="signature">()</span><span class="type-signature"> → {boolean}</span></h4>
|
2397 |
|
2398 |
|
2399 | </dt>
|
2400 | <dd>
|
2401 |
|
2402 |
|
2403 | <div class="description">
|
2404 | <p>Tells whether the canvas is ready to be used or not. Some canvas emulation methods can take some time until they are ready to be used.</p>
|
2405 | </div>
|
2406 |
|
2407 |
|
2408 |
|
2409 |
|
2410 |
|
2411 |
|
2412 |
|
2413 |
|
2414 |
|
2415 |
|
2416 | <dl class="details">
|
2417 |
|
2418 |
|
2419 |
|
2420 |
|
2421 |
|
2422 |
|
2423 |
|
2424 |
|
2425 |
|
2426 |
|
2427 |
|
2428 |
|
2429 |
|
2430 |
|
2431 |
|
2432 |
|
2433 |
|
2434 |
|
2435 |
|
2436 |
|
2437 |
|
2438 |
|
2439 |
|
2440 |
|
2441 |
|
2442 |
|
2443 |
|
2444 |
|
2445 |
|
2446 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2447 | <dd class="tag-source">
|
2448 | <ul class="dummy">
|
2449 | <li>
|
2450 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
2451 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-811">line 811</a>
|
2452 | </li>
|
2453 | </ul>
|
2454 | </dd>
|
2455 |
|
2456 |
|
2457 |
|
2458 |
|
2459 |
|
2460 |
|
2461 |
|
2462 | </dl>
|
2463 |
|
2464 |
|
2465 |
|
2466 |
|
2467 |
|
2468 |
|
2469 |
|
2470 |
|
2471 |
|
2472 |
|
2473 |
|
2474 |
|
2475 |
|
2476 | <h5>Returns:</h5>
|
2477 |
|
2478 |
|
2479 | <div class="param-desc">
|
2480 | <p>Returns whether the canvas is ready to be used or not.</p>
|
2481 | </div>
|
2482 |
|
2483 |
|
2484 |
|
2485 | <dl>
|
2486 | <dt>
|
2487 | Type
|
2488 | </dt>
|
2489 | <dd>
|
2490 |
|
2491 | <span class="param-type">boolean</span>
|
2492 |
|
2493 |
|
2494 |
|
2495 | </dd>
|
2496 | </dl>
|
2497 |
|
2498 |
|
2499 |
|
2500 |
|
2501 |
|
2502 | </dd>
|
2503 |
|
2504 |
|
2505 |
|
2506 | <hr>
|
2507 | <dt>
|
2508 | <h4 class="name" id="isSupported"><span class="type-signature"></span>isSupported<span class="signature">()</span><span class="type-signature"> → {boolean}</span></h4>
|
2509 |
|
2510 |
|
2511 | </dt>
|
2512 | <dd>
|
2513 |
|
2514 |
|
2515 | <div class="description">
|
2516 | <p>Tells whether the canvas works or not. The internal test used could be not totally reliable.</p>
|
2517 | </div>
|
2518 |
|
2519 |
|
2520 |
|
2521 |
|
2522 |
|
2523 |
|
2524 |
|
2525 |
|
2526 |
|
2527 |
|
2528 | <dl class="details">
|
2529 |
|
2530 |
|
2531 |
|
2532 |
|
2533 |
|
2534 |
|
2535 |
|
2536 |
|
2537 |
|
2538 |
|
2539 |
|
2540 |
|
2541 |
|
2542 |
|
2543 |
|
2544 |
|
2545 |
|
2546 |
|
2547 |
|
2548 |
|
2549 |
|
2550 |
|
2551 |
|
2552 |
|
2553 |
|
2554 |
|
2555 |
|
2556 |
|
2557 |
|
2558 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2559 | <dd class="tag-source">
|
2560 | <ul class="dummy">
|
2561 | <li>
|
2562 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
2563 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-679">line 679</a>
|
2564 | </li>
|
2565 | </ul>
|
2566 | </dd>
|
2567 |
|
2568 |
|
2569 |
|
2570 |
|
2571 |
|
2572 |
|
2573 |
|
2574 | </dl>
|
2575 |
|
2576 |
|
2577 |
|
2578 |
|
2579 |
|
2580 |
|
2581 |
|
2582 |
|
2583 |
|
2584 |
|
2585 |
|
2586 |
|
2587 |
|
2588 | <h5>Returns:</h5>
|
2589 |
|
2590 |
|
2591 | <div class="param-desc">
|
2592 | <p>Returns whether the canvas works or not. The internal test used could be not totally reliable.</p>
|
2593 | </div>
|
2594 |
|
2595 |
|
2596 |
|
2597 | <dl>
|
2598 | <dt>
|
2599 | Type
|
2600 | </dt>
|
2601 | <dd>
|
2602 |
|
2603 | <span class="param-type">boolean</span>
|
2604 |
|
2605 |
|
2606 |
|
2607 | </dd>
|
2608 | </dl>
|
2609 |
|
2610 |
|
2611 |
|
2612 |
|
2613 |
|
2614 | </dd>
|
2615 |
|
2616 |
|
2617 |
|
2618 | <hr>
|
2619 | <dt>
|
2620 | <h4 class="name" id="normalizeContext"><span class="type-signature"></span>normalizeContext<span class="signature">()</span><span class="type-signature"></span></h4>
|
2621 |
|
2622 |
|
2623 | </dt>
|
2624 | <dd>
|
2625 |
|
2626 |
|
2627 | <div class="description">
|
2628 | <p>Alias for <a href="CB_Canvas.html#prepareContext"><code>CB_Canvas#prepareContext</code></a>.</p>
|
2629 | </div>
|
2630 |
|
2631 |
|
2632 |
|
2633 |
|
2634 |
|
2635 |
|
2636 |
|
2637 |
|
2638 |
|
2639 |
|
2640 | <dl class="details">
|
2641 |
|
2642 |
|
2643 |
|
2644 |
|
2645 |
|
2646 |
|
2647 |
|
2648 |
|
2649 |
|
2650 |
|
2651 |
|
2652 |
|
2653 |
|
2654 |
|
2655 |
|
2656 |
|
2657 |
|
2658 |
|
2659 |
|
2660 |
|
2661 |
|
2662 |
|
2663 |
|
2664 |
|
2665 |
|
2666 |
|
2667 |
|
2668 |
|
2669 |
|
2670 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2671 | <dd class="tag-source">
|
2672 | <ul class="dummy">
|
2673 | <li>
|
2674 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
2675 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-537">line 537</a>
|
2676 | </li>
|
2677 | </ul>
|
2678 | </dd>
|
2679 |
|
2680 |
|
2681 |
|
2682 |
|
2683 |
|
2684 | <dt class="tag-see method-doc-label method-doc-details-label">See:</dt>
|
2685 | <dd class="tag-see">
|
2686 | <ul>
|
2687 | <li><a href="CB_Canvas.html#prepareContext"><code>CB_Canvas#prepareContext</code></a></li>
|
2688 | </ul>
|
2689 | </dd>
|
2690 |
|
2691 |
|
2692 |
|
2693 | </dl>
|
2694 |
|
2695 |
|
2696 |
|
2697 |
|
2698 |
|
2699 |
|
2700 |
|
2701 |
|
2702 |
|
2703 |
|
2704 |
|
2705 |
|
2706 |
|
2707 |
|
2708 |
|
2709 | </dd>
|
2710 |
|
2711 |
|
2712 |
|
2713 | <hr>
|
2714 | <dt>
|
2715 | <h4 class="name" id="prepareContext"><span class="type-signature"></span>prepareContext<span class="signature">( )</span><span class="type-signature"> → {RenderingContext|Object}</span></h4>
|
2716 |
|
2717 |
|
2718 | </dt>
|
2719 | <dd>
|
2720 |
|
2721 |
|
2722 | <div class="description">
|
2723 | <p>Provides the canvas <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> with some methods and properties, in case it needs it (as some canvas emulation methods lack of some methods and properties). Since this method is called by the <a href="CB_Canvas.html#set"><code>CB_Canvas#set</code></a> method already (and this one is called by the constructor automatically), it is not needed to be called again normally.</p>
|
2724 | </div>
|
2725 |
|
2726 |
|
2727 |
|
2728 |
|
2729 |
|
2730 |
|
2731 |
|
2732 |
|
2733 | <h5>Parameters:</h5>
|
2734 |
|
2735 |
|
2736 | <table class="params table table-striped">
|
2737 | <thead>
|
2738 | <tr>
|
2739 |
|
2740 | <th style="width:12%; min-width:110px;">Name</th>
|
2741 |
|
2742 |
|
2743 | <th style="width:12%; min-width:110px;">Type</th>
|
2744 |
|
2745 |
|
2746 | <th style="width:12%; min-width:110px;">Argument</th>
|
2747 |
|
2748 |
|
2749 |
|
2750 | <th style="width:12%; min-width:110px;">Default</th>
|
2751 |
|
2752 |
|
2753 | <th class="last" style="min-width:310px;">Description</th>
|
2754 | </tr>
|
2755 | </thead>
|
2756 |
|
2757 | <tbody>
|
2758 |
|
2759 |
|
2760 | <tr>
|
2761 |
|
2762 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>context</code></td>
|
2763 |
|
2764 |
|
2765 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2766 |
|
2767 |
|
2768 | <span class="param-type">RenderingContext</span>
|
2769 | |
|
2770 |
|
2771 | <span class="param-type">Object</span>
|
2772 |
|
2773 |
|
2774 |
|
2775 |
|
2776 | </td>
|
2777 |
|
2778 |
|
2779 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2780 |
|
2781 | <optional><br>
|
2782 |
|
2783 |
|
2784 |
|
2785 |
|
2786 |
|
2787 | </td>
|
2788 |
|
2789 |
|
2790 |
|
2791 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2792 |
|
2793 | <a href="CB_Canvas.html#getContext"><code>CB_Canvas#getContext</code></a>()
|
2794 |
|
2795 | </td>
|
2796 |
|
2797 |
|
2798 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> object that we want to prepare (different type if a canvas emulation method is being used). If not defined, calls the <a href="CB_Canvas.html#getContext"><code>CB_Canvas#getContext</code></a> method internally.</p></td>
|
2799 | </tr>
|
2800 |
|
2801 |
|
2802 | </tbody>
|
2803 | </table>
|
2804 |
|
2805 |
|
2806 |
|
2807 |
|
2808 | <dl class="details">
|
2809 |
|
2810 |
|
2811 |
|
2812 |
|
2813 |
|
2814 |
|
2815 |
|
2816 |
|
2817 |
|
2818 |
|
2819 |
|
2820 |
|
2821 |
|
2822 |
|
2823 |
|
2824 |
|
2825 |
|
2826 |
|
2827 |
|
2828 |
|
2829 |
|
2830 |
|
2831 |
|
2832 |
|
2833 |
|
2834 |
|
2835 |
|
2836 |
|
2837 |
|
2838 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
2839 | <dd class="tag-source">
|
2840 | <ul class="dummy">
|
2841 | <li>
|
2842 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
2843 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-549">line 549</a>
|
2844 | </li>
|
2845 | </ul>
|
2846 | </dd>
|
2847 |
|
2848 |
|
2849 |
|
2850 |
|
2851 |
|
2852 |
|
2853 |
|
2854 | <dt class="tag-todo method-doc-label method-doc-details-label">To Do:</dt>
|
2855 | <dd class="tag-todo">
|
2856 | <ul>
|
2857 | <li>Add more methods and properties needed by some emulation methods.</li>
|
2858 | </ul>
|
2859 | </dd>
|
2860 |
|
2861 | </dl>
|
2862 |
|
2863 |
|
2864 |
|
2865 |
|
2866 |
|
2867 |
|
2868 |
|
2869 |
|
2870 |
|
2871 |
|
2872 |
|
2873 |
|
2874 |
|
2875 | <h5>Returns:</h5>
|
2876 |
|
2877 |
|
2878 | <div class="param-desc">
|
2879 | <p>Returns the canvas <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> (different type if a canvas emulation method is being used).</p>
|
2880 | </div>
|
2881 |
|
2882 |
|
2883 |
|
2884 | <dl>
|
2885 | <dt>
|
2886 | Type
|
2887 | </dt>
|
2888 | <dd>
|
2889 |
|
2890 | <span class="param-type">RenderingContext</span>
|
2891 | |
|
2892 |
|
2893 | <span class="param-type">Object</span>
|
2894 |
|
2895 |
|
2896 |
|
2897 | </dd>
|
2898 | </dl>
|
2899 |
|
2900 |
|
2901 |
|
2902 |
|
2903 |
|
2904 | </dd>
|
2905 |
|
2906 |
|
2907 |
|
2908 | <hr>
|
2909 | <dt>
|
2910 | <h4 class="name" id="set"><span class="type-signature"></span>set<span class="signature">(canvasId [, canvasWidth] [, canvasHeight] [, onLoad] [, onError] [, alternativeCanvasEmulation] [, forceEmulation])</span><span class="type-signature"></span></h4>
|
2911 |
|
2912 |
|
2913 | </dt>
|
2914 | <dd>
|
2915 |
|
2916 |
|
2917 | <div class="description">
|
2918 | <p>Defines the canvas element. Since this method is called by the constructor already, it is not needed to be called unless the canvas element wants to be defined again.</p>
|
2919 | </div>
|
2920 |
|
2921 |
|
2922 |
|
2923 |
|
2924 |
|
2925 |
|
2926 |
|
2927 |
|
2928 | <h5>Parameters:</h5>
|
2929 |
|
2930 |
|
2931 | <table class="params table table-striped">
|
2932 | <thead>
|
2933 | <tr>
|
2934 |
|
2935 | <th style="width:12%; min-width:110px;">Name</th>
|
2936 |
|
2937 |
|
2938 | <th style="width:12%; min-width:110px;">Type</th>
|
2939 |
|
2940 |
|
2941 | <th style="width:12%; min-width:110px;">Argument</th>
|
2942 |
|
2943 |
|
2944 |
|
2945 | <th style="width:12%; min-width:110px;">Default</th>
|
2946 |
|
2947 |
|
2948 | <th class="last" style="min-width:310px;">Description</th>
|
2949 | </tr>
|
2950 | </thead>
|
2951 |
|
2952 | <tbody>
|
2953 |
|
2954 |
|
2955 | <tr>
|
2956 |
|
2957 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasId</code></td>
|
2958 |
|
2959 |
|
2960 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2961 |
|
2962 |
|
2963 | <span class="param-type">string</span>
|
2964 |
|
2965 |
|
2966 |
|
2967 |
|
2968 | </td>
|
2969 |
|
2970 |
|
2971 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2972 |
|
2973 |
|
2974 |
|
2975 |
|
2976 |
|
2977 | </td>
|
2978 |
|
2979 |
|
2980 |
|
2981 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2982 |
|
2983 | </td>
|
2984 |
|
2985 |
|
2986 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The desired ID for the canvas.</p></td>
|
2987 | </tr>
|
2988 |
|
2989 |
|
2990 |
|
2991 | <tr>
|
2992 |
|
2993 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasWidth</code></td>
|
2994 |
|
2995 |
|
2996 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
2997 |
|
2998 |
|
2999 | <span class="param-type">integer</span>
|
3000 |
|
3001 |
|
3002 |
|
3003 |
|
3004 | </td>
|
3005 |
|
3006 |
|
3007 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3008 |
|
3009 | <optional><br>
|
3010 |
|
3011 |
|
3012 |
|
3013 |
|
3014 |
|
3015 | </td>
|
3016 |
|
3017 |
|
3018 |
|
3019 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3020 |
|
3021 | <a href="CB_Canvas.html#.WIDTH_DEFAULT"><code>CB_Canvas.WIDTH_DEFAULT</code></a>
|
3022 |
|
3023 | </td>
|
3024 |
|
3025 |
|
3026 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The desired width (horizontal size) in pixels for the canvas.</p></td>
|
3027 | </tr>
|
3028 |
|
3029 |
|
3030 |
|
3031 | <tr>
|
3032 |
|
3033 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasHeight</code></td>
|
3034 |
|
3035 |
|
3036 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3037 |
|
3038 |
|
3039 | <span class="param-type">integer</span>
|
3040 |
|
3041 |
|
3042 |
|
3043 |
|
3044 | </td>
|
3045 |
|
3046 |
|
3047 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3048 |
|
3049 | <optional><br>
|
3050 |
|
3051 |
|
3052 |
|
3053 |
|
3054 |
|
3055 | </td>
|
3056 |
|
3057 |
|
3058 |
|
3059 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3060 |
|
3061 | <a href="CB_Canvas.html#.HEIGHT_DEFAULT"><code>CB_Canvas.HEIGHT_DEFAULT</code></a>
|
3062 |
|
3063 | </td>
|
3064 |
|
3065 |
|
3066 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The desired height (vertical size) in pixels for the canvas.</p></td>
|
3067 | </tr>
|
3068 |
|
3069 |
|
3070 |
|
3071 | <tr>
|
3072 |
|
3073 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onLoad</code></td>
|
3074 |
|
3075 |
|
3076 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3077 |
|
3078 |
|
3079 | <span class="param-type">function</span>
|
3080 |
|
3081 |
|
3082 |
|
3083 |
|
3084 | </td>
|
3085 |
|
3086 |
|
3087 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3088 |
|
3089 | <optional><br>
|
3090 |
|
3091 |
|
3092 |
|
3093 |
|
3094 |
|
3095 | </td>
|
3096 |
|
3097 |
|
3098 |
|
3099 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3100 |
|
3101 | </td>
|
3102 |
|
3103 |
|
3104 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback function that will be called when the canvas is finally loaded. It will not receive parameters, being "this" the <a href="CB_Canvas.html"><code>CB_Canvas</code></a> object itself.</p></td>
|
3105 | </tr>
|
3106 |
|
3107 |
|
3108 |
|
3109 | <tr>
|
3110 |
|
3111 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>onError</code></td>
|
3112 |
|
3113 |
|
3114 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3115 |
|
3116 |
|
3117 | <span class="param-type">function</span>
|
3118 |
|
3119 |
|
3120 |
|
3121 |
|
3122 | </td>
|
3123 |
|
3124 |
|
3125 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3126 |
|
3127 | <optional><br>
|
3128 |
|
3129 |
|
3130 |
|
3131 |
|
3132 |
|
3133 | </td>
|
3134 |
|
3135 |
|
3136 |
|
3137 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3138 |
|
3139 | </td>
|
3140 |
|
3141 |
|
3142 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Callback function that will be called when there is an error creating or loading the canvas. Being "this" the <a href="CB_Canvas.html"><code>CB_Canvas</code></a> object itself, the unique parameter received will be a string describing the error (if it could be determined).</p></td>
|
3143 | </tr>
|
3144 |
|
3145 |
|
3146 |
|
3147 | <tr>
|
3148 |
|
3149 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>alternativeCanvasEmulation</code></td>
|
3150 |
|
3151 |
|
3152 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3153 |
|
3154 |
|
3155 | <span class="param-type">string</span>
|
3156 |
|
3157 |
|
3158 |
|
3159 |
|
3160 | </td>
|
3161 |
|
3162 |
|
3163 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3164 |
|
3165 | <optional><br>
|
3166 |
|
3167 |
|
3168 |
|
3169 |
|
3170 |
|
3171 | </td>
|
3172 |
|
3173 |
|
3174 |
|
3175 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3176 |
|
3177 | <a href="CB_Canvas.html#.bestEmulation"><code>CB_Canvas.bestEmulation</code></a>()
|
3178 |
|
3179 | </td>
|
3180 |
|
3181 |
|
3182 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Emulation method we want to use in the case that the native <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas">canvas</a> is not supported or if the "forceEmulation" parameter is set to true. Possible emulation methods: "FLASH", "VML", "DHTML" and "SILVERLIGHT".</p></td>
|
3183 | </tr>
|
3184 |
|
3185 |
|
3186 |
|
3187 | <tr>
|
3188 |
|
3189 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>forceEmulation</code></td>
|
3190 |
|
3191 |
|
3192 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3193 |
|
3194 |
|
3195 | <span class="param-type">boolean</span>
|
3196 |
|
3197 |
|
3198 |
|
3199 |
|
3200 | </td>
|
3201 |
|
3202 |
|
3203 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3204 |
|
3205 | <optional><br>
|
3206 |
|
3207 |
|
3208 |
|
3209 |
|
3210 |
|
3211 | </td>
|
3212 |
|
3213 |
|
3214 |
|
3215 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3216 |
|
3217 | false
|
3218 |
|
3219 | </td>
|
3220 |
|
3221 |
|
3222 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, it will force to use the emulation method defined in the "alternativeCanvasEmulation" parameter (even when this alternative emulation method could be not supported and even when native <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas">canvas</a> support could be supported).</p></td>
|
3223 | </tr>
|
3224 |
|
3225 |
|
3226 | </tbody>
|
3227 | </table>
|
3228 |
|
3229 |
|
3230 |
|
3231 |
|
3232 | <dl class="details">
|
3233 |
|
3234 |
|
3235 |
|
3236 |
|
3237 |
|
3238 |
|
3239 |
|
3240 |
|
3241 |
|
3242 |
|
3243 |
|
3244 |
|
3245 |
|
3246 |
|
3247 |
|
3248 |
|
3249 |
|
3250 |
|
3251 |
|
3252 |
|
3253 |
|
3254 |
|
3255 |
|
3256 |
|
3257 |
|
3258 |
|
3259 |
|
3260 |
|
3261 |
|
3262 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3263 | <dd class="tag-source">
|
3264 | <ul class="dummy">
|
3265 | <li>
|
3266 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
3267 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-336">line 336</a>
|
3268 | </li>
|
3269 | </ul>
|
3270 | </dd>
|
3271 |
|
3272 |
|
3273 |
|
3274 |
|
3275 |
|
3276 |
|
3277 |
|
3278 | </dl>
|
3279 |
|
3280 |
|
3281 |
|
3282 |
|
3283 |
|
3284 |
|
3285 |
|
3286 |
|
3287 |
|
3288 |
|
3289 |
|
3290 |
|
3291 |
|
3292 |
|
3293 |
|
3294 | </dd>
|
3295 |
|
3296 |
|
3297 |
|
3298 | <hr>
|
3299 | <dt>
|
3300 | <h4 class="name" id="setContextType"><span class="type-signature"></span>setContextType<span class="signature">( [contextType])</span><span class="type-signature"> → {string}</span></h4>
|
3301 |
|
3302 |
|
3303 | </dt>
|
3304 | <dd>
|
3305 |
|
3306 |
|
3307 | <div class="description">
|
3308 | <p>Defines the desired canvas <a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> type. Internally, it only defines the <code>CB_Canvas#._contextType</code> property.</p>
|
3309 | </div>
|
3310 |
|
3311 |
|
3312 |
|
3313 |
|
3314 |
|
3315 |
|
3316 |
|
3317 |
|
3318 | <h5>Parameters:</h5>
|
3319 |
|
3320 |
|
3321 | <table class="params table table-striped">
|
3322 | <thead>
|
3323 | <tr>
|
3324 |
|
3325 | <th style="width:12%; min-width:110px;">Name</th>
|
3326 |
|
3327 |
|
3328 | <th style="width:12%; min-width:110px;">Type</th>
|
3329 |
|
3330 |
|
3331 | <th style="width:12%; min-width:110px;">Argument</th>
|
3332 |
|
3333 |
|
3334 |
|
3335 | <th style="width:12%; min-width:110px;">Default</th>
|
3336 |
|
3337 |
|
3338 | <th class="last" style="min-width:310px;">Description</th>
|
3339 | </tr>
|
3340 | </thead>
|
3341 |
|
3342 | <tbody>
|
3343 |
|
3344 |
|
3345 | <tr>
|
3346 |
|
3347 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>contextType</code></td>
|
3348 |
|
3349 |
|
3350 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3351 |
|
3352 |
|
3353 | <span class="param-type">'2d'</span>
|
3354 | |
|
3355 |
|
3356 | <span class="param-type">'webgl'</span>
|
3357 | |
|
3358 |
|
3359 | <span class="param-type">'experimental-webgl'</span>
|
3360 | |
|
3361 |
|
3362 | <span class="param-type">'webgl2'</span>
|
3363 | |
|
3364 |
|
3365 | <span class="param-type">'experimental-webgl2'</span>
|
3366 | |
|
3367 |
|
3368 | <span class="param-type">'bitmaprenderer'</span>
|
3369 |
|
3370 |
|
3371 |
|
3372 |
|
3373 | </td>
|
3374 |
|
3375 |
|
3376 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3377 |
|
3378 | <optional><br>
|
3379 |
|
3380 |
|
3381 |
|
3382 |
|
3383 |
|
3384 | </td>
|
3385 |
|
3386 |
|
3387 |
|
3388 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3389 |
|
3390 | '2d'
|
3391 |
|
3392 | </td>
|
3393 |
|
3394 |
|
3395 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The [context]<a href="https://developer.mozilla.org/en-US/docs/Web/API/RenderingContext">context</a> type desired. More information: <a href="https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/getContext">HTMLCanvasElement.getContext</a>. Note that most emulation methods will only support "2d".</p></td>
|
3396 | </tr>
|
3397 |
|
3398 |
|
3399 | </tbody>
|
3400 | </table>
|
3401 |
|
3402 |
|
3403 |
|
3404 |
|
3405 | <dl class="details">
|
3406 |
|
3407 |
|
3408 |
|
3409 |
|
3410 |
|
3411 |
|
3412 |
|
3413 |
|
3414 |
|
3415 |
|
3416 |
|
3417 |
|
3418 |
|
3419 |
|
3420 |
|
3421 |
|
3422 |
|
3423 |
|
3424 |
|
3425 |
|
3426 |
|
3427 |
|
3428 |
|
3429 |
|
3430 |
|
3431 |
|
3432 |
|
3433 |
|
3434 |
|
3435 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3436 | <dd class="tag-source">
|
3437 | <ul class="dummy">
|
3438 | <li>
|
3439 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
3440 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-650">line 650</a>
|
3441 | </li>
|
3442 | </ul>
|
3443 | </dd>
|
3444 |
|
3445 |
|
3446 |
|
3447 |
|
3448 |
|
3449 |
|
3450 |
|
3451 | </dl>
|
3452 |
|
3453 |
|
3454 |
|
3455 |
|
3456 |
|
3457 |
|
3458 |
|
3459 |
|
3460 |
|
3461 |
|
3462 |
|
3463 |
|
3464 |
|
3465 | <h5>Returns:</h5>
|
3466 |
|
3467 |
|
3468 | <div class="param-desc">
|
3469 | <p>Returns the context type just applied.</p>
|
3470 | </div>
|
3471 |
|
3472 |
|
3473 |
|
3474 | <dl>
|
3475 | <dt>
|
3476 | Type
|
3477 | </dt>
|
3478 | <dd>
|
3479 |
|
3480 | <span class="param-type">string</span>
|
3481 |
|
3482 |
|
3483 |
|
3484 | </dd>
|
3485 | </dl>
|
3486 |
|
3487 |
|
3488 |
|
3489 |
|
3490 |
|
3491 | </dd>
|
3492 |
|
3493 |
|
3494 |
|
3495 | <hr>
|
3496 | <dt>
|
3497 | <h4 class="name" id="setHeight"><span class="type-signature"></span>setHeight<span class="signature">( [canvasHeight])</span><span class="type-signature"> → {number}</span></h4>
|
3498 |
|
3499 |
|
3500 | </dt>
|
3501 | <dd>
|
3502 |
|
3503 |
|
3504 | <div class="description">
|
3505 | <p>Defines the desired canvas height.</p>
|
3506 | </div>
|
3507 |
|
3508 |
|
3509 |
|
3510 |
|
3511 |
|
3512 |
|
3513 |
|
3514 |
|
3515 | <h5>Parameters:</h5>
|
3516 |
|
3517 |
|
3518 | <table class="params table table-striped">
|
3519 | <thead>
|
3520 | <tr>
|
3521 |
|
3522 | <th style="width:12%; min-width:110px;">Name</th>
|
3523 |
|
3524 |
|
3525 | <th style="width:12%; min-width:110px;">Type</th>
|
3526 |
|
3527 |
|
3528 | <th style="width:12%; min-width:110px;">Argument</th>
|
3529 |
|
3530 |
|
3531 |
|
3532 | <th style="width:12%; min-width:110px;">Default</th>
|
3533 |
|
3534 |
|
3535 | <th class="last" style="min-width:310px;">Description</th>
|
3536 | </tr>
|
3537 | </thead>
|
3538 |
|
3539 | <tbody>
|
3540 |
|
3541 |
|
3542 | <tr>
|
3543 |
|
3544 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasHeight</code></td>
|
3545 |
|
3546 |
|
3547 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3548 |
|
3549 |
|
3550 | <span class="param-type">integer</span>
|
3551 |
|
3552 |
|
3553 |
|
3554 |
|
3555 | </td>
|
3556 |
|
3557 |
|
3558 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3559 |
|
3560 | <optional><br>
|
3561 |
|
3562 |
|
3563 |
|
3564 |
|
3565 |
|
3566 | </td>
|
3567 |
|
3568 |
|
3569 |
|
3570 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3571 |
|
3572 | <a href="CB_Canvas.html#.HEIGHT_DEFAULT"><code>CB_Canvas.HEIGHT_DEFAULT</code></a>
|
3573 |
|
3574 | </td>
|
3575 |
|
3576 |
|
3577 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The desired height (vertical size) in pixels for the canvas.</p></td>
|
3578 | </tr>
|
3579 |
|
3580 |
|
3581 | </tbody>
|
3582 | </table>
|
3583 |
|
3584 |
|
3585 |
|
3586 |
|
3587 | <dl class="details">
|
3588 |
|
3589 |
|
3590 |
|
3591 |
|
3592 |
|
3593 |
|
3594 |
|
3595 |
|
3596 |
|
3597 |
|
3598 |
|
3599 |
|
3600 |
|
3601 |
|
3602 |
|
3603 |
|
3604 |
|
3605 |
|
3606 |
|
3607 |
|
3608 |
|
3609 |
|
3610 |
|
3611 |
|
3612 |
|
3613 |
|
3614 |
|
3615 |
|
3616 |
|
3617 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3618 | <dd class="tag-source">
|
3619 | <ul class="dummy">
|
3620 | <li>
|
3621 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
3622 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-751">line 751</a>
|
3623 | </li>
|
3624 | </ul>
|
3625 | </dd>
|
3626 |
|
3627 |
|
3628 |
|
3629 |
|
3630 |
|
3631 |
|
3632 |
|
3633 | </dl>
|
3634 |
|
3635 |
|
3636 |
|
3637 |
|
3638 |
|
3639 |
|
3640 |
|
3641 |
|
3642 |
|
3643 |
|
3644 |
|
3645 |
|
3646 |
|
3647 | <h5>Returns:</h5>
|
3648 |
|
3649 |
|
3650 | <div class="param-desc">
|
3651 | <p>Returns the canvas height (vertical size) being used in pixels. It could return zero (0) if cannot be calculated.</p>
|
3652 | </div>
|
3653 |
|
3654 |
|
3655 |
|
3656 | <dl>
|
3657 | <dt>
|
3658 | Type
|
3659 | </dt>
|
3660 | <dd>
|
3661 |
|
3662 | <span class="param-type">number</span>
|
3663 |
|
3664 |
|
3665 |
|
3666 | </dd>
|
3667 | </dl>
|
3668 |
|
3669 |
|
3670 |
|
3671 |
|
3672 |
|
3673 | </dd>
|
3674 |
|
3675 |
|
3676 |
|
3677 | <hr>
|
3678 | <dt>
|
3679 | <h4 class="name" id="setId"><span class="type-signature"></span>setId<span class="signature">(canvasId)</span><span class="type-signature"></span></h4>
|
3680 |
|
3681 |
|
3682 | </dt>
|
3683 | <dd>
|
3684 |
|
3685 |
|
3686 | <div class="description">
|
3687 | <p>Sets the desired identifier (ID) of the canvas element. Since this method is called by the constructor already, it is not needed to be called unless the canvas element wants to be defined again through the <a href="CB_Canvas.html#set"><code>CB_Canvas#set</code></a> method. Note that changing the ID after the canvas has been set could lead to some problems when using certain emulation methods so it is not recommended.</p>
|
3688 | </div>
|
3689 |
|
3690 |
|
3691 |
|
3692 |
|
3693 |
|
3694 |
|
3695 |
|
3696 |
|
3697 | <h5>Parameters:</h5>
|
3698 |
|
3699 |
|
3700 | <table class="params table table-striped">
|
3701 | <thead>
|
3702 | <tr>
|
3703 |
|
3704 | <th style="width:12%; min-width:110px;">Name</th>
|
3705 |
|
3706 |
|
3707 | <th style="width:12%; min-width:110px;">Type</th>
|
3708 |
|
3709 |
|
3710 |
|
3711 |
|
3712 |
|
3713 | <th class="last" style="min-width:310px;">Description</th>
|
3714 | </tr>
|
3715 | </thead>
|
3716 |
|
3717 | <tbody>
|
3718 |
|
3719 |
|
3720 | <tr>
|
3721 |
|
3722 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasId</code></td>
|
3723 |
|
3724 |
|
3725 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3726 |
|
3727 |
|
3728 | <span class="param-type">string</span>
|
3729 |
|
3730 |
|
3731 |
|
3732 |
|
3733 | </td>
|
3734 |
|
3735 |
|
3736 |
|
3737 |
|
3738 |
|
3739 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Identifier (ID) for the canvas element.</p></td>
|
3740 | </tr>
|
3741 |
|
3742 |
|
3743 | </tbody>
|
3744 | </table>
|
3745 |
|
3746 |
|
3747 |
|
3748 |
|
3749 | <dl class="details">
|
3750 |
|
3751 |
|
3752 |
|
3753 |
|
3754 |
|
3755 |
|
3756 |
|
3757 |
|
3758 |
|
3759 |
|
3760 |
|
3761 |
|
3762 |
|
3763 |
|
3764 |
|
3765 |
|
3766 |
|
3767 |
|
3768 |
|
3769 |
|
3770 |
|
3771 |
|
3772 |
|
3773 |
|
3774 |
|
3775 |
|
3776 |
|
3777 |
|
3778 |
|
3779 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3780 | <dd class="tag-source">
|
3781 | <ul class="dummy">
|
3782 | <li>
|
3783 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
3784 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-304">line 304</a>
|
3785 | </li>
|
3786 | </ul>
|
3787 | </dd>
|
3788 |
|
3789 |
|
3790 |
|
3791 |
|
3792 |
|
3793 |
|
3794 |
|
3795 | </dl>
|
3796 |
|
3797 |
|
3798 |
|
3799 |
|
3800 |
|
3801 |
|
3802 |
|
3803 |
|
3804 |
|
3805 |
|
3806 |
|
3807 |
|
3808 |
|
3809 |
|
3810 |
|
3811 | </dd>
|
3812 |
|
3813 |
|
3814 |
|
3815 | <hr>
|
3816 | <dt>
|
3817 | <h4 class="name" id="setWidth"><span class="type-signature"></span>setWidth<span class="signature">( [canvasWidth])</span><span class="type-signature"> → {number}</span></h4>
|
3818 |
|
3819 |
|
3820 | </dt>
|
3821 | <dd>
|
3822 |
|
3823 |
|
3824 | <div class="description">
|
3825 | <p>Defines the desired canvas width.</p>
|
3826 | </div>
|
3827 |
|
3828 |
|
3829 |
|
3830 |
|
3831 |
|
3832 |
|
3833 |
|
3834 |
|
3835 | <h5>Parameters:</h5>
|
3836 |
|
3837 |
|
3838 | <table class="params table table-striped">
|
3839 | <thead>
|
3840 | <tr>
|
3841 |
|
3842 | <th style="width:12%; min-width:110px;">Name</th>
|
3843 |
|
3844 |
|
3845 | <th style="width:12%; min-width:110px;">Type</th>
|
3846 |
|
3847 |
|
3848 | <th style="width:12%; min-width:110px;">Argument</th>
|
3849 |
|
3850 |
|
3851 |
|
3852 | <th style="width:12%; min-width:110px;">Default</th>
|
3853 |
|
3854 |
|
3855 | <th class="last" style="min-width:310px;">Description</th>
|
3856 | </tr>
|
3857 | </thead>
|
3858 |
|
3859 | <tbody>
|
3860 |
|
3861 |
|
3862 | <tr>
|
3863 |
|
3864 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>canvasWidth</code></td>
|
3865 |
|
3866 |
|
3867 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3868 |
|
3869 |
|
3870 | <span class="param-type">integer</span>
|
3871 |
|
3872 |
|
3873 |
|
3874 |
|
3875 | </td>
|
3876 |
|
3877 |
|
3878 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3879 |
|
3880 | <optional><br>
|
3881 |
|
3882 |
|
3883 |
|
3884 |
|
3885 |
|
3886 | </td>
|
3887 |
|
3888 |
|
3889 |
|
3890 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
3891 |
|
3892 | <a href="CB_Canvas.html#.WIDTH_DEFAULT"><code>CB_Canvas.WIDTH_DEFAULT</code></a>
|
3893 |
|
3894 | </td>
|
3895 |
|
3896 |
|
3897 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>The desired width (horizontal size) in pixels for the canvas.</p></td>
|
3898 | </tr>
|
3899 |
|
3900 |
|
3901 | </tbody>
|
3902 | </table>
|
3903 |
|
3904 |
|
3905 |
|
3906 |
|
3907 | <dl class="details">
|
3908 |
|
3909 |
|
3910 |
|
3911 |
|
3912 |
|
3913 |
|
3914 |
|
3915 |
|
3916 |
|
3917 |
|
3918 |
|
3919 |
|
3920 |
|
3921 |
|
3922 |
|
3923 |
|
3924 |
|
3925 |
|
3926 |
|
3927 |
|
3928 |
|
3929 |
|
3930 |
|
3931 |
|
3932 |
|
3933 |
|
3934 |
|
3935 |
|
3936 |
|
3937 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
3938 | <dd class="tag-source">
|
3939 | <ul class="dummy">
|
3940 | <li>
|
3941 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
3942 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-701">line 701</a>
|
3943 | </li>
|
3944 | </ul>
|
3945 | </dd>
|
3946 |
|
3947 |
|
3948 |
|
3949 |
|
3950 |
|
3951 |
|
3952 |
|
3953 | </dl>
|
3954 |
|
3955 |
|
3956 |
|
3957 |
|
3958 |
|
3959 |
|
3960 |
|
3961 |
|
3962 |
|
3963 |
|
3964 |
|
3965 |
|
3966 |
|
3967 | <h5>Returns:</h5>
|
3968 |
|
3969 |
|
3970 | <div class="param-desc">
|
3971 | <p>Returns the canvas width (horizontal size) being used in pixels. It could return zero (0) if cannot be calculated.</p>
|
3972 | </div>
|
3973 |
|
3974 |
|
3975 |
|
3976 | <dl>
|
3977 | <dt>
|
3978 | Type
|
3979 | </dt>
|
3980 | <dd>
|
3981 |
|
3982 | <span class="param-type">number</span>
|
3983 |
|
3984 |
|
3985 |
|
3986 | </dd>
|
3987 | </dl>
|
3988 |
|
3989 |
|
3990 |
|
3991 |
|
3992 |
|
3993 | </dd>
|
3994 |
|
3995 |
|
3996 |
|
3997 | <hr>
|
3998 | <dt>
|
3999 | <h4 class="name" id=".bestEmulation"><span class="type-signature"><static> </span>bestEmulation<span class="signature">( [preferredOrder] [, forceFirstEmulationMethod] [, addOtherMethods] [, allowFlashCanvasLocally])</span><span class="type-signature"> → {'NONE'|'FLASH'|'SILVERLIGHT'|'VML'|'DHTML'}</span></h4>
|
4000 |
|
4001 |
|
4002 | </dt>
|
4003 | <dd>
|
4004 |
|
4005 |
|
4006 | <div class="description">
|
4007 | <p>Calculates and returns the best alternative canvas emulation.</p>
|
4008 | </div>
|
4009 |
|
4010 |
|
4011 |
|
4012 |
|
4013 |
|
4014 |
|
4015 |
|
4016 |
|
4017 | <h5>Parameters:</h5>
|
4018 |
|
4019 |
|
4020 | <table class="params table table-striped">
|
4021 | <thead>
|
4022 | <tr>
|
4023 |
|
4024 | <th style="width:12%; min-width:110px;">Name</th>
|
4025 |
|
4026 |
|
4027 | <th style="width:12%; min-width:110px;">Type</th>
|
4028 |
|
4029 |
|
4030 | <th style="width:12%; min-width:110px;">Argument</th>
|
4031 |
|
4032 |
|
4033 |
|
4034 | <th style="width:12%; min-width:110px;">Default</th>
|
4035 |
|
4036 |
|
4037 | <th class="last" style="min-width:310px;">Description</th>
|
4038 | </tr>
|
4039 | </thead>
|
4040 |
|
4041 | <tbody>
|
4042 |
|
4043 |
|
4044 | <tr>
|
4045 |
|
4046 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>preferredOrder</code></td>
|
4047 |
|
4048 |
|
4049 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4050 |
|
4051 |
|
4052 | <span class="param-type">array</span>
|
4053 | |
|
4054 |
|
4055 | <span class="param-type">string</span>
|
4056 |
|
4057 |
|
4058 |
|
4059 |
|
4060 | </td>
|
4061 |
|
4062 |
|
4063 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4064 |
|
4065 | <optional><br>
|
4066 |
|
4067 |
|
4068 |
|
4069 |
|
4070 |
|
4071 | </td>
|
4072 |
|
4073 |
|
4074 |
|
4075 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4076 |
|
4077 | <a href="CB_Configuration.CrossBase.html#.CB_Canvas_PREFERRED_EMULATION_METHODS"><code>CB_Configuration.CrossBase.CB_Canvas_PREFERRED_EMULATION_METHODS</code></a>
|
4078 |
|
4079 | </td>
|
4080 |
|
4081 |
|
4082 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Numeric array listing the desired alternative emulation methods for rendering the canvas, in order of preference. Possible emulation methods: "FLASH", "VML", "DHTML" and "SILVERLIGHT". It can also be a string with the unique desired canvas emulation method or with "NO" or "NONE" value (meaning no emulation method is desired and then the returning value will always be "NONE").</p></td>
|
4083 | </tr>
|
4084 |
|
4085 |
|
4086 |
|
4087 | <tr>
|
4088 |
|
4089 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>forceFirstEmulationMethod</code></td>
|
4090 |
|
4091 |
|
4092 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4093 |
|
4094 |
|
4095 | <span class="param-type">boolean</span>
|
4096 |
|
4097 |
|
4098 |
|
4099 |
|
4100 | </td>
|
4101 |
|
4102 |
|
4103 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4104 |
|
4105 | <optional><br>
|
4106 |
|
4107 |
|
4108 |
|
4109 |
|
4110 |
|
4111 | </td>
|
4112 |
|
4113 |
|
4114 |
|
4115 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4116 |
|
4117 | false
|
4118 |
|
4119 | </td>
|
4120 |
|
4121 |
|
4122 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, it will force to return the first alternative emulation method desired which is detected as supported without being too strict (even when this alternative emulation method could be not really supported and even when native <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas">canvas</a> support could be supported).</p></td>
|
4123 | </tr>
|
4124 |
|
4125 |
|
4126 |
|
4127 | <tr>
|
4128 |
|
4129 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>addOtherMethods</code></td>
|
4130 |
|
4131 |
|
4132 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4133 |
|
4134 |
|
4135 | <span class="param-type">boolean</span>
|
4136 |
|
4137 |
|
4138 |
|
4139 |
|
4140 | </td>
|
4141 |
|
4142 |
|
4143 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4144 |
|
4145 | <optional><br>
|
4146 |
|
4147 |
|
4148 |
|
4149 |
|
4150 |
|
4151 | </td>
|
4152 |
|
4153 |
|
4154 |
|
4155 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4156 |
|
4157 | true
|
4158 |
|
4159 | </td>
|
4160 |
|
4161 |
|
4162 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, it will add other alternative methods (if any is missing) at the end of the desired alternative emulation methods so they will also be checked and used if the previous ones are not finally used. The order they will be added will be the one used in the <a href="CB_Configuration.CrossBase.html#.CB_Canvas_PREFERRED_EMULATION_METHODS"><code>CB_Configuration.CrossBase.CB_Canvas_PREFERRED_EMULATION_METHODS</code></a> constant.</p></td>
|
4163 | </tr>
|
4164 |
|
4165 |
|
4166 |
|
4167 | <tr>
|
4168 |
|
4169 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>allowFlashCanvasLocally</code></td>
|
4170 |
|
4171 |
|
4172 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4173 |
|
4174 |
|
4175 | <span class="param-type">boolean</span>
|
4176 |
|
4177 |
|
4178 |
|
4179 |
|
4180 | </td>
|
4181 |
|
4182 |
|
4183 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4184 |
|
4185 | <optional><br>
|
4186 |
|
4187 |
|
4188 |
|
4189 |
|
4190 |
|
4191 | </td>
|
4192 |
|
4193 |
|
4194 |
|
4195 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4196 |
|
4197 | <a href="CB_Configuration.CrossBase.html#.FLASHCANVAS_ALLOW_RUN_LOCALLY_DEFAULT"><code>CB_Configuration.CrossBase.FLASHCANVAS_ALLOW_RUN_LOCALLY_DEFAULT</code></a>
|
4198 |
|
4199 | </td>
|
4200 |
|
4201 |
|
4202 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, it will allow to use <a href="https://en.wikipedia.org/wiki/Adobe_Flash_Player">Adobe Flash (formerly Macromedia Flash)</a> emulation (if needed) even when it is running locally. Uses the <a href="CB_Client.html#.isRunningLocally"><code>CB_Client.isRunningLocally</code></a> function internally.</p></td>
|
4203 | </tr>
|
4204 |
|
4205 |
|
4206 | </tbody>
|
4207 | </table>
|
4208 |
|
4209 |
|
4210 |
|
4211 |
|
4212 | <dl class="details">
|
4213 |
|
4214 |
|
4215 |
|
4216 |
|
4217 |
|
4218 |
|
4219 |
|
4220 |
|
4221 |
|
4222 |
|
4223 |
|
4224 |
|
4225 |
|
4226 |
|
4227 |
|
4228 |
|
4229 |
|
4230 |
|
4231 |
|
4232 |
|
4233 |
|
4234 |
|
4235 |
|
4236 |
|
4237 |
|
4238 |
|
4239 |
|
4240 |
|
4241 |
|
4242 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
4243 | <dd class="tag-source">
|
4244 | <ul class="dummy">
|
4245 | <li>
|
4246 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
4247 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-142">line 142</a>
|
4248 | </li>
|
4249 | </ul>
|
4250 | </dd>
|
4251 |
|
4252 |
|
4253 |
|
4254 |
|
4255 |
|
4256 |
|
4257 |
|
4258 | </dl>
|
4259 |
|
4260 |
|
4261 |
|
4262 |
|
4263 |
|
4264 |
|
4265 |
|
4266 |
|
4267 |
|
4268 |
|
4269 |
|
4270 |
|
4271 |
|
4272 | <h5>Returns:</h5>
|
4273 |
|
4274 |
|
4275 | <div class="param-desc">
|
4276 | <p>Returns "NONE" if no canvas emulation is needed/supported (and no emulation method is forced). Otherwise, it returns the best emulation method calculated ("FLASH", "SILVERLIGHT", "VML" or "DHTML").</p>
|
4277 | </div>
|
4278 |
|
4279 |
|
4280 |
|
4281 | <dl>
|
4282 | <dt>
|
4283 | Type
|
4284 | </dt>
|
4285 | <dd>
|
4286 |
|
4287 | <span class="param-type">'NONE'</span>
|
4288 | |
|
4289 |
|
4290 | <span class="param-type">'FLASH'</span>
|
4291 | |
|
4292 |
|
4293 | <span class="param-type">'SILVERLIGHT'</span>
|
4294 | |
|
4295 |
|
4296 | <span class="param-type">'VML'</span>
|
4297 | |
|
4298 |
|
4299 | <span class="param-type">'DHTML'</span>
|
4300 |
|
4301 |
|
4302 |
|
4303 | </dd>
|
4304 | </dl>
|
4305 |
|
4306 |
|
4307 |
|
4308 |
|
4309 |
|
4310 | </dd>
|
4311 |
|
4312 |
|
4313 |
|
4314 | <hr>
|
4315 | <dt>
|
4316 | <h4 class="name" id=".needsEmulation"><span class="type-signature"><static> </span>needsEmulation<span class="signature">()</span><span class="type-signature"> → {boolean}</span></h4>
|
4317 |
|
4318 |
|
4319 | </dt>
|
4320 | <dd>
|
4321 |
|
4322 |
|
4323 | <div class="description">
|
4324 | <p>Tells whether the current client needs canvas emulation or not. Uses <a href="CB_Client.html#.supportsCanvas"><code>CB_Client.supportsCanvas</code></a> internally.</p>
|
4325 | </div>
|
4326 |
|
4327 |
|
4328 |
|
4329 |
|
4330 |
|
4331 |
|
4332 |
|
4333 |
|
4334 |
|
4335 |
|
4336 | <dl class="details">
|
4337 |
|
4338 |
|
4339 |
|
4340 |
|
4341 |
|
4342 |
|
4343 |
|
4344 |
|
4345 |
|
4346 |
|
4347 |
|
4348 |
|
4349 |
|
4350 |
|
4351 |
|
4352 |
|
4353 |
|
4354 |
|
4355 |
|
4356 |
|
4357 |
|
4358 |
|
4359 |
|
4360 |
|
4361 |
|
4362 |
|
4363 |
|
4364 |
|
4365 |
|
4366 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
4367 | <dd class="tag-source">
|
4368 | <ul class="dummy">
|
4369 | <li>
|
4370 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
4371 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-127">line 127</a>
|
4372 | </li>
|
4373 | </ul>
|
4374 | </dd>
|
4375 |
|
4376 |
|
4377 |
|
4378 |
|
4379 |
|
4380 |
|
4381 |
|
4382 | </dl>
|
4383 |
|
4384 |
|
4385 |
|
4386 |
|
4387 |
|
4388 |
|
4389 |
|
4390 |
|
4391 |
|
4392 |
|
4393 |
|
4394 |
|
4395 |
|
4396 | <h5>Returns:</h5>
|
4397 |
|
4398 |
|
4399 | <div class="param-desc">
|
4400 | <p>Returns whether the current client needs canvas emulation or not.</p>
|
4401 | </div>
|
4402 |
|
4403 |
|
4404 |
|
4405 | <dl>
|
4406 | <dt>
|
4407 | Type
|
4408 | </dt>
|
4409 | <dd>
|
4410 |
|
4411 | <span class="param-type">boolean</span>
|
4412 |
|
4413 |
|
4414 |
|
4415 | </dd>
|
4416 | </dl>
|
4417 |
|
4418 |
|
4419 |
|
4420 |
|
4421 |
|
4422 | </dd>
|
4423 |
|
4424 |
|
4425 |
|
4426 | <hr>
|
4427 | <dt>
|
4428 | <h4 class="name" id=".supportsEmulationMethod"><span class="type-signature"><static> </span>supportsEmulationMethod<span class="signature">(emulationMethod [, strictMode])</span><span class="type-signature"> → {boolean}</span></h4>
|
4429 |
|
4430 |
|
4431 | </dt>
|
4432 | <dd>
|
4433 |
|
4434 |
|
4435 | <div class="description">
|
4436 | <p>Tells whether the current client is compatible with a given canvas emulation method or not.</p>
|
4437 | </div>
|
4438 |
|
4439 |
|
4440 |
|
4441 |
|
4442 |
|
4443 |
|
4444 |
|
4445 |
|
4446 | <h5>Parameters:</h5>
|
4447 |
|
4448 |
|
4449 | <table class="params table table-striped">
|
4450 | <thead>
|
4451 | <tr>
|
4452 |
|
4453 | <th style="width:12%; min-width:110px;">Name</th>
|
4454 |
|
4455 |
|
4456 | <th style="width:12%; min-width:110px;">Type</th>
|
4457 |
|
4458 |
|
4459 | <th style="width:12%; min-width:110px;">Argument</th>
|
4460 |
|
4461 |
|
4462 |
|
4463 | <th style="width:12%; min-width:110px;">Default</th>
|
4464 |
|
4465 |
|
4466 | <th class="last" style="min-width:310px;">Description</th>
|
4467 | </tr>
|
4468 | </thead>
|
4469 |
|
4470 | <tbody>
|
4471 |
|
4472 |
|
4473 | <tr>
|
4474 |
|
4475 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>emulationMethod</code></td>
|
4476 |
|
4477 |
|
4478 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4479 |
|
4480 |
|
4481 | <span class="param-type">string</span>
|
4482 |
|
4483 |
|
4484 |
|
4485 |
|
4486 | </td>
|
4487 |
|
4488 |
|
4489 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4490 |
|
4491 |
|
4492 |
|
4493 |
|
4494 |
|
4495 | </td>
|
4496 |
|
4497 |
|
4498 |
|
4499 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4500 |
|
4501 | </td>
|
4502 |
|
4503 |
|
4504 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>Emulation method we want to check. Possible emulation methods: "FLASH", "VML", "DHTML" and "SILVERLIGHT".</p></td>
|
4505 | </tr>
|
4506 |
|
4507 |
|
4508 |
|
4509 | <tr>
|
4510 |
|
4511 | <td class="name" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><code>strictMode</code></td>
|
4512 |
|
4513 |
|
4514 | <td class="type" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4515 |
|
4516 |
|
4517 | <span class="param-type">boolean</span>
|
4518 |
|
4519 |
|
4520 |
|
4521 |
|
4522 | </td>
|
4523 |
|
4524 |
|
4525 | <td class="attributes" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4526 |
|
4527 | <optional><br>
|
4528 |
|
4529 |
|
4530 |
|
4531 |
|
4532 |
|
4533 | </td>
|
4534 |
|
4535 |
|
4536 |
|
4537 | <td class="default" style="width:12%; min-width:110px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;">
|
4538 |
|
4539 | true
|
4540 |
|
4541 | </td>
|
4542 |
|
4543 |
|
4544 | <td class="description last" style="min-width:310px; overflow-wrap:break-word; word-wrap:break-word; word-break:break-word; line-break:strict; hyphens:none; -webkit-hyphens:none; -moz-hyphens:none;"><p>If set to true, the compatibility will be checked more carefully. If set to false (not recommended), the method could return true even when sometimes the canvas emulation method is not totally supported by the current client.</p></td>
|
4545 | </tr>
|
4546 |
|
4547 |
|
4548 | </tbody>
|
4549 | </table>
|
4550 |
|
4551 |
|
4552 |
|
4553 |
|
4554 | <dl class="details">
|
4555 |
|
4556 |
|
4557 |
|
4558 |
|
4559 |
|
4560 |
|
4561 |
|
4562 |
|
4563 |
|
4564 |
|
4565 |
|
4566 |
|
4567 |
|
4568 |
|
4569 |
|
4570 |
|
4571 |
|
4572 |
|
4573 |
|
4574 |
|
4575 |
|
4576 |
|
4577 |
|
4578 |
|
4579 |
|
4580 |
|
4581 |
|
4582 |
|
4583 |
|
4584 | <dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
|
4585 | <dd class="tag-source">
|
4586 | <ul class="dummy">
|
4587 | <li>
|
4588 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html">CrossBase/audiovisual/image/canvas/CB_Canvas.js</a>,
|
4589 | <a href="CrossBase_audiovisual_image_canvas_CB_Canvas.js.html#sunlight-1-line-216">line 216</a>
|
4590 | </li>
|
4591 | </ul>
|
4592 | </dd>
|
4593 |
|
4594 |
|
4595 |
|
4596 |
|
4597 |
|
4598 |
|
4599 |
|
4600 | </dl>
|
4601 |
|
4602 |
|
4603 |
|
4604 |
|
4605 |
|
4606 |
|
4607 |
|
4608 |
|
4609 |
|
4610 |
|
4611 |
|
4612 |
|
4613 |
|
4614 | <h5>Returns:</h5>
|
4615 |
|
4616 |
|
4617 | <div class="param-desc">
|
4618 | <p>Returns whether the current client is compatible with the given canvas emulation method or not.</p>
|
4619 | </div>
|
4620 |
|
4621 |
|
4622 |
|
4623 | <dl>
|
4624 | <dt>
|
4625 | Type
|
4626 | </dt>
|
4627 | <dd>
|
4628 |
|
4629 | <span class="param-type">boolean</span>
|
4630 |
|
4631 |
|
4632 |
|
4633 | </dd>
|
4634 | </dl>
|
4635 |
|
4636 |
|
4637 |
|
4638 |
|
4639 |
|
4640 | </dd>
|
4641 |
|
4642 | </dl>
|
4643 |
|
4644 |
|
4645 |
|
4646 |
|
4647 |
|
4648 | </article>
|
4649 |
|
4650 | </section>
|
4651 |
|
4652 |
|
4653 |
|
4654 |
|
4655 | </div>
|
4656 | </div>
|
4657 |
|
4658 | <div class="clearfix"></div>
|
4659 |
|
4660 |
|
4661 | <div class="col-md-3">
|
4662 | <div id="toc" class="col-md-3 hidden-xs hidden-sm hidden-md" style="display:none; visibility:hidden;"></div>
|
4663 | </div>
|
4664 |
|
4665 |
|
4666 | </div>
|
4667 | </div>
|
4668 |
|
4669 |
|
4670 | <div class="modal fade" id="searchResults">
|
4671 | <div class="modal-dialog">
|
4672 | <div class="modal-content">
|
4673 | <div class="modal-header">
|
4674 | <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
4675 | <h4 class="modal-title">Search results</h4>
|
4676 | </div>
|
4677 | <div class="modal-body"></div>
|
4678 | <div class="modal-footer">
|
4679 | <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
|
4680 | </div>
|
4681 | </div>
|
4682 | </div>
|
4683 | </div>
|
4684 |
|
4685 |
|
4686 | <footer>
|
4687 |
|
4688 |
|
4689 | <span class="copyright">
|
4690 | <span style="color:#000000">© <address style="display:inline; font-style:normal;"><a href="https://crossbrowdy.com/" target="_blank">CrossBrowdy</a> API documentation</address> by <a href="https://joanalbamaldonado.com/" target="_blank">Joan Alba Maldonado</a> - <a href="https://creativecommons.org/licenses/by/4.0/" target="_blank">Creative Commons Attribution 4.0 International</a><br />DocStrap Copyright © 2012-2015 The contributors to the JSDoc3 and DocStrap projects.</span>
|
4691 | </span>
|
4692 |
|
4693 | <span class="jsdoc-message">
|
4694 | Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.2</a>
|
4695 |
|
4696 | on Wed Mar 22nd 2023
|
4697 |
|
4698 | using the <a href="https://github.com/docstrap/docstrap">DocStrap template</a>.
|
4699 | </span>
|
4700 | </footer>
|
4701 |
|
4702 | <script src="scripts/docstrap.lib.js"></script>
|
4703 | <script src="scripts/toc.js"></script>
|
4704 |
|
4705 | <script type="text/javascript" src="scripts/fulltext-search-ui.js"></script>
|
4706 |
|
4707 |
|
4708 | <script>
|
4709 | $( function () {
|
4710 | $( "[id*='$']" ).each( function () {
|
4711 | var $this = $( this );
|
4712 |
|
4713 | $this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) );
|
4714 | } );
|
4715 |
|
4716 | $( ".tutorial-section pre, .readme-section pre, pre.prettyprint.source" ).each( function () {
|
4717 | var $this = $( this );
|
4718 |
|
4719 | var example = $this.find( "code" );
|
4720 | exampleText = example.html();
|
4721 | var lang = /{@lang (.*?)}/.exec( exampleText );
|
4722 | if ( lang && lang[1] ) {
|
4723 | exampleText = exampleText.replace( lang[0], "" );
|
4724 | example.html( exampleText );
|
4725 | lang = lang[1];
|
4726 | } else {
|
4727 | var langClassMatch = example.parent()[0].className.match(/lang\-(\S+)/);
|
4728 | lang = langClassMatch ? langClassMatch[1] : "javascript";
|
4729 | }
|
4730 |
|
4731 | if ( lang ) {
|
4732 |
|
4733 | $this
|
4734 | .addClass( "sunlight-highlight-" + lang )
|
4735 | .addClass( "linenums" )
|
4736 | .html( example.html() );
|
4737 |
|
4738 | }
|
4739 | } );
|
4740 |
|
4741 | Sunlight.highlightAll( {
|
4742 | lineNumbers : true,
|
4743 | showMenu : true,
|
4744 | enableDoclinks : true
|
4745 | } );
|
4746 |
|
4747 | $.catchAnchorLinks( {
|
4748 | navbarOffset: 10
|
4749 | } );
|
4750 | $( "#toc" ).toc( {
|
4751 | anchorName : function ( i, heading, prefix ) {
|
4752 | return $( heading ).attr( "id" ) || ( prefix + i );
|
4753 | },
|
4754 | selectors : "#toc-content h1,#toc-content h2,#toc-content h3,#toc-content h4",
|
4755 | showAndHide : false,
|
4756 | smoothScrolling: true
|
4757 | } );
|
4758 |
|
4759 | $( "#main span[id^='toc']" ).addClass( "toc-shim" );
|
4760 | $( '.dropdown-toggle' ).dropdown();
|
4761 |
|
4762 | $( "table" ).each( function () {
|
4763 | var $this = $( this );
|
4764 | $this.addClass('table');
|
4765 | } );
|
4766 |
|
4767 | } );
|
4768 | </script>
|
4769 |
|
4770 |
|
4771 |
|
4772 |
|
4773 |
|
4774 |
|
4775 |
|
4776 |
|
4777 |
|
4778 |
|
4779 | <script type="text/javascript">
|
4780 | $(document).ready(function() {
|
4781 | SearcherDisplay.init();
|
4782 | });
|
4783 | </script>
|
4784 |
|
4785 |
|
4786 | </body>
|
4787 | </html> |
\ | No newline at end of file |