mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-08-10 07:30:08 -04:00
Add a TestField widget that supports a cursor.
This commit is contained in:
parent
5c4e27ea29
commit
4b37f1bb2f
6 changed files with 218 additions and 80 deletions
|
@ -43,7 +43,7 @@ int Painter::draw_char(const Point p, const Style& style, const char c) {
|
|||
}
|
||||
|
||||
int Painter::draw_string(Point p, const Font& font, const Color foreground,
|
||||
const Color background, const std::string text) {
|
||||
const Color background, const std::string& text) {
|
||||
|
||||
bool escape = false;
|
||||
size_t width = 0;
|
||||
|
@ -71,7 +71,7 @@ int Painter::draw_string(Point p, const Font& font, const Color foreground,
|
|||
return width;
|
||||
}
|
||||
|
||||
int Painter::draw_string(Point p, const Style& style, const std::string text) {
|
||||
int Painter::draw_string(Point p, const Style& style, const std::string& text) {
|
||||
return draw_string(p, style.font, style.foreground, style.background, text);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue