fix: export error

This commit is contained in:
Roy Qu 2024-04-29 13:37:04 +08:00
parent 6359000c85
commit e9f7d42aa6
1 changed files with 1 additions and 1 deletions

View File

@ -95,7 +95,7 @@ void Exporter::exportRange(const PDocument& doc, BufferCoord start, BufferCoord
continue; continue;
} }
if (i==stop.line && (startPos+token.length() > stop.ch)) { if (i==stop.line && (startPos+token.length() > stop.ch)) {
token = token.remove(stop.ch - startPos - 1); token = token.left(stop.ch - startPos - 1);
} }
if (i==start.line && startPos < start.ch-1) { if (i==start.line && startPos < start.ch-1) {
token = token.mid(start.ch-1-startPos); token = token.mid(start.ch-1-startPos);