The Viewer doesn't close on Esc when previewing HTML

The other file extensions which it can preview, like pictures, pdfs, text files and so on are working fine. However, pressing Esc when previewing an HTML file does not do anything. Can this be changed?

Not really, since Esc might need to do something else on a web page, and we have no way of knowing when it's safe to take over the key and when it isn't.

The standalone viewer isn't really expected to be used for HTML at all, although it does work. It's useful in the viewer pane, but if you're opening a separate window then we figure most people are going to open a full web browser for that.

1 Like

I think for quick preview and just general flow of previewing files it is useful. Not every file is a complex HTML. It is a bit contradictory to disable Esc, if you expect user to use the browser anyway for a serious work.

We aren't really disabling Esc. The embedded web browser is handling all keyboard input and we'd have to go out of our way to hook the key in some way. And since we have no way to know when a page is using Esc for something else (which would unexpectedly close the window if we hooked it all the time) and we also did not envisage people wanting to use the standalone viewer to view web content (because it's so limited compared to using a real browser)...

I understand, but In general, I consider this as fast, lightweight preview and not a full blown editor/viewer of any kind. Hence, Esc working still makes sense to me.

Or maybe some app can hook Esc, to be Alt+F4 when Viewer + HTML is detected? lol

Thanks for the feedback.