HVGA preset resizes to show only a 320 pixel wide title & location bar
Although similar to http://windowresizer.userecho.com/topic/674699-current-version-doesnt-resize-correctly/ I think this may be a separate issue. All of the viewport presets work except for HVGA 320 x 480. That one apparently sets the viewport width but fails to set viewport height, as the result is a window that is 320 pixels wide, but has no height, i.e. only the titlebar and location bar are visible.
I'm on Debian sid with Chromium 46.0.2490.71. I haven't yet tested on jessie, but it's likely the issue occurs there, too.
Thanks,
Ben
جواب
I have a partial answer to this based on some further testing. The window is not, in fact, resized to 320 wide. By manually dragging the resize bar on the window, I can see for a particular site, the window and viewport can go no smaller than 372 pixels wide. I suspect what happens here is that when the dimensions go out of bounds, the resize operation fails completely and both width and height are set to minimum possible values.
The only thing I tried which proved fruitful was to switch to various different sites and observe the differences between window and viewport sizes on each. It turns out that different sites place different constraints on minimum window width and minimum viewport width, so the bug does not always occur -- it only happens on sites that prevent the viewport from being resized lower than the dimensions of the preset. I have no publicly accessible URL for the site I'm working on, so these tests were done with random URLs I frequently visit.
For http://weather.gc.ca/city/pages/ns-19_metric_e.html, the minimum width is 372 for both window & viewport. For http://www.cbc.ca/, the minimum viewport width is reported as 263 while the minimum window width is 394, so the 320x480 preset works fine there, whereas it doesn't for the first URL.
So perhaps this is all working as intended, but I think the user could be given some feedback, e.g. a passive bubble complaining about the failure and then do nothing, or else resize as small as possible within the site's constraints instead, and a passive notification of the same. Mysteriously resizing the window to zero dimensions is a rather surprising, and broken-looking result. If you could just make it fail in a less mysterious way, I'd be happy.
Thanks,
Ben
Hi Ben,
Sorry for the late reply, but I was very busy these last days.
I am aware (sort of) of the issue you're talking about. I noticed it happening on Ubuntu and Debian (the only Linux distros I tried it on), on both Chrome and Chromium. This is an issue with the browser (maybe even related to the Linux window managers).
When the extension asks the browser to re-size to a width smaller than the minimum possible for the current window, the window is collapsed to a 0px height, but no error is raised, like everything went fine.
As far as I could see, the minimum width doesn't depend on the website currently loaded, but on:
- the number of opened tabs in the current window
- the number of extension icons visible (those on top right, next to the menu)
- whether the developer tools are visible and docked to the right side of the window
I agree that a message should be shown to the user and this is what will happen in v.2 (which will come at the end of this month): after re-size, the extension will check the window size and see if it's what it should be; if not, then it will reset the window to the original size and display a message to the user letting him/her know that the re-size has failed.
Until v.2 becomes available, I suggest you try the solution I proposed here: http://windowresizer.userecho.com/topic/913830-320-pixel-width-doesnt-work/.
Regards,
Ionuț
Thanks. This works exactly as advertised. At work this is beyond our present requirements, so I filed the issue more because I happened to notice it than due to a business need, but I have some personal projects in which, when I return to them (and if that's before the v.2 release) this will be a handy workaround. Looking forward to the new release!
خدمة دعم العملاء من خلال UserEcho
Hi Ben,
Sorry for the late reply, but I was very busy these last days.
I am aware (sort of) of the issue you're talking about. I noticed it happening on Ubuntu and Debian (the only Linux distros I tried it on), on both Chrome and Chromium. This is an issue with the browser (maybe even related to the Linux window managers).
When the extension asks the browser to re-size to a width smaller than the minimum possible for the current window, the window is collapsed to a 0px height, but no error is raised, like everything went fine.
As far as I could see, the minimum width doesn't depend on the website currently loaded, but on:
I agree that a message should be shown to the user and this is what will happen in v.2 (which will come at the end of this month): after re-size, the extension will check the window size and see if it's what it should be; if not, then it will reset the window to the original size and display a message to the user letting him/her know that the re-size has failed.
Until v.2 becomes available, I suggest you try the solution I proposed here: http://windowresizer.userecho.com/topic/913830-320-pixel-width-doesnt-work/.
Regards,
Ionuț