@epikao , I ran into the same confusion for a bit. It wasn’t quite clear to me what things were supported in the canvas and what things were not. I wound up wrapping up the canvas concept in two C++ classes lvppCanvasFullColor and lvppCanvasIndexed which handle these big ‘switches’ between the two modes. The Indexed version of the canvas class does allow for drawing lines and rectangles, but in a less feature rich manner than the full color support - at least today.
These are part of a library that I just made public yesterday. If you’re interested in a C++ wrapper for canvas as well as much of the LVGL library, have a look at my My Project intro topic here on the forums or go directly to the Github project at LVGLPlusPlus and its associated Doxygen Docs for LVGLPlusPlus
Happy to hear feedback if there’s no flame throwers involved.
–bob