Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suggestion for layout in full-screen mode. #76

Open
emukhin opened this issue Sep 6, 2017 · 9 comments
Open

Suggestion for layout in full-screen mode. #76

emukhin opened this issue Sep 6, 2017 · 9 comments
Assignees

Comments

@emukhin
Copy link

emukhin commented Sep 6, 2017

version: latest as of Sept 6, 2017

Here are 2 screenshots with different vnc screen resolutions. My real browser resolution is 1920x1080
1366x1920
1366x1920
1920x1080
1920x1080

I think it should be done this way:
if vnc screen resolution is less than a browser viewport it should be centered and shown with given vnc width.
otherwise, it should be scaled to viewport width with vertical scrollbar.

Now it looks like the width depends on vnc screen height and if it quite large, image becomes too small.

@lanwen
Copy link
Collaborator

lanwen commented Sep 8, 2017

You could try novnc with different settings and say what combination of settings is good for you. You can connect to vnc via novnc with pwd selenoid, and path /vnc/<session-id> on selenoid directly

@emukhin
Copy link
Author

emukhin commented Sep 11, 2017

I'm not sure what you are trying to say. I'm pointing out to not efficient viewport distribution. Cannot come up with reasons why don't you show a browser in full width.

@lanwen
Copy link
Collaborator

lanwen commented Sep 11, 2017

UI simply does nothing with browser width and viewport distribution. By default - xfvb screen greater than browser window, so some black space for UI - still the screen of your session (red arrows) - and can't be distinguished from browser window. We use NOVNC under the hood which has some options to crop the viewport. You can try this options in the original novnc client.

Also, you can try to tune xfvb in the container or the browser resolution with screenResolution capability.

For now, UI just tries to fit the whole vnc screen in external viewport by longest side (You can see div elements edges in inspector). Personally, I don't think scrolls is a good idea in vnc.

@lanwen
Copy link
Collaborator

lanwen commented Sep 11, 2017

So the proposal is to fit by width and align to center if width lesser than external viewport.

Ok, accepted, will think on how to do it

@lanwen lanwen added this to the 1.5.0 milestone Sep 11, 2017
@lanwen lanwen self-assigned this Sep 11, 2017
@vania-pooh vania-pooh removed this from the 1.5.0 milestone Nov 8, 2017
@baranoff-ivan
Copy link

baranoff-ivan commented Feb 8, 2018

If #97 is a duplicate, then this is not improvement. It is a bug. Because maximization feature does not work.

@aemelyan
Copy link

Hi, @lanwen @vania-pooh! Do we have any solutions for this? Still have error "Canvas not supported." and can't maximize window (Firefox 56, Chrome 64)

@vania-pooh
Copy link
Member

vania-pooh commented Feb 19, 2018

@aemelyan maximizing browser windows inside containers is not supported because of missing window manager. As a workaround you are expected to use something like this in your tests:

driver.manage().window().setSize(new Dimension(1920, 1080)); // Java code

This issue is about Selenoid UI layout.

@aemelyan
Copy link

aemelyan commented Feb 19, 2018

@vania-pooh thank you for a quick answer! I believe that my issue a little bit different. I don't use maximizing during test run, instead i set size to browser directly as you show. But when i open VNC on selenoid UI and try to open fullscreen mode, canvas element size is only 1120x630 instead of expected 1920x1080. Here is html - <canvas width="1920" height="1080" style="width: 1120px; height: 630px; cursor: default;">Canvas not supported.</canvas>. I use Chrome 64 that should support canvas. I believe that my issue similar to #97. Any thoughts?

@lanwen
Copy link
Collaborator

lanwen commented Feb 19, 2018

All the drawings are made by js, you won't see anything in html. Issue should be fixed with some tune of novnc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants