FabGL
ESP32 Display Controller and Graphics Library

◆ clear()

void clear ( bool  moveCursor = true)

Clears the screen.

Clears the screen sending "CSI 2 J" command to the screen.

Parameters
moveCursorIf True moves cursor at position 1, 1.

Example:

// Fill the screen with blue
Terminal.setBackgroundColor(Color::Blue);
Terminal.clear();
Examples
SSD1306_OLED/128x64/NetworkTerminal/NetworkTerminal.ino, SSD1306_OLED/128x64/RTClock/RTClock.ino, VGA/Altair8800/Altair8800.ino, VGA/AnsiTerminal/AnsiTerminal.ino, VGA/LoopbackTerminal/LoopbackTerminal.ino, VGA/NetworkTerminal/NetworkTerminal.ino, VGA/Songs/Songs.ino, and VGA/SoundChipSimulator/SoundChipSimulator.ino.

Definition at line 1010 of file terminal.cpp.