Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Problem with icons on HiDPI displays

<< < (6/13) > >>

oBFusCATed:
It turned out that adding the icons would be a lot more involved and complex than I originally thought.
So, I'll do it in two steps:
1. move 22x22 images in a separate folder and make sure everything works
2. add new icons after 1 is complete

So I've implemented step 1. You can see the changes in this branch: https://github.com/obfuscated/codeblocks_sf/tree/ui/move_images

At the moment the code seems to work on linux with both wx2.8 and wx3.x. Unfortunately I don't have the energy to test stuff on windows at the moment. So I'll be really happy if someone volunteers to apply the changes to update*.bat files and do some testing on windows.

Next I plan to see how this modified codeblocks works on macOS.

stahta01:
Used your branch to build win64 version of Code::Blocks and CB booted up OK; did not test any plugins.

Tested only 64 bit wxWidgets 3.0 build; patch used below

--- Code: ---From 9fa06dff4ecceb602411b34e925f061089cf17d5 Mon Sep 17 00:00:00 2001
From: Tim S <stahta01@gmail.com>
Date: Sun, 3 Mar 2019 14:38:10 -0500
Subject: [PATCH] ui: Copy 22x22 images

---
 src/update30_64.bat | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/src/update30_64.bat b/src/update30_64.bat
index 07388dc3a..bc71ac4a6 100644
--- a/src/update30_64.bat
+++ b/src/update30_64.bat
@@ -16,6 +16,7 @@ if not exist %CB_OUTPUT_RESDIR%\lexers md %CB_OUTPUT_RESDIR%\lexers\
 if not exist %CB_OUTPUT_RESDIR%\images md %CB_OUTPUT_RESDIR%\images\
 if not exist %CB_OUTPUT_RESDIR%\images\settings md %CB_OUTPUT_RESDIR%\images\settings\
 if not exist %CB_OUTPUT_RESDIR%\images\16x16 md %CB_OUTPUT_RESDIR%\images\16x16\
+if not exist %CB_OUTPUT_RESDIR%\images\22x22 md %CB_OUTPUT_RESDIR%\images\22x22\
 if not exist %CB_OUTPUT_RESDIR%\images\codecompletion md %CB_OUTPUT_RESDIR%\images\codecompletion\
 if not exist %CB_OUTPUT_RESDIR%\plugins md %CB_OUTPUT_RESDIR%\plugins\
 if not exist %CB_OUTPUT_RESDIR%\templates md %CB_OUTPUT_RESDIR%\templates\
@@ -30,6 +31,7 @@ if not exist %CB_DEVEL_RESDIR%\lexers md %CB_DEVEL_RESDIR%\lexers\
 if not exist %CB_DEVEL_RESDIR%\images md %CB_DEVEL_RESDIR%\images\
 if not exist %CB_DEVEL_RESDIR%\images\settings md %CB_DEVEL_RESDIR%\images\settings\
 if not exist %CB_DEVEL_RESDIR%\images\16x16 md %CB_DEVEL_RESDIR%\images\16x16\
+if not exist %CB_DEVEL_RESDIR%\images\22x22 md %CB_DEVEL_RESDIR%\images\22x22\
 if not exist %CB_DEVEL_RESDIR%\images\codecompletion md %CB_DEVEL_RESDIR%\images\codecompletion\
 if not exist %CB_DEVEL_RESDIR%\plugins md %CB_DEVEL_RESDIR%\plugins\
 if not exist %CB_DEVEL_RESDIR%\templates md %CB_DEVEL_RESDIR%\templates\
@@ -60,14 +62,14 @@ echo Compressing plugins UI resources
 %ZIPCMD% -jqu9 %CB_DEVEL_RESDIR%\abbreviations.zip plugins\abbreviations\resources\manifest.xml plugins\abbreviations\resources\*.xrc > nul
 echo Packing core UI bitmaps
 cd src\resources
-%ZIPCMD% -0 -qu ..\..\%CB_DEVEL_RESDIR%\resources.zip images\*.png images\12x12\*.png images\16x16\*.png > nul
+%ZIPCMD% -0 -qu ..\..\%CB_DEVEL_RESDIR%\resources.zip images\*.png images\12x12\*.png images\16x16\*.png images\22x22\*.png > nul
 cd ..\..\sdk\resources
-%ZIPCMD% -0 -qu ..\..\%CB_DEVEL_RESDIR%\manager_resources.zip images\*.png images\12x12\*.png images\16x16\*.png > nul
+%ZIPCMD% -0 -qu ..\..\%CB_DEVEL_RESDIR%\manager_resources.zip images\*.png images\12x12\*.png images\16x16\*.png images\22x22\*.png > nul
 echo Packing plugins UI bitmaps
 cd ..\..\plugins\compilergcc\resources
-%ZIPCMD% -0 -qu ..\..\..\%CB_DEVEL_RESDIR%\compiler.zip images\*.png images\16x16\*.png > nul
+%ZIPCMD% -0 -qu ..\..\..\%CB_DEVEL_RESDIR%\compiler.zip images\*.png images\16x16\*.png images\22x22\*.png > nul
 cd ..\..\..\plugins\debuggergdb\resources
-%ZIPCMD% -0 -qu ..\..\..\%CB_DEVEL_RESDIR%\debugger.zip images\*.png images\16x16\*.png > nul
+%ZIPCMD% -0 -qu ..\..\..\%CB_DEVEL_RESDIR%\debugger.zip images\*.png images\16x16\*.png images\22x22\*.png > nul
 cd ..\..\..
 
 echo Copying files
@@ -80,6 +82,8 @@ xcopy /D /y src\resources\images\*.png %CB_OUTPUT_RESDIR%\images > nul
 xcopy /D /y src\resources\images\settings\*.png %CB_OUTPUT_RESDIR%\images\settings > nul
 xcopy /D /y src\resources\images\16x16\*.png %CB_DEVEL_RESDIR%\images\16x16 > nul
 xcopy /D /y src\resources\images\16x16\*.png %CB_OUTPUT_RESDIR%\images\16x16 > nul
+xcopy /D /y src\resources\images\22x22\*.png %CB_DEVEL_RESDIR%\images\22x22 > nul
+xcopy /D /y src\resources\images\22x22\*.png %CB_OUTPUT_RESDIR%\images\22x22 > nul
 xcopy /D /y plugins\codecompletion\resources\images\*.png %CB_DEVEL_RESDIR%\images\codecompletion > nul
 xcopy /D /y plugins\codecompletion\resources\images\*.png %CB_OUTPUT_RESDIR%\images\codecompletion > nul
 xcopy /D /y plugins\compilergcc\resources\compilers\*.xml %CB_DEVEL_RESDIR%\compilers > nul
--
2.21.0.windows.1


--- End code ---

oBFusCATed:
Does switching to 16x16 icons work correctly? Do you see images in all four core toolbars?

oBFusCATed:
Committed. I've applied the same changes to the other update.bat scripts hopefully I've not messed something up.

stahta01:

--- Quote from: oBFusCATed on March 04, 2019, 12:16:35 am ---Does switching to 16x16 icons work correctly? Do you see images in all for core toolbars?

--- End quote ---

Yes

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version