-
Notifications
You must be signed in to change notification settings - Fork 1
Home
It's recommended (for quick access) place the .dual-monitor
script into the home directory (however you can place it wherever you want):
$ mv .dual-monitor ~/
- Setup proper output names (may be specific for your system). You can see a list of output names by the following command:
$ xrandr
- Provide executable permissions for the script:
$ sudo chmod +x .dual-monitor
- Kill processes that occupy the
5900
and5901
ports.
-
See the docs at first (the following command prints a manual):
$ bash .dual-monitor
-
Create a mode (there are default arguments for clarity):
$ bash .dual-monitor -c -w 1280 -h 1024 -r 60
-
Enable the mode:
You should see the output of the
$ bash .dual-monitor -e
x11vnc
server. Find a string similar as below there to obtain necessary information (host and port) to connect a vnc viewer (IP address of the host determines automatically):The VNC desktop is: 192.168.1.103:1 PORT=5901
-
Disable the mode and close the tracks:
You should use same arguments as when connecting to disable necessary mode (in other case it may disable any other mode)!
$ bash .dual-monitor -d -w 1280 -h 1024 -r 60
Use primary commands in order mentioned in the documentation if you don't understand how xrandr
works (in other case unexpected behavior may occur).
Don't try to create several same modes (with identical parameters) per a user session! That will not work ;)
**-c**
– create a mode for a virtual output.
**-e**
– enable a mode of a virtual output.
**-d**
– disable a mode of a virtual output.
It's recommended to manually edit this configuration of the script if you will use it frequently with same parameters which differ from defaults!
**-h**
– height of a virtual screen (default 800
, used with the -c
and -d
flags).
**-p**
– primary output name (default LVDS-1
, used with the -c
flag).
**-r**
– refresh frequency of a virtual screen (default 60
, used with the -c
flag).
**-v**
– virtual output name (default VGA-1
, used with the -c
and -d
flags).
**-w**
– width of a virtual screen (default 1280
, used with the -c
and -d
flags).