Consider this code: Sub ShowScreenSize() screenRectangle = CreateUnoService("com.sun.star.awt.Toolkit").getWorkArea() MsgBox screenRectangle.Width & " x " & screenRectangle.Height End Sub According to the documentation [1], it returns the size and position of the primary display. On my system, the code gives "1919 x 1079", instead of expected "1920 x 1080". [1] https://api.libreoffice.org/docs/idl/ref/interfacecom_1_1sun_1_1star_1_1awt_1_1XToolkit.html#a29f80014339cc32d254de3be5cb22057
https://gerrit.libreoffice.org/c/core/+/169766
Mike Kaganski committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/58ed26938f254e1952dfaed4b208ad5a89b89387 tdf#161844: AbsoluteScreenPixelRectangle is a closed interval It will be available in 25.2.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Mike Kaganski committed a patch related to this issue. It has been pushed to "libreoffice-24-8": https://git.libreoffice.org/core/commit/239cfbdec6c167bcf75c9d9d33ff137f575ea5ce tdf#161844: AbsoluteScreenPixelRectangle is a closed interval It will be available in 24.8.0.0.beta2. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.