Auf letztere gehen wir später noch ein. To set the color of an HTML5 Canvas line, we can use the strokeStyle property of the canvas context, which can be set to a color string such as red, green, or blue, a hex value such as #FF0000 or #555, or an RGB value such as rgb(255, 0, 0). 17+ Chat Box CSS Examples with Source Code . color steht entweder für einen CSS Farbwert, ein Gradienten-Objekt, oder ein Muster-Objekt. Following is a simple example which makes use of the above-mentioned fillStyle attribute to create a nice pattern. HTML5 canvas provides the following two important properties to apply colors to a shape −. HTML5 Canvas Text Font, Size, and Style Tutorial. HTML5 Canvas Text tutorial: In HTML5, canvas?element supports basic text rendering on a line-by-line basis. This can be used to draw scaled down or enlarged shapes and bitmaps. When selecting an optimization strategy, be aware of any trade-offs of using that strategy. A canvas is a rectangular area on an HTML page. To learn more about