diff --git a/PowerEditor/src/WinControls/DocumentMap/documentMap.cpp b/PowerEditor/src/WinControls/DocumentMap/documentMap.cpp index d0bbe02db..ed2995574 100644 --- a/PowerEditor/src/WinControls/DocumentMap/documentMap.cpp +++ b/PowerEditor/src/WinControls/DocumentMap/documentMap.cpp @@ -326,10 +326,8 @@ void DocumentMap::scrollMapWith(const MapPosition & mapPos) void DocumentMap::doMove() { RECT rc; - POINT pt = {0,0}; - ::ClientToScreen(_hSelf, &pt); getClientRect(rc); - ::MoveWindow(_vzDlg.getHSelf(), pt.x, pt.y, (rc.right - rc.left), (rc.bottom - rc.top), TRUE); + ::MoveWindow(_vzDlg.getHSelf(), 0, 0, (rc.right - rc.left), (rc.bottom - rc.top), TRUE); } void DocumentMap::fold(size_t line, bool foldOrNot) @@ -378,6 +376,7 @@ INT_PTR CALLBACK DocumentMap::run_dlgProc(UINT message, WPARAM wParam, LPARAM lP _vzDlg.init(::GetModuleHandle(NULL), _hSelf); _vzDlg.doDialog(); (NppParameters::getInstance()).SetTransparent(_vzDlg.getHSelf(), 50); // 0 <= transparancy < 256 + BringWindowToTop (_vzDlg.getHSelf()); setSyntaxHiliting(); @@ -398,12 +397,10 @@ INT_PTR CALLBACK DocumentMap::run_dlgProc(UINT message, WPARAM wParam, LPARAM lP if (_vzDlg.isCreated()) { - POINT pt = {0,0}; - ::ClientToScreen(_hSelf, &pt); if (!_pMapView->isWrap()) ::MoveWindow(_pMapView->getHSelf(), 0, 0, width, height, TRUE); - ::MoveWindow(_vzDlg.getHSelf(), pt.x, pt.y, width, height, TRUE); + ::MoveWindow(_vzDlg.getHSelf(), 0, 0, width, height, TRUE); } } break; @@ -440,9 +437,7 @@ INT_PTR CALLBACK DocumentMap::run_dlgProc(UINT message, WPARAM wParam, LPARAM lP int width = rc.right - rc.left; int height = rc.bottom - rc.top; - POINT pt = {0,0}; - ::ClientToScreen(_hSelf, &pt); - ::MoveWindow(_vzDlg.getHSelf(), pt.x, pt.y, width, height, TRUE); + ::MoveWindow(_vzDlg.getHSelf(), 0, 0, width, height, TRUE); scrollMap(); return TRUE; } diff --git a/PowerEditor/src/WinControls/DocumentMap/documentMap.rc b/PowerEditor/src/WinControls/DocumentMap/documentMap.rc index 42e34e455..38434f44b 100644 --- a/PowerEditor/src/WinControls/DocumentMap/documentMap.rc +++ b/PowerEditor/src/WinControls/DocumentMap/documentMap.rc @@ -38,7 +38,7 @@ BEGIN END IDD_VIEWZONE DIALOGEX 26, 41, 200, 200 -STYLE DS_SETFONT | DS_FIXEDSYS | WS_POPUP +STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD FONT 8, "MS Sans Serif", 0, 0, 0x0 BEGIN CONTROL "",IDC_VIEWZONECANVAS,"Static",SS_OWNERDRAW,0,0,50,14