Create GraphicalBezierEditor.pde

It looks messy now, but I'm still proud of this piece of code, because it was my final project for my first quarter CPE class. Just nine weeks before writing this, I was a newly-admitted freshman with no real prior programming experience....

The Graphic Bezier Editor is written in and for Processing (http://www.processing.org), a Java-esque language and development tool created to teach programming fundamentals in a visual way. Processing has many built-in ways to display shapes onscreen, including the Bezier curve, which allows for much more complex shapes than can be made with many of the other predefined drawing functions. However, due to the need to define all the shapes with code and coordinates, working with Bezier curves is often tedious and time consuming, and may involve a lot of guesswork, trial, and error.

My program allows the user to define the curves in a WYSIWYG fashion, by left-click-dragging the handles and anchors of the curves across a 400px space (the typical size for a Processing program in our class). The user can add more curves to each shape (by right clicking), add more shapes in separate layers, and add and delete both individual curve segments as well as whole shapes. The user can redefine the origin from which the coordinates of the curves are defined, and to make things easier, the editor also includes buttons to create new curves in the shapes of ellipses, triangles, and quadrilaterals. Not only can the code defining all these shapes be seen in the editor, updated in real time, but it can be copied to the clipboard with one click of a button, ready to define these shapes in a new Processing 'sketch'.