Skip to content

Commit 7c2e472

Browse files
committed
Changing doclets for exceptions to the PGraphics class and fixing comments
1 parent 3927123 commit 7c2e472

File tree

4 files changed

+13
-7
lines changed

4 files changed

+13
-7
lines changed

core/src/processing/core/PApplet.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -259,13 +259,13 @@ public class PApplet implements PConstants {
259259

260260
/**
261261
*
262-
* When <b>pixelDensity(2)</d> is used to make use of a high resolution
262+
* When <b>pixelDensity(2)</b> is used to make use of a high resolution
263263
* display (called a Retina display on OS X or high-dpi on Windows and
264264
* Linux), the width and height of the sketch do not change, but the
265265
* number of pixels is doubled. As a result, all operations that use pixels
266266
* (like <b>loadPixels()</b>, <b>get()</b>, <b>set()</b>, etc.) happen
267267
* in this doubled space. As a convenience, the variables <b>pixelWidth</b>
268-
* and <b>pixelHeight<b> hold the actual width and height of the sketch
268+
* and <b>pixelHeight</b> hold the actual width and height of the sketch
269269
* in pixels. This is useful for any sketch that uses the <b>pixels[]</b>
270270
* array, for instance, because the number of elements in the array will
271271
* be <b>pixelWidth*pixelHeight</b>, not <b>width*height</b>.
@@ -282,13 +282,13 @@ public class PApplet implements PConstants {
282282

283283
/**
284284
*
285-
* When <b>pixelDensity(2)</d> is used to make use of a high resolution
285+
* When <b>pixelDensity(2)</b> is used to make use of a high resolution
286286
* display (called a Retina display on OS X or high-dpi on Windows and
287287
* Linux), the width and height of the sketch do not change, but the
288288
* number of pixels is doubled. As a result, all operations that use pixels
289289
* (like <b>loadPixels()</b>, <b>get()</b>, <b>set()</b>, etc.) happen
290290
* in this doubled space. As a convenience, the variables <b>pixelWidth</b>
291-
* and <b>pixelHeight<b> hold the actual width and height of the sketch
291+
* and <b>pixelHeight</b> hold the actual width and height of the sketch
292292
* in pixels. This is useful for any sketch that uses the <b>pixels[]</b>
293293
* array, for instance, because the number of elements in the array will
294294
* be <b>pixelWidth*pixelHeight</b>, not <b>width*height</b>.

doclet/ReferenceGenerator/processingrefBuild.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ REFERENCES_OUT_PATH=../../../processing-website/content/references/translations/
1111
echo "[REFERENCE GENERATOR] Source Path :: $PROCESSING_SRC_PATH"
1212
echo "[REFERENCE GENERATOR] Library Path :: $PROCESSING_LIB_PATH"
1313

14-
# You can pass one argument "sound" or "video" (without the "") to generate those libraries separately
14+
# You can pass one argument "sound" or "video" to generate those libraries separately
1515
# or "processing" to generate the core without the sound and video libraries
1616
# if there is no argument it will generate everything
1717
if [ $# -eq 0 ]

doclet/ReferenceGenerator/src/writers/ClassWriter.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,10 @@ public void write( ClassDoc classDoc ) throws IOException {
7777

7878
for (MethodDoc m : classDoc.methods()) {
7979
if(needsWriting(m)){
80-
MethodWriter.write((HashMap<String, String>)vars.clone(), m, classname, folderName);
81-
methodSet.add(getPropertyInfo(m));
80+
if (!classname.equals("PGraphics") || getName(m).equals("beginDraw()") || getName(m).equals("endDraw()")) {
81+
MethodWriter.write((HashMap<String, String>)vars.clone(), m, classname, folderName);
82+
methodSet.add(getPropertyInfo(m));
83+
}
8284
}
8385
}
8486

doclet/ReferenceGenerator/src/writers/MethodWriter.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@ public static void write( HashMap<String, String> vars, MethodDoc doc, String cl
3535
String category = getCategory(tags[0]);
3636
String subcategory = getSubcategory(tags[0]);
3737

38+
if (!classname.equals("PGraphics") || getName(doc).equals("beginDraw()") || getName(doc).equals("endDraw()")) {
39+
3840
try
3941
{
4042
methodJSON.put("type", "method");
@@ -72,6 +74,8 @@ public static void write( HashMap<String, String> vars, MethodDoc doc, String cl
7274
} catch (IOException e) {
7375
e.printStackTrace();
7476
}
77+
78+
}
7579
}
7680

7781
}

0 commit comments

Comments
 (0)