Issues with multiple monitors

Hello,

we have two reported issues with players that are using a setup with more than two monitors with different resolutions.

The first one is playing the game fullscreen on a secondary monitor with different resolution than the primary. It was reported on [Content removed] and there’s a bug on the tracker(UE-206910). Are ther any updates with this? On the community post version of the EPS ticket another user mention Fortnite doesn’t have that issue, so is there something we can do our own to fix it as well?

The other is moving the game window with windows key (Windows + shift + arrow), it was reported on [Content removed] and there’s a ticket (UE-274239) marked as won’t fix. Both the post and ticket mention this doesn’t happen on Windows 11, but we are able to reproduce consistently on W11. Is there any fix for this? What was the reason for it to be marked as won’t fix?

By the way, all of our settings are based on Lyra, if that information helps in any way.

Thank you!

Steps to Reproduce

Hello,

The Cursor input does not work properly in exclusive fullscreen mode on a secondary monito issue was backlogged with a proposed fix which is to replace the usage of CachedDisplayMetrics in SlateApplication.cpp and SlateUser.cpp with:

FVector2f DisplaySize = Window->GetFullScreenInfo().GetSize2f();However in 5.8 CL#49786545 (6f3ecb) was added and may address this issue:

Improve support for multiple monitors on Windows

The main change is to extend UGameUserSettings with members to track the DisplayID and DisplayIndex of the main display. The DisplayID and DisplayIndex can be used to determine the MonitorIndex using FDisplayMetrics::GetClosestMonitorFromIDAndIndex. MonitorIndex is plumbed around the engine to index into the FDisplayMetrics::MonitorInfo array. In the common case, DisplayIndex and MonitorIndex will be the same, but we have a preference for DisplayID if displays get shuffled around.

r.SetRes.MonitorIndex was added to complement r.SetRes for displaying on a specific monitor.

The code will try to preserve legacy behavior when MonitorIndex == -1, which usually means using the primary display members of FDisplayMetrics. If the user moves or resizes the window or uses a fullscreen toggle shortcut (F11 or Alt+Enter), then display properties will be written into GameUserSettings and cause MonitorIndex to become valid.

Add FMonitorInfo::FriendlyName for display purposes because FMonitorInfo::Name is not very friendly. Also add FMonitorInfo::NativeHandle, which is useful for calling RHIGetAvailableResolutionsForDisplay.

Modify FWindowsWindow and FWindowsApplication to prevent shenanigans if we are not in a modal loop for moving or sizing that was initiated by the user.

Simplify FMonitorInfo::DPI on Windows to use effective DPI logic, undoing changelist 4534956. If raw or angular DPI become necessary, we should supply them separately.

Fix FSlateApplication::LocateWidgetInWindow and FSlateApplication::TransformPointerEvent to allow exclusive fullscreen to compute mouse position correctly on secondary monitors.

Add FSlateApplicationBase::GetCachedDisplayMetricsByRef to avoid copies when using FSlateApplicationBase::GetCachedDisplayMetrics, but callers need to be careful.

Prevent remote desktop from entering exclusive fullscreen through F11 toggle by checking new function FViewport::IsExclusiveFullscreenSupported.

Fix settings screen not refreshing settings after video revert through new multicast delegate FOnGameUserSettingsVideoRevert.

The code now looks like this (among many changes):

const FVector2f DisplaySize = CachedDisplayMetrics.MonitorInfo.IsEmpty()
                ? FVector2f(CachedDisplayMetrics.PrimaryDisplayWidth, CachedDisplayMetrics.PrimaryDisplayHeight)
                : Window->GetFullScreenInfo().GetSize2f();

I don’t see any special handling for this in Fortnite. Please let me know if this changelist addresses the issue you’re seeing and I’ll update the bug tracker.

The other issue, Switching project monitor with shift+win+arrow keys, was marked as won’t fix because it only reproduced in Windows 10 which is EOL. Please provide more information and repro steps on how you are able to reproduce it consistently on Windows 11 and what version of Windows 11.

Hello, thanks for the reply. We will try to integrate these CLs and report back.

About the issue only reproduced in W10, the repro were the same on W11, but unfortunatelly we are not able to get the version at this time.