UltraModernUI icon indicating copy to clipboard operation
UltraModernUI copied to clipboard

Unicode characters break in INSTDIR

Open novacto3 opened this issue 6 years ago • 3 comments

Hello,

I use NSIS 3.04 with UltraModernUI 2.0b5 and I encountered this bug:

When I try to install software to unicode path (czech characters) like this: D:\přílišžluťoučkýkůň\Modern UI Test it gets converted into this: D:\prílišžlutouckýkun\Modern UI Test

UMUI

NSIS with MUI2 works correctly, so I presume it is bug in UMUI: Test2

I used oficial example from NSIS documentation: https://nsis.sourceforge.io/Examples/Modern%20UI/MultiLanguage.nsi Tested on Windows 10.

novacto3 avatar Aug 09 '19 12:08 novacto3

The problem is located somewhere in the SkinnedControls plugin. When disabled by this two defines, it works:

!define UMUI_NO_BUTTONIMAGE
!define UMUI_NO_SCROLLBARIMAGE

I will have to reinstall the plugin development environment when I have time. But not being an expert in C++, I'm not sure I'll find the solution.

SuperPat45 avatar Aug 25 '19 17:08 SuperPat45

!define UMUI_NO_BUTTONIMAGE !define UMUI_NO_SCROLLBARIMAGE

Thank you very much, this fixes the problem.

novacto3 avatar Aug 26 '19 13:08 novacto3

The coolsb project in SkinnedControls is set to "Use Multi-Byte Character Set" even for the unicode project configurations. If the GWL_WNDPROC attribute is set using SetWindowLongA instead of SetWindowLongW, this causes text be translated to ANSI when WM_GETTEXT and WM_SETTEXT messages are processed. Setting the coolsb project to "Use Unicode Character Set" for the unicode configurations seems to fix the issue for me.

alex-chung avatar Aug 01 '21 19:08 alex-chung