nw.js
nw.js copied to clipboard
Window is not centered vertically when "center" position is requested
NWJS Version : 0.44.3 Operating System : macOS Catalina (10.15.3)
Expected behavior
Window should be centered vertically
Actual behavior
Window is centered around 1/3 of screen height, closer to the top
How to reproduce
rm -rf "${HOME}/Library/Application Support/nwjs-test" && \
cd /tmp && rm -rf nwjs-test && mkdir nwjs-test && cd nwjs-test && \
echo '{"name": "nwjs-test", "main": "data:,test", "window": {"id": "test", "title": "position test", "position": "center", "width": 200, "height": 200}}' > package.json && \
~/Downloads/nwjs-sdk-v0.44.3-osx-x64/nwjs.app/Contents/MacOS/nwjs .
or simply executing the following in dev tools console
nw.Window.open('data:,test', {id: 'dialog', position: 'center', width:200, height: 200})
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.