Clears all pixel in the memory frame buffer.
See u8g2 clearBuffer().
Draw a box (filled frame).
See u8g2 drawBox().
Draw a circle.
See u8g2 drawCircle().
Note that parameter opt
is optional and defaults to u8g2.DRAW_ALL
if omitted.
Draw a filled circle.
See u8g2 drawDisc().
Note that parameter opt
is optional and defaults to u8g2.DRAW_ALL
if omitted.
Draw an ellipse.
See u8g2 drawEllipse().
Note that parameter opt
is optional and defaults to u8g2.DRAW_ALL
if omitted.
Draw a filled ellipse.
Note that parameter opt
is optional and defaults to u8g2.DRAW_ALL
if omitted.
Draw a frame (empty box).
See u8g2 drawFrame().
Draw a single character.
See u8g2 drawGlyph().
Draw a horizontal line.
See u8g2 drawHLine().
Draw a line between two points.
See u8g2 drawLine().
Draw a pixel.
See u8g2 drawPixel().
Draw a box with round edges.
See u8g2 drawRBox().
Draw a frame with round edges.
See u8g2 drawRFrame().
Draw a string.
See u8g2 drawStr().
Draw a triangle (filled polygon).
See u8g2 drawTriangle().
Draw a string which is encoded as UTF-8.
See u8g2 drawUTF8().
Draw a vertical line.
See u8g2 drawVLine().
Draw a XBM Bitmap.
See u8g2 drawXBM().
XBM bitmaps are supplied as strings to drawXBM()
. This off-loads all data handling from the u8g2 module to generic methods for binary files. See graphics_test.lua.
In contrast to the source code based inclusion of XBMs in upstream u8g2 library, it’s required to provide precompiled binary files. This can be performed online with Online-Utility’s Image Converter: Convert from XBM to MONO format and upload the binary result.
Returns the reference height of the glyphs above the baseline (ascent).
See u8g2 getAscent().
Returns the reference height of the glyphs below the baseline (descent).
See u8g2 getDescent().
Return the pixel width of string.
See u8g2 getStrWidth().
Return the pixel width of an UTF-8 encoded string.
See u8g2 getUTF8Width().
Send the content of the memory frame buffer to the display.
See u8g2 sendBuffer().
Define bitmap background color mode.
See u8g2 setBitmapMode().
Set the contrast or brightness.
See u8g2 setContrast().
Changes the display rotation.
See u8g2 setDisplayRotation().
Defines the bit value (color index) for all drawing functions.
See u8g2 setDrawColor().
Set flip (180 degree rotation) mode.
See u8g2 setFlipMode().
Define a u8g2 font for the glyph and string drawing functions. They can be supplied as strings or compiled into the firmware image. They are available as u8g2.<font_name>
in Lua.
See u8g2 setFont().
Set the drawing direction of all strings or glyphs.
Define font background color mode.
See u8g2 setFontMode().
Change the reference position for the glyph and string draw functions to «baseline».
See u8g2 setFontPosBaseline().
Change the reference position for the glyph and string draw functions to «bottom».
Change the reference position for the glyph and string draw functions to «top».
See u8g2 setFontPosTop().
Change the reference position for the glyph and string draw functions to «center».
Set ascent and descent calculation mode to «highest and lowest glyph».
See u8g2 setFontRefHeightAll().
Set ascent and descent calculation mode to «highest of [A1(], lowest of [g(]«.
See u8g2 setFontRefHeightExtendedText().
Set ascent and descent calculation mode to «highest of [A1], lowest of [g]«.
See u8g2 setFontRefHeightText().
Activate or disable power save mode of the display.
See u8g2 setPowerSave().