Closed hongyi-zhao closed 4 years ago
My observation is a bit different so far:
--xephyr
always triggers the problem--nxagent
, --xpra
sometimes triggers the problem--weston-xwayland
never triggers the problemVery strange. What's your host OS?
What's your host OS?
$ lsb_release -a No LSB modules are available. Distributor ID: Debian Description: Debian GNU/Linux bullseye/sid Release: testing Codename: bullseye
Maybe this partially depends on speed. The X server is starting up, and the container system is booting. Maybe at some point of the container system boot the X server is ready to accept a resize request, or it is not. I wouldn't worry to much about this. It would be rather interesting if the Gnome 3 desktop could be configured not to resize the X server on its own.
It is possible to resize the window with xrandr
from package x11-xserver-utils
.
The last entry is the one originally set by x11docker:
$ xrandr
xrandr: Failed to get size of gamma for output default
Screen 0: minimum 160 x 160, current 1600 x 1200, maximum 1824 x 1200
default connected primary 1600x1200+0+0 (normal left inverted right x axis y axis) 0mm x 0mm
1600x1200 0.00*
1400x1050 0.00
1280x960 0.00
1280x1024 0.00
1152x864 0.00
1024x768 0.00
832x624 0.00
800x600 0.00
720x400 0.00
480x640 0.00
640x480 0.00
640x400 0.00
320x240 0.00
240x320 0.00
160x160 0.00
1824x984 0.00
It can be set with:
xrandr --output default --mode 1824x984
It is possible to resize the window with
xrandr
from packagex11-xserver-utils
. The last entry is the one originally set by x11docker:$ xrandr xrandr: Failed to get size of gamma for output default Screen 0: minimum 160 x 160, current 1600 x 1200, maximum 1824 x 1200 default connected primary 1600x1200+0+0 (normal left inverted right x axis y axis) 0mm x 0mm 1600x1200 0.00* 1400x1050 0.00 1280x960 0.00 1280x1024 0.00 1152x864 0.00 1024x768 0.00 832x624 0.00 800x600 0.00 720x400 0.00 480x640 0.00 640x480 0.00 640x400 0.00 320x240 0.00 240x320 0.00 160x160 0.00 1824x984 0.00
See the results of mine:
$ xrandr
Screen 0: minimum 8 x 8, current 1920 x 1080, maximum 32767 x 32767
DP-0 disconnected (normal left inverted right x axis y axis)
DP-1 disconnected (normal left inverted right x axis y axis)
HDMI-0 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 525mm x 297mm
1920x1080 60.00*+
1680x1050 59.95
1280x1024 75.02 72.00 70.00 60.02
1280x960 60.00
1024x768 75.03 70.07 60.00
800x600 75.00 72.19 60.32 56.25
640x480 75.00 72.81 59.94
DP-2 disconnected (normal left inverted right x axis y axis)
DP-3 disconnected (normal left inverted right x axis y axis)
DP-4 disconnected (normal left inverted right x axis y axis)
DP-5 disconnected (normal left inverted right x axis y axis)
USB-C-0 disconnected (normal left inverted right x axis y axis)
Why it's very different in form from yours?
It can be set with:
xrandr --output default --mode 1824x984
Do you mean run this command with different --mode
on host to resize the deepin container's window size?
Why it's very different in form from yours?
That is the output for your host. I mean to run within the container.
Do you mean run this command with different --mode on host to resize the deepin container's window size?
I mean to run it in container. Currently I try to add an autostart entry. So far it works for --xephyr
that has output name default
:
RUN env DEBIAN_FRONTEND=noninteractive apt-get install -y \
x11-xserver-utils
RUN echo "#! /bin/sh\n\
xrandr --output default --mode \$(xrandr 2>&1 | tail -n1 | awk '{print \$1}')\n\
" > /usr/local/bin/x11docker-xrandr-xephyr && chmod +x /usr/local/bin/x11docker-xrandr-xephyr && \
mkdir -p /etc/xdg/autostart && \
echo "[Desktop Entry]\n\
Encoding=UTF-8\n\
Version=0.9.4\n\
Type=Application\n\
Name=x11docker-xrandr-xephyr\n\
Comment=\n\
Exec=/usr/local/bin/x11docker-xrandr-xephyr\n\
" > /etc/xdg/autostart/x11docker-xrandr-xephyr.desktop
I mean to run it in container. Currently I try to add an autostart entry.
Can this be done with a newly added x11docker option? If so, it will be more transferable and convenient for using it.
I've added this to x11docker, always done now without an option. So it fixes x11docker/cinnamon
and x11docker/gnome
as well.
Note that this needs xrandr
/ package x11-xserver-utils
in image.
Great. I've added this package into my Dockerfile.
I noticed that you told the following here:
With x11docker default X server option --xephyr the desktop window size is too large, deepin does some odd resizing. Try --nxagent, --xpra or --weston-xwayland instead. These options allow to resize the window.
We have discussed this problem here. But based on my further tries, the results are still different from your above conclusion. To be simple, the phenomenon I observed is as follows:
EDIT: