[
https://issues.apache.org/jira/browse/GUACAMOLE-1583?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17523255#comment-17523255
]
Nick Couchman commented on GUACAMOLE-1583:
------------------------------------------
The Guacamole Client already measures the dimensions of the available screen
area and sends that along to guacd. However, getting VNC to dynamically resize
is a bit more complicated than that, for a couple of reasons:
* There is no standardized way to deliver screen resolution to the VNC server.
Various VNC servers provide proprietary or at the very least vendor-specific
ways to accomplish this. It seems like it may be possible to implement this
capability, and there's already a Jira issue to cover it: GUACAMOLE-1196.
* Simply using xrandr with the dimensions provided by the client isn't going to
work - while guacd makes the VNC connection, it doesn't talk directly to a
command line or terminal associated with the VNC session, so it can't just send
the xrandr command through to somewhere. This would take a little doing. But,
based on GUACAMOLE-1196 and the feedback Mike provided, I don't think this is
actually required.
Going to close this out as a duplicate of 1196.
> Dynamic Resolution Update for vnc connections
> ---------------------------------------------
>
> Key: GUACAMOLE-1583
> URL: https://issues.apache.org/jira/browse/GUACAMOLE-1583
> Project: Guacamole
> Issue Type: Improvement
> Components: guacamole-server, guacd, Terminal, VNC
> Reporter: Felix Fischer
> Priority: Minor
> Labels: features
>
> I think it would be possible to dynamically update the resolution of a vnc
> connection to the actual browser window size by getting the inner resolution
> of the window using javascript like so:
>
> {code:java}
> window.innerWidth
> window.innerHeight
> {code}
> and then setting this resolution using xrandr.
> I am unsure if it is already possible, but all you would need is a way to
> execute a command in the same shell as the vnc user is logged in (otherwise
> xrandr won't be able to access the display).
> If this was possible, you could simply execute the following commands:
> {{}}
> {code:java}
> cvt "$WIDTH" "$HEIGHT" "$REFRESH" | grep Modeline | sed "s/Modeline//" |
> xargs xrandr --newmode
> xrandr --addmode "$DEVICE" "$WIDTH"x"$HEIGHT"_"$REFRESH".00
> xrandr --output "$DEVICE" --mode "$WIDTH"x"$HEIGHT"_"$REFRESH".00{code}
> {{}}
>
> and this would change the resolution of the xsession to whatever the window
> size was.
--
This message was sent by Atlassian Jira
(v8.20.1#820001)