processing / p5.js

p5.js is a client-side JS platform that empowers artists, designers, students, and anyone to learn to code and express themselves creatively on the web. It is based on the core principles of Processing. http://twitter.com/p5xjs —
http://p5js.org/
GNU Lesser General Public License v2.1
21.08k stars 3.22k forks source link

inconsistent parameter handling #7078

Open rrshaban opened 3 weeks ago

rrshaban commented 3 weeks ago

Most appropriate sub-area of p5.js?

p5.js version

web version

Web browser and version

124.0

Operating system

OSX

Steps to reproduce this

documentation in general would highly benefit from traditional parameter notation; e.g. "Stroke(color) Stroke(color, alpha) Stroke(r, g, b) Stroke(r, g, b, alpha) Stroke(rgb) Stroke(rgb, alpha) < this one I tried and it broke "

is this a javascript thing?

welcome[bot] commented 3 weeks ago

Welcome! 👋 Thanks for opening your first issue here! And to ensure the community is able to respond to your issue, please make sure to fill out the inputs in the issue forms. Thank you!

limzykenneth commented 3 weeks ago

Hi @rrshaban, stroke(rgb, alpha) is not a supported parameter signature as documented in the reference. The supported options are

stroke(v1, v2, v3, [alpha])

stroke(value)

stroke(gray, [alpha])

stroke(values)

stroke(color)

Did you find stroke(rgb, alpha) somewhere?