Created attachment 126143 [details] Screenshots of help dialogs from different versions Under Windows, starting LibreOffice with --help (-h, -?) switch outputs the information to a dialog, instead of console. Given rather large amount of information there, this dialog is unusable because: 1. It cannot be resized, and there is no scroll bars there to enable view of parts outside of initially displayed part (both horizontally and vertically) 2. It doesn't enable copying text from it (neither using Ctrl+C, not selecting by mouse) 3. Since 5.0, it doesn't allow closing clicking "Close" button by mouse (Bug 91622, supposedly because the text overlaps the button, thus click happens to the text instead of the button). It is unclear why would this help text need to be in a dialog in the first place, because its intent is to enable user to use command line, which implies console usage, so outputting this to console could be fine. But if it's necessary (e.g., because console is unavailable to the program, or no console experience is implied), then the dialog should be made usable by making the text both scrollable and selectable/copiable, and not overlapping "Close" button. Attached are screenshots from different versions, where it's apparent that even on older versions, where the text vertically fit the dialog, it still doesn't fit horizontally. In recent versions, it doesn't fit both directions.
There is bug 76932 for the lack of scrolling.
*** Bug 103255 has been marked as a duplicate of this bug. ***
My duplicate, bug 103255, also suggests the complete elimination of the dialog for other commandline arguments like version.
A patch is submitted for review: https://gerrit.libreoffice.org/31059
Mike Kaganski committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=24a24e65cafffe137d76de0a6eb5270ea88ebffd tdf#100826: use console for -h and --version also on Windows It will be available in 5.3.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
A follow-up patch is in gerrit: https://gerrit.libreoffice.org/31187 that allows to output the --help into caller console if available.
Mike Kaganski committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=601bdc416b6ef17498c94fec49164b1b4c38528d tdf#100826: Use parent console for output if possible It will be available in 5.4.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://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 "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=12899c07be2f927776ae12ea1abcefdc4bea8346 tdf#100826 related: initialize stdout/stdin/strerr properly It will be available in 5.4.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Hello, Is this bug fixed? If so, could you please close it as RESOLVED FIXED?
I tested this on windows with LibreOffice Version: 5.4.5.1 (x64) Build ID: 79c9829dd5d8054ec39a82dc51cd9eff340dbee8 I needed this to programatically find a version number for LibreOffice (also versions <5 so I will have to find another way to do this.) bellow are three examples which I tried with described results and code snippet to reproduce my findings cmd did only return a newline C:\Users\user>"C:\Program Files\LibreOffice 5\program\scalc.exe" --version powershell spawned a separate commandline window listed in taskmanager as soffice.bin with version information. PS C:\Users\user> Start-Process -FilePath "C:\Program Files\LibreOffice 5\program\scalc.exe" -ArgumentList "--headless --version" python, using subprocess module, returned the version information. C:\Users\user>python3.exe >>> import subprocess >>> result = subprocess.run(['C:\Program Files\LibreOffice 5\program\soffice.exe', '--version'], stdout=subprocess.PIPE) >>> print(result.stdout) b'LibreOffice 5.4.5.1 79c9829dd5d8054ec39a82dc51cd9eff340dbee8\r\n\r\n'