UPDATE 10/02/2017
I tested with r247 and NW.js 0.25.0 but the bug still remains.
Workarounds I found are
- Use NW.js v0.13.0 alpha 5
- Use frameless mode (uncheck "Window frame" when you export)
I'll try to reach out people who can take care of this bug.
UPDATE 04/03/2017
For anyone who have the same issue, it's a Nwjs bug and the team is aware of this.
See the links below.
https://github.com/nwjs/nw.js/issues/5337
https://bugs.chromium.org/p/chromium/issues/detail?id=677381
It's been a while since the bug was found so I hope they fix it soon.
Problem Description
When exporting a project as nw.js for desktop, its window size is set as not what originally intended.
Attach a Capx
https://drive.google.com/open?id=0B1SDO1CycJ1XSGRNSlVwQTJxdFU
Description of Capx
Simple layout with one screen size sprite, setting its canvas size and showing nw.js dev tools
Steps to Reproduce Bug
- export a project as nw.js for desktop
- run the exe
Observed Result
The nw.js window size isn't same as the game specified and it causes undesired aspect ratio.
If the game contains sprites, those would be blurry due to the problem.
This issue does happen running a project through Construct 2 too but is less noticeable so easy to miss.
I tired not only the latest version of nw.js but some older ones too. Only v0.13.0 alpha 5 worked properly.
Here are the exported files for convenience sake.
v0.19.2https://drive.google.com/open?id=0B1SDO1CycJ1XOWFJb01RR1pGQ2s
v0.14.5https://drive.google.com/open?id=0B1SDO1CycJ1XU3MwUGNUOU1VWWM
v0.13.2https://drive.google.com/open?id=0B1SDO1CycJ1XR3Fwd0hwbkd0U28
v0.13.0 alpha 5 https://drive.google.com/open?id=0B1SDO1CycJ1XZHBMRGNDTkY0Rk0
Expected Result
The exported nw.js window size should be same as the game originally specified in Construct 2.
Affected Browsers
- Chrome: (NO)
- FireFox: (NO)
- Internet Explorer: (NO)
- nw.js: (YES)
Operating System and Service Pack
Windwos7 64bit
Construct 2 Version ID
r240 with nwjs v0.19.2, v0.14.5, v0.13.2, v0.13.0 alpha 5