From 2c3e96e0cdc1778e9e490189e168743ed9007684 Mon Sep 17 00:00:00 2001 From: Ben Fry Date: Wed, 23 Sep 2020 21:35:11 -0400 Subject: [PATCH] remove extra trailing spaces from the docs import --- core/src/processing/core/PGraphics.java | 222 ++++++++++++------------ core/src/processing/core/PImage.java | 2 +- 2 files changed, 112 insertions(+), 112 deletions(-) diff --git a/core/src/processing/core/PGraphics.java b/core/src/processing/core/PGraphics.java index b53cb0268..3612b7b02 100644 --- a/core/src/processing/core/PGraphics.java +++ b/core/src/processing/core/PGraphics.java @@ -63,7 +63,7 @@ import processing.opengl.PShader; *
* To create a new graphics context, use the createGraphics() function. * Do not use the syntax new PGraphics(). - * + * *

Advanced

Main graphics and rendering context, as well as the base * API implementation. * @@ -1336,13 +1336,13 @@ public class PGraphics extends PImage implements PConstants { /** * - * Defines if textures repeat or draw once within a texture map. - * The two parameters are CLAMP (the default behavior) and REPEAT. + * Defines if textures repeat or draw once within a texture map. + * The two parameters are CLAMP (the default behavior) and REPEAT. * This function only works with the P2D and P3D renderers. * * * @webref image:textures - * @webBrief Defines if textures repeat or draw once within a texture map. + * @webBrief Defines if textures repeat or draw once within a texture map. * @param wrap Either CLAMP (default) or REPEAT * @see PGraphics#texture(PImage) * @see PGraphics#textureMode(int) @@ -1689,18 +1689,18 @@ public class PGraphics extends PImage implements PConstants { // } /** - * Use the beginContour() and endContour() function to - * create negative shapes within shapes such as the center of the - * letter 'O'. beginContour() begins recording vertices for the - * shape and endContour() stops recording. The vertices that - * define a negative shape must "wind" in the opposite direction from - * the exterior shape. First draw vertices for the exterior shape in + * Use the beginContour() and endContour() function to + * create negative shapes within shapes such as the center of the + * letter 'O'. beginContour() begins recording vertices for the + * shape and endContour() stops recording. The vertices that + * define a negative shape must "wind" in the opposite direction from + * the exterior shape. First draw vertices for the exterior shape in * clockwise order, then for internal shapes, draw vertices counterclockwise.
*
- * These functions can only be used within a beginShape()/endShape() - * pair and transformations such as translate(), rotate(), and - * scale() do not work within a beginContour()/endContour() - * pair. It is also not possible to use other shapes, such as ellipse() + * These functions can only be used within a beginShape()/endShape() + * pair and transformations such as translate(), rotate(), and + * scale() do not work within a beginContour()/endContour() + * pair. It is also not possible to use other shapes, such as ellipse() * or rect() within. * * @webref shape:vertex @@ -1712,20 +1712,20 @@ public class PGraphics extends PImage implements PConstants { /** - * Use the beginContour() and endContour() function to - * create negative shapes within shapes such as the center of the - * letter 'O'. beginContour() begins recording vertices for - * the shape and endContour() stops recording. The vertices - * that define a negative shape must "wind" in the opposite direction - * from the exterior shape. First draw vertices for the exterior shape + * Use the beginContour() and endContour() function to + * create negative shapes within shapes such as the center of the + * letter 'O'. beginContour() begins recording vertices for + * the shape and endContour() stops recording. The vertices + * that define a negative shape must "wind" in the opposite direction + * from the exterior shape. First draw vertices for the exterior shape * in clockwise order, then for internal shapes, draw vertices counterclockwise.
*
- * These functions can only be used within a beginShape()/endShape() - * pair and transformations such as translate(), rotate(), and - * scale() do not work within a beginContour()/endContour() - * pair. It is also not possible to use other shapes, such as ellipse() - * or rect() within. - * + * These functions can only be used within a beginShape()/endShape() + * pair and transformations such as translate(), rotate(), and + * scale() do not work within a beginContour()/endContour() + * pair. It is also not possible to use other shapes, such as ellipse() + * or rect() within. + * * @webref shape:vertex * @webBrief Stops recording vertices for the shape. */ @@ -1765,23 +1765,23 @@ public class PGraphics extends PImage implements PConstants { /** - * Loads geometry into a variable of type PShape. SVG and OBJ - * files may be loaded. To load correctly, the file must be located - * in the data directory of the current sketch. In most cases, - * loadShape() should be used inside setup() because + * Loads geometry into a variable of type PShape. SVG and OBJ + * files may be loaded. To load correctly, the file must be located + * in the data directory of the current sketch. In most cases, + * loadShape() should be used inside setup() because * loading shapes inside draw() will reduce the speed of a sketch.
*
- * Alternatively, the file maybe be loaded from anywhere on the local - * computer using an absolute path (something that starts with / on - * Unix and Linux, or a drive letter on Windows), or the filename + * Alternatively, the file maybe be loaded from anywhere on the local + * computer using an absolute path (something that starts with / on + * Unix and Linux, or a drive letter on Windows), or the filename * parameter can be a URL for a file found on a network.
*
- * If the file is not available or an error occurs, null will - * be returned and an error message will be printed to the console. - * The error message does not halt the program, however the null value - * may cause a NullPointerException if your code does not check whether + * If the file is not available or an error occurs, null will + * be returned and an error message will be printed to the console. + * The error message does not halt the program, however the null value + * may cause a NullPointerException if your code does not check whether * the value returned is null.
- * + * * @webref shape * @webBrief Loads geometry into a variable of type PShape. * @param filename name of file to load, can be .svg or .obj @@ -1809,35 +1809,35 @@ public class PGraphics extends PImage implements PConstants { /** - * The createShape() function is used to define a new shape. - * Once created, this shape can be drawn with the shape() - * function. The basic way to use the function defines new primitive - * shapes. One of the following parameters are used as the first - * parameter: ELLIPSE, RECT, ARC, TRIANGLE, - * SPHERE, BOX, QUAD, or LINE. The - * parameters for each of these different shapes are the same as their - * corresponding functions: ellipse(), rect(), arc(), - * triangle(), sphere(), box(), quad(), and + * The createShape() function is used to define a new shape. + * Once created, this shape can be drawn with the shape() + * function. The basic way to use the function defines new primitive + * shapes. One of the following parameters are used as the first + * parameter: ELLIPSE, RECT, ARC, TRIANGLE, + * SPHERE, BOX, QUAD, or LINE. The + * parameters for each of these different shapes are the same as their + * corresponding functions: ellipse(), rect(), arc(), + * triangle(), sphere(), box(), quad(), and * line(). The first example above clarifies how this works.
*
- * Custom, unique shapes can be made by using createShape() without - * a parameter. After the shape is started, the drawing attributes and - * geometry can be set directly to the shape within the beginShape() - * and endShape() methods. See the second example above for specifics, + * Custom, unique shapes can be made by using createShape() without + * a parameter. After the shape is started, the drawing attributes and + * geometry can be set directly to the shape within the beginShape() + * and endShape() methods. See the second example above for specifics, * and the reference for beginShape() for all of its options.
*
- * The createShape() function can also be used to make a complex - * shape made of other shapes. This is called a "group" and it's created by - * using the parameter GROUP as the first parameter. See the fourth + * The createShape() function can also be used to make a complex + * shape made of other shapes. This is called a "group" and it's created by + * using the parameter GROUP as the first parameter. See the fourth * example above to see how it works.
*
- * After using createShape(), stroke and fill color can be set by - * calling methods like setFill() and setStroke(), as seen - * in the examples above. The complete list of methods and fields for the + * After using createShape(), stroke and fill color can be set by + * calling methods like setFill() and setStroke(), as seen + * in the examples above. The complete list of methods and fields for the * PShape class are in the Processing Javadoc. - * + * * @webref shape - * @webBrief The createShape() function is used to define a new shape. + * @webBrief The createShape() function is used to define a new shape. * @see PShape * @see PShape#endShape() * @see PApplet#loadShape(String) @@ -1958,25 +1958,25 @@ public class PGraphics extends PImage implements PConstants { // SHADERS /** - * Loads a shader into the PShader object. The shader file must be - * loaded in the sketch's "data" folder/directory to load correctly. - * Shaders are compatible with the P2D and P3D renderers, but not + * Loads a shader into the PShader object. The shader file must be + * loaded in the sketch's "data" folder/directory to load correctly. + * Shaders are compatible with the P2D and P3D renderers, but not * with the default renderer.
*
- * Alternatively, the file maybe be loaded from anywhere on the local - * computer using an absolute path (something that starts with / on - * Unix and Linux, or a drive letter on Windows), or the filename + * Alternatively, the file maybe be loaded from anywhere on the local + * computer using an absolute path (something that starts with / on + * Unix and Linux, or a drive letter on Windows), or the filename * parameter can be a URL for a file found on a network.
*
- * If the file is not available or an error occurs, null will - * be returned and an error message will be printed to the console. - * The error message does not halt the program, however the null - * value may cause a NullPointerException if your code does not check + * If the file is not available or an error occurs, null will + * be returned and an error message will be printed to the console. + * The error message does not halt the program, however the null + * value may cause a NullPointerException if your code does not check * whether the value returned is null.
* * * @webref rendering:shaders - * @webBrief Loads a shader into the PShader object. + * @webBrief Loads a shader into the PShader object. * @param fragFilename name of fragment shader file */ public PShader loadShader(String fragFilename) { @@ -1996,7 +1996,7 @@ public class PGraphics extends PImage implements PConstants { /** * - * Applies the shader specified by the parameters. It's compatible with + * Applies the shader specified by the parameters. It's compatible with * the P2D and P3D renderers, but not with the default renderer. * * @@ -2019,12 +2019,12 @@ public class PGraphics extends PImage implements PConstants { /** * - * Restores the default shaders. Code that runs after resetShader() + * Restores the default shaders. Code that runs after resetShader() * will not be affected by previously defined shaders. * * * @webref rendering:shaders - * @webBrief Restores the default shaders. + * @webBrief Restores the default shaders. */ public void resetShader() { showMissingWarning("resetShader"); @@ -2125,11 +2125,11 @@ public class PGraphics extends PImage implements PConstants { /** * - * Blends the pixels in the display window according to a defined mode. - * There is a choice of the following modes to blend the source pixels (A) - * with the ones of pixels already in the display window (B). Each pixel's - * final color is the result of applying one of the blend modes with each - * channel of (A) and (B) independently. The red channel is compared with + * Blends the pixels in the display window according to a defined mode. + * There is a choice of the following modes to blend the source pixels (A) + * with the ones of pixels already in the display window (B). Each pixel's + * final color is the result of applying one of the blend modes with each + * channel of (A) and (B) independently. The red channel is compared with * red, green with green, and blue with blue.
*
* BLEND - linear interpolation of colors: C = A*factor + B. This is the default.
@@ -2152,15 +2152,15 @@ public class PGraphics extends PImage implements PConstants { *
* REPLACE - the pixels entirely replace the others and don't utilize alpha (transparency) values
*
- * We recommend using blendMode() and not the previous blend() - * function. However, unlike blend(), the blendMode() function - * does not support the following: HARD_LIGHT, SOFT_LIGHT, OVERLAY, DODGE, - * BURN. On older hardware, the LIGHTEST, DARKEST, and DIFFERENCE modes might - * not be available as well. + * We recommend using blendMode() and not the previous blend() + * function. However, unlike blend(), the blendMode() function + * does not support the following: HARD_LIGHT, SOFT_LIGHT, OVERLAY, DODGE, + * BURN. On older hardware, the LIGHTEST, DARKEST, and DIFFERENCE modes might + * not be available as well. * * * @webref rendering - * @webBrief Blends the pixels in the display window according to a defined mode. + * @webBrief Blends the pixels in the display window according to a defined mode. * @param mode the blending mode to use */ public void blendMode(int mode) { @@ -2289,17 +2289,17 @@ public class PGraphics extends PImage implements PConstants { /** - * Specifies vertex coordinates for quadratic Bezier curves. Each call - * to quadraticVertex() defines the position of one control - * point and one anchor point of a Bezier curve, adding a new segment - * to a line or shape. The first time quadraticVertex() is used - * within a beginShape() call, it must be prefaced with a call - * to vertex() to set the first anchor point. This function must - * be used between beginShape() and endShape() and only - * when there is no MODE parameter specified to beginShape(). - * Using the 3D version requires rendering with P3D (see the Environment + * Specifies vertex coordinates for quadratic Bezier curves. Each call + * to quadraticVertex() defines the position of one control + * point and one anchor point of a Bezier curve, adding a new segment + * to a line or shape. The first time quadraticVertex() is used + * within a beginShape() call, it must be prefaced with a call + * to vertex() to set the first anchor point. This function must + * be used between beginShape() and endShape() and only + * when there is no MODE parameter specified to beginShape(). + * Using the 3D version requires rendering with P3D (see the Environment * reference for more information). - * + * * @webref shape:vertex * @webBrief Specifies vertex coordinates for quadratic Bezier curves. * @param cx the x-coordinate of the control point @@ -2643,7 +2643,7 @@ public class PGraphics extends PImage implements PConstants { * counter-clockwise around the defined shape. * * @webref shape:2d_primitives - * @webBrief A quad is a quadrilateral, a four sided polygon. + * @webBrief A quad is a quadrilateral, a four sided polygon. * @param x1 x-coordinate of the first corner * @param y1 y-coordinate of the first corner * @param x2 x-coordinate of the second corner @@ -3102,7 +3102,7 @@ public class PGraphics extends PImage implements PConstants { * function. * * @webref shape:2d_primitives - * @webBrief Draws a circle to the screen. + * @webBrief Draws a circle to the screen. * @param x x-coordinate of the ellipse * @param y y-coordinate of the ellipse * @param extent width and height of the ellipse by default @@ -4338,7 +4338,7 @@ public class PGraphics extends PImage implements PConstants { * the font. * * - * + * * @webref typography:attributes * @webBrief Sets the current alignment for drawing text. * @param alignX horizontal alignment, either LEFT, CENTER, or RIGHT @@ -5713,7 +5713,7 @@ public class PGraphics extends PImage implements PConstants { * * @webref transform * @webBrief Shears a shape around the x-axis the amount specified by the - * angle parameter. + * angle parameter. * @param angle angle of shear specified in radians * @see PGraphics#popMatrix() * @see PGraphics#pushMatrix() @@ -6004,7 +6004,7 @@ public class PGraphics extends PImage implements PConstants { * * * @webref lights_camera:camera - * @webBrief Sets the position of the camera. + * @webBrief Sets the position of the camera. * @see PGraphics#beginCamera() * @see PGraphics#endCamera() * @see PGraphics#frustum(float, float, float, float, float, float) @@ -6106,7 +6106,7 @@ public class PGraphics extends PImage implements PConstants { * * @webref lights_camera:camera * @webBrief Sets a perspective projection applying foreshortening, making distant - * objects appear smaller than closer ones. + * objects appear smaller than closer ones. */ public void perspective() { showMissingWarning("perspective"); @@ -7204,7 +7204,7 @@ public class PGraphics extends PImage implements PConstants { * * @webref lights_camera:lights * @webBrief Sets the default ambient light, directional light, falloff, and specular - * values. + * values. * @usage web_application * @see PGraphics#ambientLight(float, float, float, float, float, float) * @see PGraphics#directionalLight(float, float, float, float, float, float) @@ -7568,14 +7568,14 @@ public class PGraphics extends PImage implements PConstants { } /** - * Clears the pixels within a buffer. This function only works on - * PGraphics objects created with the createGraphics() - * function. Unlike the main graphics context (the display window), - * pixels in additional graphics areas created with createGraphics() - * can be entirely or partially transparent. This function clears - * everything in a PGraphics object to make all of the pixels + * Clears the pixels within a buffer. This function only works on + * PGraphics objects created with the createGraphics() + * function. Unlike the main graphics context (the display window), + * pixels in additional graphics areas created with createGraphics() + * can be entirely or partially transparent. This function clears + * everything in a PGraphics object to make all of the pixels * 100% transparent. - * + * * @webref color:setting * @webBrief Clears the pixels within a buffer. */ @@ -8075,7 +8075,7 @@ public class PGraphics extends PImage implements PConstants { * example, the following two lines of code are equivalent means of getting the * red value of the color value c:
*
- * + * *
    * float r1 = red(c); // Simpler, but slower to calculate
    * float r2 = c >> 16 & 0xFF; // Very fast to calculate
@@ -8115,7 +8115,7 @@ public class PGraphics extends PImage implements PConstants {
    * example, the following two lines of code are equivalent means of getting the
    * green value of the color value c:
*
- * + * *
    * float g1 = green(c); // Simpler, but slower to calculate
    * float g2 = c >> 8 & 0xFF; // Very fast to calculate
@@ -8155,7 +8155,7 @@ public class PGraphics extends PImage implements PConstants {
    * the following two lines of code are equivalent means of getting the blue
    * value of the color value c:
*
- * + * *
    * float b1 = blue(c); // Simpler, but slower to calculate
    * float b2 = c & 0xFF; // Very fast to calculate
diff --git a/core/src/processing/core/PImage.java b/core/src/processing/core/PImage.java
index 34cb6c146..a49a0687c 100644
--- a/core/src/processing/core/PImage.java
+++ b/core/src/processing/core/PImage.java
@@ -414,7 +414,7 @@ public class PImage implements PConstants, Cloneable {
    * is not currently used by any of the renderers, however the api is structured
    * this way in the hope of being able to use this to speed things up in the
    * future.
-   * 
+   *
    * @webref pimage:pixels
    * @webBrief Updates the image with the data in its pixels[] array.
    * @usage web_application