Skip to content

Commit 2ea89cd

Browse files
committed
upd
1 parent 5858bd0 commit 2ea89cd

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,9 @@
4444
// ====== КОНСТРУКТОР ======
4545
su::Text(String& str);
4646
su::Text(const String& str);
47-
su::Text(const __FlashStringHelper* str, int16_t len = 0);
47+
su::Text(const uint8_t* str, uint16_t len);
4848
su::Text(const char* str, int16_t len = 0, bool pgm = 0);
49+
su::Text(const __FlashStringHelper* str, int16_t len = 0);
4950

5051
// ======== СИСТЕМА ========
5152
bool valid(); // Статус строки, существует или нет

library.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name=StringUtils
2-
version=1.4.1
2+
version=1.4.2
33
author=AlexGyver <alex@alexgyver.ru>
44
maintainer=AlexGyver <alex@alexgyver.ru>
55
sentence=Bunch of converting functions for string data

src/utils/Text.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ class Text : public Printable {
2626
Text() {}
2727
Text(const __FlashStringHelper* str, int16_t len = -1) : _str((PGM_P)str), _len(len >= 0 ? len : strlen_P((PGM_P)str)), _type(Type::pgmChar) {}
2828
Text(const char* str, int16_t len = -1, bool pgm = 0) : _str(str), _len(len >= 0 ? len : (pgm ? strlen_P(str) : strlen(str ? str : ""))), _type(pgm ? Type::pgmChar : Type::constChar) {}
29-
Text(const String& str) : _str(str.c_str()), _len(str.length()), _type(Type::constChar) {}
29+
Text(const uint8_t* str, uint16_t len) : _str((const char*)str), _len(len) {}
30+
Text(const String& str) : _str(str.c_str()), _len(str.length()) {}
3031

3132
// ========================== SYSTEM ==========================
3233
// Строка из Flash памяти

0 commit comments

Comments
 (0)