Windows11DragAndDropToTaskbarFix icon indicating copy to clipboard operation
Windows11DragAndDropToTaskbarFix copied to clipboard

App bad understand what app I want to open

Open DanRotaru opened this issue 3 years ago • 21 comments

https://user-images.githubusercontent.com/7759507/150231145-75179ff9-32e4-44b4-8875-d3db9f448c79.mp4

Windows 11 with 125% windows scalling App ver. 2.2.0.0

DanRotaru avatar Jan 19 '22 22:01 DanRotaru

Does it work this way every time?

Did you change the DPI settings when the program was already running?

Did you by any chance change DPI Awareness settings in the .exe file properties?

HerMajestyDrMona avatar Jan 19 '22 23:01 HerMajestyDrMona

  1. Yes
  2. No, I changed this settings only once when setup my windows
  3. No

Does it work this way every time?

Did you change the DPI settings when the program was already running?

Did you by any chance change DPI Awareness settings in the .exe file properties?

DanRotaru avatar Jan 20 '22 14:01 DanRotaru

I tested now on many DPI variations, and the program seems to detect and auto-switch it for me with no problem.

Unfortunately, I will need a debug log from you. Please add to your config file:

PrintDebugInfo=1 ShowConsoleWindowOnStartup=1

Then start Windows11DragAndDropToTaskbarFix.exe using the commandline, by typing:

Windows11DragAndDropToTaskbarFix.exe > win11fix_log.txt

More detailed guide how to do is, is for example available here: https://www.wikihow.com/Run-an-EXE-File-From-Command-Prompt

After that please drag and drop for few seconds and quit the program. Then upload the win11fix_log.txt file here.

I'm mostly interested in a line saying:

L"Different Session ID or Monitor detected. Current DPI X: " << Current_DPI_Scale_X << ". Y: " << Current_DPI_Scale_Y << "."

But the whole log would be a nice thing to check.

HerMajestyDrMona avatar Jan 20 '22 17:01 HerMajestyDrMona

This command dont save to file output (just blank file is created) Windows11DragAndDropToTaskbarFix.exe > win11fix_log.txt In console I find this line Different Session ID or Monitor detected. Current DPI X: 1. Y: 1 (2 times appears the same)

DanRotaru avatar Jan 20 '22 17:01 DanRotaru

Sorry, seems like something doesn't work with the log file when the program creates a custom console window.

I added a CustomLogFile variable now to the configuration file (that's why it took so long to reply).

Could you please download: https://we.tl/t-U0zywMHZVI Then add to your config:

PrintDebugInfo=1 ShowConsoleWindowOnStartup=1 CustomLogFile=win11fix_log.txt

I also added some extra logging to the Update_Pseudo_DPI_Scale() function, so should be easier to detect the issue.

In worst case, I guess I could add the custom DPI scale configuration variable to the config file, so you could set what you need to fix this problem? This could work when you're not using multiple screens.

HerMajestyDrMona avatar Jan 20 '22 19:01 HerMajestyDrMona

Sorry, seems like something doesn't work with the log file when the program creates a custom console window.

I added a CustomLogFile variable now to the configuration file (that's why it took so long to reply).

Could you please download: https://we.tl/t-U0zywMHZVI Then add to your config:

PrintDebugInfo=1 ShowConsoleWindowOnStartup=1 CustomLogFile=win11fix_log.txt

I also added some extra logging to the Update_Pseudo_DPI_Scale() function, so should be easier to detect the issue.

In worst case, I guess I could add the custom DPI scale configuration variable to the config file, so you could set what you need to fix this problem? This could work when you're not using multiple screens. Logs if you need, but looks the same (Different Session ID or Monitor detected. Current DPI X: 1. Y: 1) win11fix_log.txt

About DPI scale configuration I think it will be great, but better if application can determinate automatically settings and adjust it.

DanRotaru avatar Jan 20 '22 23:01 DanRotaru

Thanks for the log.

Yes, it should already automatically detect the DPI scale in function Update_Pseudo_DPI_Scale().

From your log, the interesting entries are:

Update_Pseudo_DPI_Scale = cxLogical: 1920. cyLogical: 1080.
Update_Pseudo_DPI_Scale = cxPhysical: 1920. cyPhysical: 1080.
Update_Pseudo_DPI_Scale = horzScale: 1. vertScale: 1.
Different Session ID or Monitor detected. Current DPI X: 1. Y: 1.

It seems like the monitor resolution is the same as the current logical resolution, therefore the DPI scale is detected as 1.0. I don't exactly remember how this calculation works, but normally these numbers should differ.

Are you 100% sure that you didn't tweak DPI settings for this program manually in file properties, or somewhere else? I know that you wrote that you didn't, but I just want to confirm it. Maybe quitting the program and then copying and pasting to a different folder is something worth to try, since It would most likely reset custom settings if any of them were set by the user or System itself.

EDIT: Hmmm... i checked again. The Current_DPI_Scale thing is only used in 1 place in the program (a function that detectes the error icon on the taskbar). So everywhere else it's the Operating System determining the right position, not the program. In this case it looks like the program is launched as DPI aware. Even if I added the custom DPI scale variable it wouldn't help in your case. Please try the copy-paste solution first, then we will see what's next.

HerMajestyDrMona avatar Jan 21 '22 06:01 HerMajestyDrMona

For me it looks this way:

Update_Pseudo_DPI_Scale = cxLogical: 1536. cyLogical: 864.
Update_Pseudo_DPI_Scale = cxPhysical: 1920. cyPhysical: 1080.
Update_Pseudo_DPI_Scale = horzScale: 1.25. vertScale: 1.25.
Different Session ID or Monitor detected. Current DPI X: 1.25. Y: 1.25.

So for you the program runs as DPI Aware.

Please click with the right mouse button on Windows11DragAndDropToTaskbarFix.exe, then More Options -> "Properties". Click on the "Compatibility" tab, then "Change high DPI settings" button, then check option: "Override high DPI scaling behavior" and change to "System" (or "System Enhanced"). Then restart the program and see if it's any better.

HerMajestyDrMona avatar Jan 21 '22 10:01 HerMajestyDrMona

My windows scaling settings Screenshot_3 Actually it's because I use XPExplorer (Windows 10 DPI FIX). This app fix blurry text in some classic apps (old apps), installers and others. image

Thanks for the log.

Yes, it should already automatically detect the DPI scale in function Update_Pseudo_DPI_Scale().

From your log, the interesting entries are:

Update_Pseudo_DPI_Scale = cxLogical: 1920. cyLogical: 1080.
Update_Pseudo_DPI_Scale = cxPhysical: 1920. cyPhysical: 1080.
Update_Pseudo_DPI_Scale = horzScale: 1. vertScale: 1.
Different Session ID or Monitor detected. Current DPI X: 1. Y: 1.

It seems like the monitor resolution is the same as the current logical resolution, therefore the DPI scale is detected as 1.0. I don't exactly remember how this calculation works, but normally these numbers should differ.

Are you 100% sure that you didn't tweak DPI settings for this program manually in file properties, or somewhere else? I know that you wrote that you didn't, but I just want to confirm it. Maybe quitting the program and then copying and pasting to a different folder is something worth to try, since It would most likely reset custom settings if any of them were set by the user or System itself.

EDIT: Hmmm... i checked again. The Current_DPI_Scale thing is only used in 1 place in the program (a function that detectes the error icon on the taskbar). So everywhere else it's the Operating System determining the right position, not the program. In this case it looks like the program is launched as DPI aware. Even if I added the custom DPI scale variable it wouldn't help in your case. Please try the copy-paste solution first, then we will see what's next.

DanRotaru avatar Jan 21 '22 15:01 DanRotaru

For me it looks this way:

Update_Pseudo_DPI_Scale = cxLogical: 1536. cyLogical: 864.
Update_Pseudo_DPI_Scale = cxPhysical: 1920. cyPhysical: 1080.
Update_Pseudo_DPI_Scale = horzScale: 1.25. vertScale: 1.25.
Different Session ID or Monitor detected. Current DPI X: 1.25. Y: 1.25.

So for you the program runs as DPI Aware.

Please click with the right mouse button on Windows11DragAndDropToTaskbarFix.exe, then More Options -> "Properties". Click on the "Compatibility" tab, then "Change high DPI settings" button, then check option: "Override high DPI scaling behavior" and change to "System" (or "System Enhanced"). Then restart the program and see if it's any better.

I changed this setting, the same. Video:

https://user-images.githubusercontent.com/7759507/150550809-15ab21d9-f89f-4e68-9d53-1e41df4e43ab.mp4

In video you can see that draging on first 2 apps works fine, but next with bugs, the same if I start to drag on first 2 apps from end. Logs: win11fix_log.txt

DanRotaru avatar Jan 21 '22 15:01 DanRotaru

I think this XPExplorer app is responsible for these problems. It must have tweaked some registry keys.

Have you tried to change settings in it? Generally all configurations I tested get DPI normally detected. I'm unable to reproduce this issue at all.

HerMajestyDrMona avatar Jan 21 '22 17:01 HerMajestyDrMona

Hey @DanRotaru. Have you tried anything new in order to solve this problem? I would recommend to try how it behaves after creating a new user account on Windows. Maybe it would reset some user's DPI settings then.

I think I also forgot to ask the basic question: Did you test how it behaves with 100% windows scaling? I suppose it works fine then, but just want to confirm that it's not the timing problem in the config.

HerMajestyDrMona avatar Jan 25 '22 02:01 HerMajestyDrMona

Yes, when I'm using 100% windows scalling all works great, so, this is problem.

https://user-images.githubusercontent.com/7759507/151137660-4111155c-d4c2-4041-9b67-b3b3c514697b.mp4

In logs Update_Pseudo_DPI_Scale = cxLogical: 1920. cyLogical: 1080. Update_Pseudo_DPI_Scale = cxPhysical: 1920. cyPhysical: 1080. Update_Pseudo_DPI_Scale = horzScale: 1. vertScale: 1. Different Session ID or Monitor detected. Current DPI X: 1. Y: 1.

DanRotaru avatar Jan 26 '22 09:01 DanRotaru

Even if I use 125% scaling, logs, so it's caused by XPExplorer.

Logs Update_Pseudo_DPI_Scale = cxLogical: 1536. cyLogical: 864. Update_Pseudo_DPI_Scale = cxPhysical: 1920. cyPhysical: 1080. Update_Pseudo_DPI_Scale = horzScale: 1.25. vertScale: 1.25. Different Session ID or Monitor detected. Current DPI X: 1.25. Y: 1.25.

DanRotaru avatar Jan 26 '22 09:01 DanRotaru

@DanRotaru So you're able to use the program correctly at 125% scale right now? Shutting XPExplorer helped?

HerMajestyDrMona avatar Jan 26 '22 09:01 HerMajestyDrMona

A, lol, it's not XPExplorer merit, so I don't need this app. This image

is caused by image

Sorry, my windows is in russian language, so if I will select simple 125% windows scalling, in some apps blur effect don't will disappear, but if I will enter manually 125% (in that input box), windows will display 125% scalling + without blur effect in some apps.

DanRotaru avatar Jan 26 '22 10:01 DanRotaru

For example: With 125% manually set (windows idk identify it 175%) image Logs

Update_Pseudo_DPI_Scale = cxLogical: 1920. cyLogical: 1080.
Update_Pseudo_DPI_Scale = cxPhysical: 1920. cyPhysical: 1080.
Update_Pseudo_DPI_Scale = horzScale: 1. vertScale: 1.
Different Session ID or Monitor detected. Current DPI X: 1. Y: 1.

And with 125% automatic windows scalling image Logs

Update_Pseudo_DPI_Scale = cxLogical: 1536. cyLogical: 864.
Update_Pseudo_DPI_Scale = cxPhysical: 1920. cyPhysical: 1080.
Update_Pseudo_DPI_Scale = horzScale: 1.25. vertScale: 1.25.
Different Session ID or Monitor detected. Current DPI X: 1.25. Y: 1.25.

And how you understant here app works without this bug.

So maybe in config file just add possibility to change this settings? To set from 1920x1080 to 1535x864, and dpi from 1 to 1.25

DanRotaru avatar Jan 26 '22 10:01 DanRotaru

Oh, I understand now. That's strange that Windows does such thing.

The DPI value is only used in the program for the DetectKnownPixelColorsToPreventAccidentalEvents function (which worked correctly for you in any case). Changing it wouldn't help, because everything else in the program doesn't use any DPI multiplier.

I'll see what can be done but I don't promise anything. There's so many things possible to break while implementing this option.

HerMajestyDrMona avatar Jan 26 '22 10:01 HerMajestyDrMona

i have the exact same issue, using a 17 inch laptop 1920x1080 with scale 100%

Khaledtheking avatar Oct 07 '23 23:10 Khaledtheking

i have the exact same issue, using a 17 inch laptop 1920x1080 with scale 100%

Bro, just update your OS, is not actual more), windows natively adds support for drag over taskbar, just update it =)

DanRotaru avatar Oct 07 '23 23:10 DanRotaru

sorry, i just tried to restart my laptop and it worked fine, i'm new, it is working good now, thank you

Khaledtheking avatar Oct 07 '23 23:10 Khaledtheking