LiquidMenu
1.6.0
Menu creation Arduino library for LCDs, wraps LiquidCrystal.
|
Represents a screen shown on the display. More...
#include <LiquidMenu.h>
Public Member Functions | |
Constructors | |
LiquidScreen () | |
The main constructor. More... | |
LiquidScreen (LiquidLine &liquidLine) | |
Constructor for 1 LiquidLine object. More... | |
LiquidScreen (LiquidLine &liquidLine1, LiquidLine &liquidLine2) | |
Constructor for 2 LiquidLine object. More... | |
LiquidScreen (LiquidLine &liquidLine1, LiquidLine &liquidLine2, LiquidLine &liquidLine3) | |
Constructor for 3 LiquidLine object. More... | |
LiquidScreen (LiquidLine &liquidLine1, LiquidLine &liquidLine2, LiquidLine &liquidLine3, LiquidLine &liquidLine4) | |
Constructor for 4 LiquidLine object. More... | |
Public methods | |
bool | add_line (LiquidLine &liquidLine) |
Adds a LiquidLine object to the screen. More... | |
bool | set_focusPosition (Position position) |
Sets the focus position for the whole screen at once. More... | |
void | set_displayLineCount (uint8_t lineCount) |
Specifies the line size of the display (required for scrolling). More... | |
void | hide (bool hide) |
Hides the screen. More... | |
Friends | |
class | LiquidMenu |
Represents a screen shown on the display.
A screen is made up of LiquidLine objects. It holds pointers to them and calls their functions when it is active. It also knows on which line the focus is. This classes' objects go into a LiquidMenu object which controls them. The public methods are for configuration only.
LiquidScreen::LiquidScreen | ( | ) |
The main constructor.
This is the main constructor that gets called every time.
|
explicit |
Constructor for 1 LiquidLine object.
&liquidLine | - pointer to a LiquidLine object |
LiquidScreen::LiquidScreen | ( | LiquidLine & | liquidLine1, |
LiquidLine & | liquidLine2 | ||
) |
Constructor for 2 LiquidLine object.
&liquidLine1 | - pointer to a LiquidLine object |
&liquidLine2 | - pointer to a LiquidLine object |
LiquidScreen::LiquidScreen | ( | LiquidLine & | liquidLine1, |
LiquidLine & | liquidLine2, | ||
LiquidLine & | liquidLine3 | ||
) |
Constructor for 3 LiquidLine object.
&liquidLine1 | - pointer to a LiquidLine object |
&liquidLine2 | - pointer to a LiquidLine object |
&liquidLine3 | - pointer to a LiquidLine object |
LiquidScreen::LiquidScreen | ( | LiquidLine & | liquidLine1, |
LiquidLine & | liquidLine2, | ||
LiquidLine & | liquidLine3, | ||
LiquidLine & | liquidLine4 | ||
) |
Constructor for 4 LiquidLine object.
&liquidLine1 | - pointer to a LiquidLine object |
&liquidLine2 | - pointer to a LiquidLine object |
&liquidLine3 | - pointer to a LiquidLine object |
&liquidLine4 | - pointer to a LiquidLine object |
bool LiquidScreen::add_line | ( | LiquidLine & | liquidLine | ) |
Adds a LiquidLine object to the screen.
&liquidLine | - pointer to a LiquidLine object |
MAX_LINES
. The default is 8.void LiquidScreen::hide | ( | bool | hide | ) |
Hides the screen.
Hiding a screen means that it will be skipped when cycling the screens.
hide | - true for hiding and false for unhiding |
change_screen
methods.void LiquidScreen::set_displayLineCount | ( | uint8_t | lineCount | ) |
Specifies the line size of the display (required for scrolling).
This is required when you want to add more lines (LiquidLine objects) to a screen (LiquidScreen object) than the display's line size. The lines will be scrolled.
lineCount | - the line size of the display |
bool LiquidScreen::set_focusPosition | ( | Position | position | ) |
Sets the focus position for the whole screen at once.
The valid positions are LEFT
and RIGHT
. CUSTOM
is not valid for this function because it needs individual column and row for every line.
position | - LEFT or RIGHT |
Position
is enum class. Use Position::(member)
when specifying the position.