diff --git a/src/utilities/conversion.js b/src/utilities/conversion.js index b640b4bd53..983d7ce61b 100644 --- a/src/utilities/conversion.js +++ b/src/utilities/conversion.js @@ -24,15 +24,13 @@ import p5 from '../core/main'; * let str = '20'; * let diameter = float(str); * ellipse(width / 2, height / 2, diameter, diameter); + * describe('20-by-20 white ellipse in the center of the canvas'); * *
* print(float('10.31')); // 10.31
* print(float('Infinity')); // Infinity
* print(float('-Infinity')); // -Infinity
*
* let string = trim(' No new lines\n ');
* text(string + ' here', 2, 50);
+ * describe('“No new lines here” displayed center canvas');
*
*
- *
- * @alt
- * "No new lines here" displayed center canvas
*/
/**
* @method trim
diff --git a/src/utilities/time_date.js b/src/utilities/time_date.js
index 62f752bc92..827682bd30 100644
--- a/src/utilities/time_date.js
+++ b/src/utilities/time_date.js
@@ -18,11 +18,9 @@ import p5 from '../core/main';
*
* let d = day();
* text('Current day: \n' + d, 5, 50);
+ * describe('Current day is displayed');
*
*
- *
- * @alt
- * Current day is displayed
*/
p5.prototype.day = function() {
return new Date().getDate();
@@ -39,11 +37,9 @@ p5.prototype.day = function() {
*
* let h = hour();
* text('Current hour:\n' + h, 5, 50);
+ * describe('Current hour is displayed');
*
*
- *
- * @alt
- * Current hour is displayed
*/
p5.prototype.hour = function() {
return new Date().getHours();
@@ -60,11 +56,9 @@ p5.prototype.hour = function() {
*
* let m = minute();
* text('Current minute: \n' + m, 5, 50);
+ * describe('Current minute is displayed');
*
*
- *
- * @alt
- * Current minute is displayed
*/
p5.prototype.minute = function() {
return new Date().getMinutes();
@@ -82,11 +76,9 @@ p5.prototype.minute = function() {
*
* let millisecond = millis();
* text('Milliseconds \nrunning: \n' + millisecond, 5, 40);
+ * describe('number of milliseconds since sketch has started displayed');
*
*
- *
- * @alt
- * number of milliseconds since sketch has started displayed
*/
p5.prototype.millis = function() {
if (this._millisStart === -1) {
@@ -108,11 +100,9 @@ p5.prototype.millis = function() {
*
* let m = month();
* text('Current month: \n' + m, 5, 50);
+ * describe('Current month is displayed');
*
*
- *
- * @alt
- * Current month is displayed
*/
p5.prototype.month = function() {
//January is 0!
@@ -130,11 +120,9 @@ p5.prototype.month = function() {
*
* let s = second();
* text('Current second: \n' + s, 5, 50);
+ * describe('Current second is displayed');
*
*
- *
- * @alt
- * Current second is displayed
*/
p5.prototype.second = function() {
return new Date().getSeconds();
@@ -151,11 +139,9 @@ p5.prototype.second = function() {
*
* let y = year();
* text('Current year: \n' + y, 5, 50);
+ * describe('Current year is displayed');
*
*
- *
- * @alt
- * Current year is displayed
*/
p5.prototype.year = function() {
return new Date().getFullYear();