mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-11 00:04:24 +00:00
Examples: Win32+OpenGL3: enable DPI awareness. (#9083)
This commit is contained in:
parent
8ff7f35eec
commit
a484fd2b56
2 changed files with 2 additions and 1 deletions
|
|
@ -175,6 +175,7 @@ Other Changes:
|
|||
during surface resize. (#8381)
|
||||
- SDL2+WebGPU: added new example (Emscripten + native Dawn/WGPU). (#8381) [@brutpitt]
|
||||
- SDL3+WebGPU: added new example (Emscripten + native Dawn/WGPU). (#8381) [@brutpitt]
|
||||
- Win32+OpenGL3: enable DPI awareness. (#9083)
|
||||
|
||||
|
||||
-----------------------------------------------------------------------
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ LRESULT WINAPI WndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam);
|
|||
int main(int, char**)
|
||||
{
|
||||
// Make process DPI aware and obtain main monitor scale
|
||||
//ImGui_ImplWin32_EnableDpiAwareness(); // FIXME: This somehow doesn't work in the Win32+OpenGL example. Why?
|
||||
ImGui_ImplWin32_EnableDpiAwareness();
|
||||
float main_scale = ImGui_ImplWin32_GetDpiScaleForMonitor(::MonitorFromPoint(POINT{ 0, 0 }, MONITOR_DEFAULTTOPRIMARY));
|
||||
|
||||
// Create application window
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue