BinEditor: Include null chars on ASCII copy

Replace them with spaces

Change-Id: I2d3cad8c7c34c222d971e3cdf56a85824342e9be
Reviewed-by: hjk <hjk@theqtcompany.com>
This commit is contained in:
Orgad Shaneh
2015-02-11 15:49:45 +02:00
committed by hjk
parent 5930e62b84
commit 2c4b9fb64f

View File

@@ -1380,8 +1380,9 @@ void BinEditorWidget::copy(bool raw)
tr("You cannot copy more than 4 MB of binary data.")); tr("You cannot copy more than 4 MB of binary data."));
return; return;
} }
const QByteArray &data = dataMid(selStart, selectionLength); QByteArray data = dataMid(selStart, selectionLength);
if (raw) { if (raw) {
data.replace(0, ' ');
QApplication::clipboard()->setText(QString::fromLatin1(data)); QApplication::clipboard()->setText(QString::fromLatin1(data));
return; return;
} }