Skip to content

Commit af8a88f

Browse files
committed
Advance the caret when decoding entities on key press
Brings UX into closer parity with as-you-type Unicode decoding
1 parent 89a522c commit af8a88f

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/U_Npp_HTMLTag.pas

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -672,6 +672,8 @@ procedure TNppPluginHTMLTag.FindAndDecode(const KeyCode: Integer; Cmd: TDecodeCm
672672
$26 {'&'}: begin
673673
if (Options.LiveEntityDecoding or (cmd = dcEntity)) then begin
674674
didReplace := Replace(@(U_Entities.DecodeEntities), anchor, caret);
675+
if not (ch in [$0A, $0D]) then
676+
Inc(charOffset);
675677
Break;
676678
end;
677679
end;

0 commit comments

Comments
 (0)