Skip to content

Commit

Permalink
Fix #94: Other TextBox carets jumping around
Browse files Browse the repository at this point in the history
  • Loading branch information
ahmetsait committed May 9, 2024
1 parent f8ad716 commit e544708
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Scintilla.NET/Scintilla.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3358,7 +3358,11 @@ public bool UseRightToLeftReadingLayout
exStyle &= ~WinApiHelpers.WS_EX_LAYOUTRTL;
}
Handle.SetWindowLongPtr(WinApiHelpers.GWL_EXSTYLE, new IntPtr(exStyle));
DirectMessage(NativeMethods.SCI_GRABFOCUS, new IntPtr(1)); // needs focus to update

// Workaround Scintilla mirrored rendering issue:
var wrapMode = WrapMode;
WrapMode = wrapMode == WrapMode.None ? WrapMode.Word : WrapMode.None;
WrapMode = wrapMode;
}
}

Expand Down

0 comments on commit e544708

Please sign in to comment.