EhhLang Help

Circle

Creating a Circle

You can create a circle by using the circle keyword followed by the radius of the circle. For example, to create a circle at position (100, 100) with a radius of 50 and white color, you can use the following code:

ehh { width: 840 height: 480 background: 0, 0, 0 output: "circle.png" } circle { position: 100, 100 radius: 50 color: 255, 255, 255 thickness: 5 }

Output:

Circle

In the above example, we have created a circle at position (100, 100) with a radius of 50 and white color.

Properties

The circle has the following properties:

  • position: The position of the circle. The position is specified in the format X, Y.

  • radius: The radius of the circle.

  • color: The color of the circle. The color is specified in RGB format R, G, B.

  • thickness: The thickness of the circle. The default thickness is 1.

  • fillColor: The fill color of the circle. The fill color is specified in RGB format R, G, B. If not specified, the circle will be hollow. It can be set to no if it is inherited from a circle that has fill color and the current object doesn't want to inherit it.

Conclusion

A circle is a simple shape that is the set of all points in a plane that are at a given distance from a given point, the centre. You can create a circle in Ehhlang using the circle keyword and specify the position, radius, color, thickness, and fill color of the circle. This helps you to create images with different circles and colors.

Last modified: 25 February 2024