mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-11-06 13:14:21 +01:00
Display (macOS, Windows): support display name detection
This commit is contained in:
@@ -125,7 +125,8 @@ static void waylandOutputHandler(WaylandData* wldata, struct wl_registry* regist
|
||||
(uint32_t) display.height,
|
||||
display.refreshRate / 1000.0,
|
||||
(uint32_t) (display.width / display.scale),
|
||||
(uint32_t) (display.height / display.scale)
|
||||
(uint32_t) (display.height / display.scale),
|
||||
NULL
|
||||
);
|
||||
|
||||
ffThreadMutexUnlock(&mutex);
|
||||
|
||||
@@ -112,13 +112,13 @@ void ffdsConnectXcb(const FFinstance* instance, FFDisplayServerResult* result)
|
||||
|
||||
while(iterator.rem > 0)
|
||||
{
|
||||
ffdsAppendDisplay(
|
||||
result,
|
||||
ffdsAppendDisplay(result,
|
||||
(uint32_t) iterator.data->width_in_pixels,
|
||||
(uint32_t) iterator.data->height_in_pixels,
|
||||
0,
|
||||
(uint32_t) iterator.data->width_in_pixels,
|
||||
(uint32_t) iterator.data->height_in_pixels
|
||||
(uint32_t) iterator.data->height_in_pixels,
|
||||
NULL
|
||||
);
|
||||
ffxcb_screen_next(&iterator);
|
||||
}
|
||||
@@ -182,7 +182,8 @@ static bool xcbRandrHandleModeInfo(XcbRandrData* data, xcb_randr_mode_info_t* mo
|
||||
(uint32_t) modeInfo->height,
|
||||
refreshRate == 0 ? data->defaultRefreshRate : refreshRate,
|
||||
(uint32_t) modeInfo->width,
|
||||
(uint32_t) modeInfo->height
|
||||
(uint32_t) modeInfo->height,
|
||||
NULL
|
||||
);
|
||||
}
|
||||
|
||||
@@ -219,7 +220,8 @@ static bool xcbRandrHandleCrtc(XcbRandrData* data, xcb_randr_crtc_t crtc)
|
||||
(uint32_t) crtcInfoReply->height,
|
||||
data->defaultRefreshRate,
|
||||
(uint32_t) crtcInfoReply->width,
|
||||
(uint32_t) crtcInfoReply->height
|
||||
(uint32_t) crtcInfoReply->height,
|
||||
NULL
|
||||
);
|
||||
|
||||
free(crtcInfoReply);
|
||||
@@ -264,7 +266,8 @@ static bool xcbRandrHandleMonitor(XcbRandrData* data, xcb_randr_monitor_info_t*
|
||||
(uint32_t) monitor->height,
|
||||
data->defaultRefreshRate,
|
||||
(uint32_t) monitor->width,
|
||||
(uint32_t) monitor->height
|
||||
(uint32_t) monitor->height,
|
||||
NULL
|
||||
);
|
||||
}
|
||||
|
||||
@@ -324,7 +327,8 @@ static void xcbRandrHandleScreen(XcbRandrData* data, xcb_screen_t* screen)
|
||||
(uint32_t) screen->height_in_pixels,
|
||||
data->defaultRefreshRate,
|
||||
(uint32_t) screen->width_in_pixels,
|
||||
(uint32_t) screen->height_in_pixels
|
||||
(uint32_t) screen->height_in_pixels,
|
||||
NULL
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -77,13 +77,13 @@ void ffdsConnectXlib(const FFinstance* instance, FFDisplayServerResult* result)
|
||||
for(int i = 0; i < ScreenCount(display); i++)
|
||||
{
|
||||
Screen* screen = ScreenOfDisplay(display, i);
|
||||
ffdsAppendDisplay(
|
||||
result,
|
||||
ffdsAppendDisplay(result,
|
||||
(uint32_t) WidthOfScreen(screen),
|
||||
(uint32_t) HeightOfScreen(screen),
|
||||
0,
|
||||
(uint32_t) WidthOfScreen(screen),
|
||||
(uint32_t) HeightOfScreen(screen)
|
||||
(uint32_t) HeightOfScreen(screen),
|
||||
NULL
|
||||
);
|
||||
}
|
||||
|
||||
@@ -141,7 +141,8 @@ static bool xrandrHandleModeInfo(XrandrData* data, XRRModeInfo* modeInfo)
|
||||
(uint32_t) modeInfo->height,
|
||||
refreshRate == 0 ? data->defaultRefreshRate : refreshRate,
|
||||
(uint32_t) modeInfo->width,
|
||||
(uint32_t) modeInfo->height
|
||||
(uint32_t) modeInfo->height,
|
||||
NULL
|
||||
);
|
||||
}
|
||||
|
||||
@@ -172,7 +173,8 @@ static bool xrandrHandleCrtc(XrandrData* data, RRCrtc crtc)
|
||||
(uint32_t) crtcInfo->height,
|
||||
data->defaultRefreshRate,
|
||||
(uint32_t) crtcInfo->width,
|
||||
(uint32_t) crtcInfo->height
|
||||
(uint32_t) crtcInfo->height,
|
||||
NULL
|
||||
);
|
||||
|
||||
data->ffXRRFreeCrtcInfo(crtcInfo);
|
||||
@@ -208,7 +210,8 @@ static bool xrandrHandleMonitor(XrandrData* data, XRRMonitorInfo* monitorInfo)
|
||||
(uint32_t) monitorInfo->height,
|
||||
data->defaultRefreshRate,
|
||||
(uint32_t) monitorInfo->width,
|
||||
(uint32_t) monitorInfo->height
|
||||
(uint32_t) monitorInfo->height,
|
||||
NULL
|
||||
);
|
||||
}
|
||||
|
||||
@@ -262,7 +265,8 @@ static void xrandrHandleScreen(XrandrData* data, Screen* screen)
|
||||
(uint32_t) HeightOfScreen(screen),
|
||||
data->defaultRefreshRate,
|
||||
(uint32_t) WidthOfScreen(screen),
|
||||
(uint32_t) HeightOfScreen(screen)
|
||||
(uint32_t) HeightOfScreen(screen),
|
||||
NULL
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user