ArduinoDumbDisplay v0.9.9-r41
DumbDisplay Arduino Library -- https://github.com/trevorwslee/Arduino-DumbDisplay
 
Loading...
Searching...
No Matches
SelectionListLayerWrapper Class Reference

wrapper for using of SelectionListLayerWrapper that help you to track the text added More...

#include <_dd_misc.h>

Public Member Functions

 SelectionListLayerWrapper (short bufferSizeInc=2)
 
SelectionListDDLayerinitializeLayer (DumbDisplay &dumbdisplay, int colCount, int rowCount, int horiSelectionCount, int vertSelectionCount, int charHeight=0, const String &fontName="", bool canDrawDots=true, float selectionBorderSizeCharHeightFactor=0.3)
 initialize a new SelectionListDDLayer (note that any old ones will not be deleted)
 
SelectionListDDLayergetLayer ()
 
int getOffset ()
 
int getSelectionCount ()
 
int getSelectionIndexFromView (int horiSelectionIdx, int vertSelectionIdx)
 
const String & getSelectionText (int selectionIdx)
 
int findSelection (const String &text)
 
void setListStateChangedCallback (void(*listStateChangedCallback)())
 set the "list state changed" callback; here "state" refers to "list add/remove text or change of offset"
 
int addSelection (int selectionIdx, const String &text, const String &align="L")
 
int removeSelection (int selectionIdx)
 
void removeAllSelections ()
 
void setOffset (int offset)
 
void incrementOffset ()
 
void decrementOffset ()
 
void scrollToView (int selectionIdx)
 
void select (int selectionIdx, bool deselectTheOthers=true)
 
void deselect (int selectionIdx, bool selectTheOthers=false)
 
void selected (int selectionIdx, bool selected, bool reverseTheOthers=false)
 
void selectAll ()
 
void deselectAll ()
 

Detailed Description

wrapper for using of SelectionListLayerWrapper that help you to track the text added

Member Function Documentation

◆ addSelection()

int SelectionListLayerWrapper::addSelection ( int  selectionIdx,
const String &  text,
const String &  align = "L" 
)
inline
Parameters
selectionIdx-1 means append as the last selection
Returns
-1 if selectionIdx is out of range

◆ removeSelection()

int SelectionListLayerWrapper::removeSelection ( int  selectionIdx)
inline
Parameters
selectionIdx-1 means the last selection
Returns
-1 if selectionIdx is out of range