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

Class for 7-segment row layer; created with DumbDisplay::create7SegmentRowLayer() More...

#include <dumbdisplay.h>

Inheritance diagram for SevenSegmentRowDDLayer:
DDLayer DDObject

Public Member Functions

 SevenSegmentRowDDLayer (int8_t layerId)
 for internal use only
 
void segmentColor (const String &color)
 
void resetSegmentOffColor (const String &color)
 
void resetSegmentOffNoColor ()
 reset segment off color to no color; note that this will clear all digits
 
void turnOn (const String &segments, int digitIdx=0)
 
void turnOff (const String &segments, int digitIdx=0)
 
void setOn (const String &segments="", int digitIdx=0)
 
void showDigit (int digit, int digitIdx=0)
 show a digit
 
void showNumber (float number, const String &padding=" ")
 show number (can be float)
 
void showHexNumber (int16_t number)
 show HEX number
 
void showFormatted (const String &formatted, bool completeReplace=true, int startIdx=0)
 
- Public Member Functions inherited from DDLayer
void border (float size, const String &color, const String &shape="flat", float extraSize=0)
 
void noBorder ()
 
void padding (float size)
 
void padding (float left, float top, float right, float bottom)
 
void noPadding ()
 
void margin (float size)
 
void margin (float left, float top, float right, float bottom)
 
void noMargin ()
 
void backgroundColor (const String &color, int opacity=100)
 
void noBackgroundColor ()
 
void visible (bool visible)
 
void transparent (bool transparent)
 
void disabled (bool disabled=true)
 
void opacity (int opacity)
 
void alpha (int alpha)
 
void blend (const String &color, int alpha=255, const String &mode="darken")
 
void noblend ()
 
void clear ()
 clear the layer
 
void flash ()
 normally used for "feedback" – flash the default way (layer + border)
 
void flashArea (int x, int y)
 normally used for "feedback" – flash the area (x, y) where the layer is clicked
 
void explicitFeedback (int16_t x=0, int16_t y=0, const String &text="", DDFeedbackType type=CLICK, const String &option="")
 
const String & getLayerId () const
 
void setFeedbackHandler (DDFeedbackHandler handler, const String &autoFeedbackMethod="", const String &allowFeedbackTypes="")
 
void enableFeedback (const String &autoFeedbackMethod="", const String &allowFeedbackTypes="")
 
void disableFeedback ()
 disable "feedback"
 
const DDFeedbackgetFeedback ()
 
void debugOnly (int i)
 for debug use
 
DDFeedbackManager * getFeedbackManager () const
 
DDFeedbackHandler getFeedbackHandler () const
 

Additional Inherited Members

- Public Attributes inherited from DDObject
int8_t objectType
 object type – DD_OBJECT_TYPE_LAYER or DD_OBJECT_TYPE_TUNNEL
 
String customData
 custom data
 
- Protected Member Functions inherited from DDLayer
 DDLayer (int8_t layerId)
 
void _enableFeedback ()
 
- Protected Attributes inherited from DDLayer
String layerId
 
DDFeedbackManager * pFeedbackManager
 
DDFeedbackHandler feedbackHandler
 

Detailed Description

Class for 7-segment row layer; created with DumbDisplay::create7SegmentRowLayer()

Member Function Documentation

◆ resetSegmentOffColor()

void SevenSegmentRowDDLayer::resetSegmentOffColor ( const String &  color)

reset segment off color; note that this will clear all digits

Parameters
colorDD_COLOR_XXX; DD_RGB_COLOR(...); can also be common "color name"

◆ segmentColor()

void SevenSegmentRowDDLayer::segmentColor ( const String &  color)

set segment color

Parameters
colorDD_COLOR_XXX; DD_RGB_COLOR(...); can also be common "color name"

◆ setOn()

void SevenSegmentRowDDLayer::setOn ( const String &  segments = "",
int  digitIdx = 0 
)

like turnOn(), except that the digit will be cleared first

Parameters
segmentsempty segments basically means turn all segments of the digit off

◆ showFormatted()

void SevenSegmentRowDDLayer::showFormatted ( const String &  formatted,
bool  completeReplace = true,
int  startIdx = 0 
)

show formatted number (even number with hex digits); e.g. "12.00", "00.34", "-.12", "0ff"

◆ turnOff()

void SevenSegmentRowDDLayer::turnOff ( const String &  segments,
int  digitIdx = 0 
)

turn off one or more segments

Parameters
segmentseach character represents a segment to turn on – 'a', 'b', 'c', 'd', 'e', 'f', 'g', '.'

◆ turnOn()

void SevenSegmentRowDDLayer::turnOn ( const String &  segments,
int  digitIdx = 0 
)

turn on one or more segments

Parameters
segmentseach character represents a segment to turn on – 'a', 'b', 'c', 'd', 'e', 'f', 'g', '.'