Improve RTL support in wxStyledTextCtrl.
Use the correct HDC, inheriting the right text orientation, when creating wxMemoryDC in SurfaceImpl code. There may still be problems with the actual RTL languages, but at the very least English text displayed in RTL locale is not mirrored any more. Closes #16230. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76493 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -211,9 +211,12 @@ void SurfaceImpl::Init(SurfaceID hdc_, WindowID) {
|
||||
hdc = (wxDC*)hdc_;
|
||||
}
|
||||
|
||||
void SurfaceImpl::InitPixMap(int width, int height, Surface *WXUNUSED(surface_), WindowID winid) {
|
||||
void SurfaceImpl::InitPixMap(int width, int height, Surface *surface, WindowID winid) {
|
||||
Release();
|
||||
hdc = new wxMemoryDC();
|
||||
if (surface)
|
||||
hdc = new wxMemoryDC(static_cast<SurfaceImpl*>(surface)->hdc);
|
||||
else
|
||||
hdc = new wxMemoryDC();
|
||||
hdcOwned = true;
|
||||
if (width < 1) width = 1;
|
||||
if (height < 1) height = 1;
|
||||
|
Reference in New Issue
Block a user