kopia lustrzana https://github.com/jamescoxon/dl-fldigi
RX Text backspace
* Correct logic error in handling UTF-8 char backspacepull/2/head
rodzic
aada490a13
commit
f2c18cb549
|
@ -274,8 +274,6 @@ void FTextRX::add(unsigned int c, int attr)
|
|||
switch (c) {
|
||||
case '\b':
|
||||
// we don't call kf_backspace because it kills selected text
|
||||
tbuf->remove(tbuf->length() - 1, tbuf->length());
|
||||
sbuf->remove(sbuf->length() - 1, sbuf->length());
|
||||
if (s_text.length()) {
|
||||
if (tbuf->byte_at(tbuf->length() - 1 ) & 0x80) { //UTF-8 character
|
||||
s_text.erase(s_text.end() - 2);
|
||||
|
|
Ładowanie…
Reference in New Issue