No reason. The install mirrors the tree structure of a website containing any number of folders, but the installer can go anywhere.
'bin' is merely a habit.
===
There are a few more quirks in Windows at different DPI settings.
I found `System::Call 'SHCORE::GetProcessDpiAwareness(p0,*i0r1)'` useful in setting the dpi-awareness only for standard sizes. 120, 144, 168, 192.
168 dpi is as bad as 120 dpi when it comes to the application window size. It is more narrow than at 96 dpi.
No one can say what future Windows versions will bring, but because 168 and 120 dpi alter the aspect-ratio by a lot, the developers might decide to streamline all DPI sizes, so there is a nice gradient when you switch to a higher or lower monitor setting. For designers this would mean adapting.
All things considered, "ManifestDPIAware false" is the safest choice, letting Windows re-scale everything up from 96 dpi. I had wondered about using "ManifestDPIAware true" in the past. It seemed like a fair choice, but having investigated it, the "false" setting, as I now think, has a lot going for it.
To switch dpi-aware on and off, I used a variable '$DPI_SCALE'. The default 96 dpi image is 's.bmp' or 'sUN.bmp' (uninstaller).
MACRO
!macro DPIX UN
StrCpy $DPI_SCALE "DWM" # ; user variable
System::Call 'SHCORE::GetProcessDpiAwareness(p0,*i0r1)'
${IfThen} $1 = 1 ${|} StrCpy $1 PROCESS_SYSTEM_DPI_AWARE ${|}
System::Call 'USER32::GetDpiForSystem()i.r2'
System::Call 'USER32::IsProcessDPIAware()i.r3'
; example - 6002: get=0 sysdpi=error aware=1 (Vista)
#MessageBox MB_OK "${TEMP1}: get=$1 sysdpi=$2 aware=$3"
StrCpy $SYS_DPI $2 #
StrCpy $DPI_AWARE $3 #
${If} $1 == "PROCESS_SYSTEM_DPI_AWARE" ; process okay
${AndIf} $3 == 1 ; aware
${If} $2 == 192
${OrIf} $2 == 168
${OrIf} $2 == 144
${OrIf} $2 == 120
StrCpy $DPI_SCALE "" #
${If} $2 == 192
File "/oname=$PluginsDir\modern-header.bmp" "xl${UN}.bmp" ; 192
${ElseIf} $2 == 168
File "/oname=$PluginsDir\modern-header.bmp" "l${UN}.bmp" ; 168
${ElseIf} $2 == 144
File "/oname=$PluginsDir\modern-header.bmp" "m${UN}.bmp" ; 144
${ElseIf} $2 == 120
File "/oname=$PluginsDir\modern-header.bmp" "n${UN}.bmp" ; 120
${EndIf}
${IfNot} $DPI_SCALE == "DWM"
!insertmacro MUI_HEADERIMAGE_INITHELPER_LOADIMAGEWITHMACRO \
MUI_LOADANDXALIGNIMAGE ; "NoStretchNoCrop"
${EndIf}
${EndIf}
${EndIf}
!macroend
INSTALLER
Function .onInit
; DPI-aware on-switch provided ManifestDPIAware is "notset"
GetWinVer ${TEMP1} Build
IntCmp ${TEMP1} 10240 0 jump 0 ; require Windows 10
; dpi font-scaling was eratic on earlier Windows
System::Call 'USER32::SetProcessDPIAware()i.r0'
jump:
...
FunctionEnd
Function onGUIInit_func
; Re-scaled bitmaps
!insertmacro DPIX ""
...
FunctionEnd
UNINSTALLER
Function un.onInit
GetWinVer ${TEMP1} Build
IntCmp ${TEMP1} 10240 0 jump 0 ; Windows 10+
System::Call 'USER32::SetProcessDPIAware()i.r0'
jump:
...
FunctionEnd
Function un.onGUIInit_func
; Re-scaled bitmaps
!insertmacro DPIX "UN"
...
FunctionEnd
May it help someone.