Deluge Firmware
1.3.0
Build date: 2025.04.16
Loading...
Searching...
No Matches
integer.h
1
/*
2
* Copyright © 2014-2023 Synthstrom Audible Limited
3
*
4
* This file is part of The Synthstrom Audible Deluge Firmware.
5
*
6
* The Synthstrom Audible Deluge Firmware is free software: you can redistribute it and/or modify it under the
7
* terms of the GNU General Public License as published by the Free Software Foundation,
8
* either version 3 of the License, or (at your option) any later version.
9
*
10
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
11
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
12
* See the GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License along with this program.
15
* If not, see <https://www.gnu.org/licenses/>.
16
*/
17
18
#pragma once
19
20
#include "number.h"
21
22
namespace
deluge::gui::menu_item {
23
24
class
Integer
:
public
Number
{
25
public
:
26
using
Number::Number;
27
void
selectEncoderAction
(int32_t offset)
override
;
28
29
protected
:
30
virtual
int32_t getDisplayValue() {
return
this->getValue(); }
31
virtual
const
char
* getUnit() {
return
""
; }
32
33
void
drawPixelsForOled
();
34
virtual
void
drawInteger(int32_t textWidth, int32_t textHeight, int32_t yPixel);
35
36
// 7Seg Only
37
void
drawValue()
override
;
38
};
39
40
class
IntegerWithOff
:
public
Integer
{
41
public
:
42
using
Integer::Integer;
43
void
drawPixelsForOled
()
override
;
44
45
// 7Seg Only
46
void
drawValue()
override
;
47
};
48
49
class
IntegerContinuous
:
public
Integer
{
50
public
:
51
using
Integer::Integer;
52
53
protected
:
54
void
drawPixelsForOled
();
55
};
56
57
}
// namespace deluge::gui::menu_item
deluge::gui::menu_item::IntegerContinuous
Definition
integer.h:49
deluge::gui::menu_item::IntegerContinuous::drawPixelsForOled
void drawPixelsForOled()
Paints the pixels below the standard title block.
Definition
integer.cpp:75
deluge::gui::menu_item::IntegerWithOff
Definition
integer.h:40
deluge::gui::menu_item::IntegerWithOff::drawPixelsForOled
void drawPixelsForOled() override
Paints the pixels below the standard title block.
Definition
integer.cpp:53
deluge::gui::menu_item::Integer
Definition
integer.h:24
deluge::gui::menu_item::Integer::selectEncoderAction
void selectEncoderAction(int32_t offset) override
Handle select encoder movement.
Definition
integer.cpp:25
deluge::gui::menu_item::Integer::drawPixelsForOled
void drawPixelsForOled()
Paints the pixels below the standard title block.
Definition
integer.cpp:71
deluge::gui::menu_item::Number
Definition
number.h:24