diff --git a/PowerEditor/src/WinControls/AnsiCharPanel/ListView.cpp b/PowerEditor/src/WinControls/AnsiCharPanel/ListView.cpp index c9f17042..e8c1f8f5 100644 --- a/PowerEditor/src/WinControls/AnsiCharPanel/ListView.cpp +++ b/PowerEditor/src/WinControls/AnsiCharPanel/ListView.cpp @@ -77,15 +77,15 @@ void ListView::init(HINSTANCE hInst, HWND parent) generic_string hexStr = pNativeSpeaker->getAttrNameStr(TEXT("Hex"), "AsciiInsertion", "ColumnHex"); generic_string charStr = pNativeSpeaker->getAttrNameStr(TEXT("Character"), "AsciiInsertion", "ColumnChar"); - lvColumn.cx = 45; + lvColumn.cx = NppParameters::getInstance()->_dpiManager.scaleX(45); lvColumn.pszText = (TCHAR *)valStr.c_str(); ListView_InsertColumn(_hSelf, 0, &lvColumn); - lvColumn.cx = 45; + lvColumn.cx = NppParameters::getInstance()->_dpiManager.scaleY(45);; lvColumn.pszText = (TCHAR *)hexStr.c_str(); ListView_InsertColumn(_hSelf, 1, &lvColumn); - lvColumn.cx = 70; + lvColumn.cx = NppParameters::getInstance()->_dpiManager.scaleY(70);; lvColumn.pszText = (TCHAR *)charStr.c_str(); ListView_InsertColumn(_hSelf, 2, &lvColumn); } diff --git a/PowerEditor/src/WinControls/ProjectPanel/TreeView.cpp b/PowerEditor/src/WinControls/ProjectPanel/TreeView.cpp index c5651c32..e49a826b 100644 --- a/PowerEditor/src/WinControls/ProjectPanel/TreeView.cpp +++ b/PowerEditor/src/WinControls/ProjectPanel/TreeView.cpp @@ -28,6 +28,7 @@ #include "TreeView.h" +#include "Parameters.h" #define CY_ITEMHEIGHT 18 @@ -47,7 +48,8 @@ void TreeView::init(HINSTANCE hInst, HWND parent, int treeViewID) _hInst, (LPVOID)0); - TreeView_SetItemHeight(_hSelf, CY_ITEMHEIGHT); + int itemHeight = NppParameters::getInstance()->_dpiManager.scaleY(CY_ITEMHEIGHT); + TreeView_SetItemHeight(_hSelf, itemHeight); ::SetWindowLongPtr(_hSelf, GWLP_USERDATA, (LONG_PTR)this); _defaultProc = reinterpret_cast(::SetWindowLongPtr(_hSelf, GWLP_WNDPROC, (LONG_PTR)staticProc));