Skip to content

Commit 196d3af

Browse files
authored
Merge pull request #5502 from Zearin/docs-multiplication-x
docs: Use “×” for dimensions
2 parents 562fa1a + ccac595 commit 196d3af

22 files changed

+129
-129
lines changed

src/color/creating_reading.js

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -245,13 +245,13 @@ p5.prototype.brightness = function(c) {
245245
*
246246
* @alt
247247
* Yellow rect in middle right of canvas, with 55 pixel width and height.
248-
* Yellow ellipse in top left of canvas, black ellipse in bottom right,both 80x80.
248+
* Yellow ellipse in top left of canvas, black ellipse in bottom right,both 80×80.
249249
* Bright fuchsia rect in middle of canvas, 60 pixel width and height.
250-
* Two bright green rects on opposite sides of the canvas, both 45x80.
251-
* Four blue rects in each corner of the canvas, each are 35x35.
252-
* Bright sea green rect on left and darker rect on right of canvas, both 45x80.
253-
* Dark green rect on left and lighter green rect on right of canvas, both 45x80.
254-
* Dark blue rect on left and light teal rect on right of canvas, both 45x80.
250+
* Two bright green rects on opposite sides of the canvas, both 45×80.
251+
* Four blue rects in each corner of the canvas, each are 35×35.
252+
* Bright sea green rect on left and darker rect on right of canvas, both 45×80.
253+
* Dark green rect on left and lighter green rect on right of canvas, both 45×80.
254+
* Dark blue rect on left and light teal rect on right of canvas, both 45×80.
255255
*/
256256

257257
/**
@@ -316,7 +316,7 @@ p5.prototype.color = function() {
316316
* </div>
317317
*
318318
* @alt
319-
* blue rect on left and green on right, both with black outlines & 35x60.
319+
* blue rect on left and green on right, both with black outlines & 35×60.
320320
*/
321321
p5.prototype.green = function(c) {
322322
p5._validateParameters('green', arguments);
@@ -351,7 +351,7 @@ p5.prototype.green = function(c) {
351351
* </div>
352352
*
353353
* @alt
354-
* salmon pink rect on left and black on right, both 35x60.
354+
* salmon pink rect on left and black on right, both 35×60.
355355
*/
356356
p5.prototype.hue = function(c) {
357357
p5._validateParameters('hue', arguments);
@@ -398,7 +398,7 @@ p5.prototype.hue = function(c) {
398398
* </div>
399399
*
400400
* @alt
401-
* 4 rects one tan, brown, brownish purple, purple, with white outlines & 20x60
401+
* 4 rects one tan, brown, brownish purple, purple, with white outlines & 20×60
402402
*/
403403

404404
p5.prototype.lerpColor = function(c1, c2, amt) {
@@ -472,7 +472,7 @@ p5.prototype.lerpColor = function(c1, c2, amt) {
472472
* </div>
473473
*
474474
* @alt
475-
* light pastel green rect on left and dark grey rect on right, both 35x60.
475+
* light pastel green rect on left and dark grey rect on right, both 35×60.
476476
*/
477477
p5.prototype.lightness = function(c) {
478478
p5._validateParameters('lightness', arguments);
@@ -511,7 +511,7 @@ p5.prototype.lightness = function(c) {
511511
* </div>
512512
*
513513
* @alt
514-
* yellow rect on left and red rect on right, both with black outlines and 35x60.
514+
* yellow rect on left and red rect on right, both with black outlines and 35×60.
515515
* grey canvas
516516
*/
517517
p5.prototype.red = function(c) {
@@ -546,7 +546,7 @@ p5.prototype.red = function(c) {
546546
* </div>
547547
*
548548
* @alt
549-
*deep pink rect on left and grey rect on right, both 35x60.
549+
*deep pink rect on left and grey rect on right, both 35×60.
550550
*/
551551
p5.prototype.saturation = function(c) {
552552
p5._validateParameters('saturation', arguments);

src/color/setting.js

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ p5.prototype.clear = function(...args) {
297297
*Green to red gradient from bottom L to top R. shading originates from top left.
298298
*Rainbow gradient from left to right. Brightness increasing to white at top.
299299
*unknown image.
300-
*50x50 ellipse at middle L & 40x40 ellipse at center. Translucent pink outlines.
300+
*50×50 ellipse at middle L & 40×40 ellipse at center. Translucent pink outlines.
301301
*/
302302

303303
/**
@@ -458,17 +458,17 @@ p5.prototype.colorMode = function(mode, max1, max2, max3, maxA) {
458458
* </div>
459459
*
460460
* @alt
461-
* 60x60 dark charcoal grey rect with black outline in center of canvas.
462-
* 60x60 yellow rect with black outline in center of canvas.
463-
* 60x60 royal blue rect with black outline in center of canvas.
464-
* 60x60 red rect with black outline in center of canvas.
465-
* 60x60 pink rect with black outline in center of canvas.
466-
* 60x60 black rect with black outline in center of canvas.
467-
* 60x60 light green rect with black outline in center of canvas.
468-
* 60x60 soft green rect with black outline in center of canvas.
469-
* 60x60 red rect with black outline in center of canvas.
470-
* 60x60 dark fuchsia rect with black outline in center of canvas.
471-
* 60x60 blue rect with black outline in center of canvas.
461+
* 60×60 dark charcoal grey rect with black outline in center of canvas.
462+
* 60×60 yellow rect with black outline in center of canvas.
463+
* 60×60 royal blue rect with black outline in center of canvas.
464+
* 60×60 red rect with black outline in center of canvas.
465+
* 60×60 pink rect with black outline in center of canvas.
466+
* 60×60 black rect with black outline in center of canvas.
467+
* 60×60 light green rect with black outline in center of canvas.
468+
* 60×60 soft green rect with black outline in center of canvas.
469+
* 60×60 red rect with black outline in center of canvas.
470+
* 60×60 dark fuchsia rect with black outline in center of canvas.
471+
* 60×60 blue rect with black outline in center of canvas.
472472
*/
473473

474474
/**
@@ -536,7 +536,7 @@ p5.prototype.fill = function(...args) {
536536
* </div>
537537
*
538538
* @alt
539-
* white rect top middle and noFill rect center. Both 60x60 with black outlines.
539+
* white rect top middle and noFill rect center. Both 60×60 with black outlines.
540540
* black canvas with purple cube wireframe spinning
541541
*/
542542
p5.prototype.noFill = function() {
@@ -576,7 +576,7 @@ p5.prototype.noFill = function() {
576576
* </div>
577577
*
578578
* @alt
579-
* 60x60 white rect at center. no outline.
579+
* 60×60 white rect at center. no outline.
580580
* black canvas with pink cube spinning
581581
*/
582582
p5.prototype.noStroke = function() {
@@ -710,17 +710,17 @@ p5.prototype.noStroke = function() {
710710
* </div>
711711
*
712712
* @alt
713-
* 60x60 white rect at center. Dark charcoal grey outline.
714-
* 60x60 white rect at center. Yellow outline.
715-
* 60x60 white rect at center. Royal blue outline.
716-
* 60x60 white rect at center. Red outline.
717-
* 60x60 white rect at center. Pink outline.
718-
* 60x60 white rect at center. Black outline.
719-
* 60x60 white rect at center. Bright green outline.
720-
* 60x60 white rect at center. Soft green outline.
721-
* 60x60 white rect at center. Red outline.
722-
* 60x60 white rect at center. Dark fuchsia outline.
723-
* 60x60 white rect at center. Blue outline.
713+
* 60×60 white rect at center. Dark charcoal grey outline.
714+
* 60×60 white rect at center. Yellow outline.
715+
* 60×60 white rect at center. Royal blue outline.
716+
* 60×60 white rect at center. Red outline.
717+
* 60×60 white rect at center. Pink outline.
718+
* 60×60 white rect at center. Black outline.
719+
* 60×60 white rect at center. Bright green outline.
720+
* 60×60 white rect at center. Soft green outline.
721+
* 60×60 white rect at center. Red outline.
722+
* 60×60 white rect at center. Dark fuchsia outline.
723+
* 60×60 white rect at center. Blue outline.
724724
*/
725725

726726
/**
@@ -826,9 +826,9 @@ p5.prototype.stroke = function(...args) {
826826
* </div>
827827
*
828828
* @alt
829-
* 60x60 centered pink rect, purple background. Elliptical area in top-left of rect is erased white.
830-
* 60x60 centered purple rect, mint green background. Triangle in top-right is partially erased with fully erased outline.
831-
* 60x60 centered teal sphere, yellow background. Torus rotating around sphere erases to reveal black text underneath.
829+
* 60×60 centered pink rect, purple background. Elliptical area in top-left of rect is erased white.
830+
* 60×60 centered purple rect, mint green background. Triangle in top-right is partially erased with fully erased outline.
831+
* 60×60 centered teal sphere, yellow background. Torus rotating around sphere erases to reveal black text underneath.
832832
*/
833833
p5.prototype.erase = function(opacityFill = 255, opacityStroke = 255) {
834834
this._renderer.erase(opacityFill, opacityStroke);

src/core/constants.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ export const WAIT = 'wait';
7878
* </code></div>
7979
*
8080
* @alt
81-
* 80x80 white quarter-circle with curve toward bottom right of canvas.
81+
* 80×80 white quarter-circle with curve toward bottom right of canvas.
8282
*/
8383
export const HALF_PI = _PI / 2;
8484
/**
@@ -132,7 +132,7 @@ export const QUARTER_PI = _PI / 4;
132132
* </code></div>
133133
*
134134
* @alt
135-
* 80x80 white ellipse shape in center of canvas.
135+
* 80×80 white ellipse shape in center of canvas.
136136
*/
137137
export const TAU = _PI * 2;
138138
/**
@@ -150,7 +150,7 @@ export const TAU = _PI * 2;
150150
* </code></div>
151151
*
152152
* @alt
153-
* 80x80 white ellipse shape in center of canvas.
153+
* 80×80 white ellipse shape in center of canvas.
154154
*/
155155
export const TWO_PI = _PI * 2;
156156
/**

src/core/environment.js

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -153,14 +153,14 @@ p5.prototype.deltaTime = 0;
153153
* </code></div>
154154
*
155155
* @alt
156-
* green 50x50 ellipse at top left. Red X covers canvas when page focus changes
156+
* green 50×50 ellipse at top left. Red X covers canvas when page focus changes
157157
*/
158158
p5.prototype.focused = document.hasFocus();
159159

160160
/**
161161
* Sets the cursor to a predefined symbol or an image, or makes it visible
162162
* if already hidden. If you are trying to set an image as the cursor, the
163-
* recommended size is 16x16 or 32x32 pixels. The values for parameters x and y
163+
* recommended size is 16×16 or 32×32 pixels. The values for parameters x and y
164164
* must be less than the dimensions of the image.
165165
*
166166
* @method cursor
@@ -229,13 +229,13 @@ p5.prototype.cursor = function(type, x, y) {
229229
* Specifies the number of frames to be displayed every second. For example,
230230
* the function call frameRate(30) will attempt to refresh 30 times a second.
231231
* If the processor is not fast enough to maintain the specified rate, the
232-
* frame rate will not be achieved. Setting the frame rate within
232+
* frame rate will not be achieved. Setting the frame rate within
233233
* <a href="#/p5/setup">setup()</a> is recommended. The default frame rate is
234-
* based on the frame rate of the display (here also called "refresh rate"),
234+
* based on the frame rate of the display (here also called "refresh rate"),
235235
* which is set to 60 frames per second on most computers. A frame rate of 24
236-
* frames per second (usual for movies) or above will be enough for smooth
236+
* frames per second (usual for movies) or above will be enough for smooth
237237
* animations. This is the same as setFrameRate(val).
238-
*
238+
*
239239
* Calling <a href="#/p5/frameRate">frameRate()</a> with no arguments returns
240240
* the current framerate. The draw function must run at least once before it will
241241
* return a value. This is the same as <a href="#/p5/getFrameRate">getFrameRate()</a>.
@@ -345,7 +345,7 @@ p5.prototype.setFrameRate = function(fps) {
345345
* </code></div>
346346
*
347347
* @alt
348-
* cursor becomes 10x 10 white ellipse the moves with mouse x and y.
348+
* cursor becomes 10×10 white ellipse the moves with mouse x and y.
349349
*/
350350
p5.prototype.noCursor = function() {
351351
this._curElement.elt.style.cursor = 'none';
@@ -580,8 +580,8 @@ p5.prototype.fullscreen = function(val) {
580580
* </div>
581581
*
582582
* @alt
583-
* fuzzy 50x50 white ellipse with black outline in center of canvas.
584-
* sharp 50x50 white ellipse with black outline in center of canvas.
583+
* fuzzy 50×50 white ellipse with black outline in center of canvas.
584+
* sharp 50×50 white ellipse with black outline in center of canvas.
585585
*/
586586
/**
587587
* @method pixelDensity
@@ -621,7 +621,7 @@ p5.prototype.pixelDensity = function(val) {
621621
* </div>
622622
*
623623
* @alt
624-
* 50x50 white ellipse with black outline in center of canvas.
624+
* 50×50 white ellipse with black outline in center of canvas.
625625
*/
626626
p5.prototype.displayDensity = () => window.devicePixelRatio;
627627

src/core/rendering.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ const defaultClass = 'p5Canvas';
2727
*
2828
* The system variables width and height are set by the parameters passed to this
2929
* function. If <a href="#/p5/createCanvas">createCanvas()</a> is not used, the
30-
* window will be given a default size of 100x100 pixels.
30+
* window will be given a default size of 100×100 pixels.
3131
*
3232
* For more ways to position the canvas, see the
3333
* <a href='https://github.com/processing/p5.js/wiki/Positioning-your-canvas'>

src/core/shape/2d_primitives.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ p5.prototype.arc = function(x, y, w, h, start, stop, mode, detail) {
253253
* </div>
254254
*
255255
* @alt
256-
*white ellipse with black outline in middle-right of canvas that is 55x55
256+
*white ellipse with black outline in middle-right of canvas that is 55×55
257257
*/
258258

259259
/**
@@ -295,7 +295,7 @@ p5.prototype.ellipse = function(x, y, w, h, detailX) {
295295
* </div>
296296
*
297297
* @alt
298-
* white circle with black outline in mid of canvas that is 55x55.
298+
* white circle with black outline in mid of canvas that is 55×55.
299299
*/
300300
p5.prototype.circle = function() {
301301
p5._validateParameters('circle', arguments);
@@ -595,9 +595,9 @@ p5.prototype.quad = function(...args) {
595595
* </div>
596596
*
597597
* @alt
598-
* 55x55 white rect with black outline in mid-right of canvas.
599-
* 55x55 white rect with black outline and rounded edges in mid-right of canvas.
600-
* 55x55 white rect with black outline and rounded edges of different radii.
598+
* 55×55 white rect with black outline in mid-right of canvas.
599+
* 55×55 white rect with black outline and rounded edges in mid-right of canvas.
600+
* 55×55 white rect with black outline and rounded edges of different radii.
601601
*/
602602

603603
/**
@@ -662,9 +662,9 @@ p5.prototype.rect = function() {
662662
* </div>
663663
*
664664
* @alt
665-
* 55x55 white square with black outline in mid-right of canvas.
666-
* 55x55 white square with black outline and rounded edges in mid-right of canvas.
667-
* 55x55 white square with black outline and rounded edges of different radii.
665+
* 55×55 white square with black outline in mid-right of canvas.
666+
* 55×55 white square with black outline and rounded edges in mid-right of canvas.
667+
* 55×55 white square with black outline and rounded edges of different radii.
668668
*/
669669
p5.prototype.square = function(x, y, s, tl, tr, br, bl) {
670670
p5._validateParameters('square', arguments);

src/core/shape/attributes.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ import * as constants from '../constants';
6262
* </div>
6363
*
6464
* @alt
65-
* 60x60 white ellipse and 30x30 grey ellipse with black outlines at center.
66-
* 60x60 white ellipse and 30x30 grey ellipse top-right with black outlines.
65+
* 60×60 white ellipse and 30×30 grey ellipse with black outlines at center.
66+
* 60×60 white ellipse and 30×30 grey ellipse top-right with black outlines.
6767
*/
6868
p5.prototype.ellipseMode = function(m) {
6969
p5._validateParameters('ellipseMode', arguments);
@@ -100,7 +100,7 @@ p5.prototype.ellipseMode = function(m) {
100100
* </div>
101101
*
102102
* @alt
103-
* 2 pixelated 36x36 white ellipses to left & right of center, black background
103+
* 2 pixelated 36×36 white ellipses to left & right of center, black background
104104
*/
105105
p5.prototype.noSmooth = function() {
106106
this.setAttributes('antialias', false);
@@ -165,8 +165,8 @@ p5.prototype.noSmooth = function() {
165165
* </div>
166166
*
167167
* @alt
168-
* 50x50 white rect at center and 25x25 grey rect in the top left of the other.
169-
* 50x50 white rect at center and 25x25 grey rect in the center of the other.
168+
* 50×50 white rect at center and 25×25 grey rect in the top left of the other.
169+
* 50×50 white rect at center and 25×25 grey rect in the center of the other.
170170
*/
171171
p5.prototype.rectMode = function(m) {
172172
p5._validateParameters('rectMode', arguments);
@@ -204,7 +204,7 @@ p5.prototype.rectMode = function(m) {
204204
* </div>
205205
*
206206
* @alt
207-
* 2 pixelated 36x36 white ellipses one left one right of center. On black.
207+
* 2 pixelated 36×36 white ellipses one left one right of center. On black.
208208
*/
209209
p5.prototype.smooth = function() {
210210
this.setAttributes('antialias', true);

src/core/shape/curves.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -476,7 +476,7 @@ p5.prototype.curveTightness = function(t) {
476476
* </code>
477477
* </div>
478478
*
479-
*line hooking down to right-bottom with 13 5x5 white ellipse points
479+
*line hooking down to right-bottom with 13 5×5 white ellipse points
480480
*/
481481
p5.prototype.curvePoint = function(a, b, c, d, t) {
482482
p5._validateParameters('curvePoint', arguments);

src/core/shape/vertex.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ p5.prototype.beginContour = function() {
261261
* 2 white triangle shapes mid-right canvas. left one pointing up and right down.
262262
* 5 horizontal interlocking and alternating white triangles in mid-right canvas.
263263
* 4 interlocking white triangles in 45 degree rotated square-shape.
264-
* 2 white rectangle shapes in mid-right canvas. Both 20x55.
264+
* 2 white rectangle shapes in mid-right canvas. Both 20×55.
265265
* 3 side-by-side white rectangles center rect is smaller in mid-right canvas.
266266
* Thick white l-shape with black outline mid-top-left of canvas.
267267
*/

0 commit comments

Comments
 (0)