diff --git a/src/siwin/window.nim b/src/siwin/window.nim index 55c2325..4f288db 100644 --- a/src/siwin/window.nim +++ b/src/siwin/window.nim @@ -292,7 +292,9 @@ when defined(linux): result.id = n.cint result.handle = display.ScreenOfDisplay(result.id) - proc defaultScreen*(): Screen = screen(display.DefaultScreen.int) + proc defaultScreen*(): Screen = + x.init() + screen(display.DefaultScreen.int) proc screen*: Screen = defaultScreen() proc n*(a: Screen): int = a.id.int