\begin{Verbatim}[commandchars=\\\{\}] \PYZsh{}\PYZsh{}\PYZsh{} Separate Arch Linux TTY for spanned monitor gaming. \PYZsh{}\PYZsh{}\PYZsh{} https://www.mikechambers.com/blog/post/2020\PYZhy{}11\PYZhy{}02\PYZhy{}installing\PYZhy{}openbox\PYZhy{}on\PYZhy{}arch\PYZhy{}linux/ \PYZsh{} To start with, we need a minimal window management server sudo pacman \PYZhy{}S openbox \PYZsh{} We\PYZsq{}ll need gamescope sudo pacman \PYZhy{}S gamescope \PYZsh{} We\PYZsq{}ll need some automation tools. sudo pacman \PYZhy{}S xdotool wmctrl \PYZsh{}\PYZsh{}\PYZsh{} Install and Configure Openbox \PYZsh{}\PYZsh{}\PYZsh{} We\PYZsq{}re gonna setup some of Openbox first before setting up an autologin TTY. That\PYZsq{}ll be at the end. \PYZsh{} Copy over config files to the /home directory. mkdir \PYZhy{}p \PYZti{}/.config/openbox cp \PYZhy{}a /etc/xdg/openbox/ \PYZti{}/.config/ \PYZsh{} Make sure you set the proper home directory for Openbox. It\PYZsq{}s fussy about what\PYZsq{}s right. export XDG\PYZus{}CONFIG\PYZus{}HOME=\PYZdl{}HOME/.config/ Now, by default, when you log in, you login into blank screens with just a cursor. Right Clck where there no window brings up a launch menu that may reference programs you don\PYZsq{}t actually have. Alt lets you drag windows when you click it and click hold any window. In the Openbox menu, navigate to terminals, open one of them. In my case, I have konsole, but I don\PYZsq{}t have any of he file managers referenced by default. I do have dolphin. That\PYZsq{}s okay. In konsole, I can just type dolphin and kate to launch them respectively if I don\PYZsq{}t want to do any console based text editing or file management. First we\PYZsq{}ll setup our autostart. You don\PYZsq{}t have to copy this exactly, these are just things I want on my openbox session start to make transitioning into gaming straightforward. \PYZus{}\PYZus{}/.config/openbox/autostart \PYZsh{}!/bin/bash \PYZsh{} Set monitor arrangement xrandr \PYZhy{}\PYZhy{}output DisplayPort\PYZhy{}0 \PYZhy{}\PYZhy{}primary \PYZhy{}\PYZhy{}mode 1920x1080 \PYZhy{}\PYZhy{}pos 1920x1080 \PYZbs{} \PYZhy{}\PYZhy{}output DisplayPort\PYZhy{}1 \PYZhy{}\PYZhy{}mode 1920x1080 \PYZhy{}\PYZhy{}pos 3840x1080 \PYZbs{} \PYZhy{}\PYZhy{}output HDMI\PYZhy{}A\PYZhy{}0 \PYZhy{}\PYZhy{}mode 1920x1080 \PYZhy{}\PYZhy{}pos 0x1080 \PYZbs{} \PYZhy{}\PYZhy{}output HDMI\PYZhy{}A\PYZhy{}1 \PYZhy{}\PYZhy{}mode 1920x1080 \PYZhy{}\PYZhy{}pos 5760x1080 \PYZbs{} \PYZhy{}\PYZhy{}output DisplayPort\PYZhy{}1\PYZhy{}3 \PYZhy{}\PYZhy{}mode 1920x1080 \PYZhy{}\PYZhy{}pos 1920x0 \PYZsh{} Wait for monitors to initialize sleep 2 \PYZsh{} Application Autostart Block \PYZti{}/.config/openbox/gamescope\PYZhy{}positioner.sh \PYZam{} konsole \PYZam{} steam \PYZam{} wait Openbox has no GUI program to set your monitor arrangements and it actually doesn\PYZsq{}t save them. On login, you have to set your monitor arrangement by hand. What I recommend is going to a fuller desktop environment that has has a GUI monitor arranger, and use the command: xrandr \PYZhy{}\PYZhy{}listmonitors Then use those positions to build a line of xrandr \PYZhy{}\PYZhy{}ouput commands. I use 5 monitors, but a simpler line of 3 monitors would look like: xrandr \PYZhy{}\PYZhy{}output DisplayPort\PYZhy{}0 \PYZhy{}\PYZhy{}primary \PYZhy{}\PYZhy{}mode 1920x1080 \PYZhy{}\PYZhy{}pos 1920x0 \PYZbs{} \PYZhy{}\PYZhy{}output DisplayPort\PYZhy{}1 \PYZhy{}\PYZhy{}mode 1920x1080 \PYZhy{}\PYZhy{}pos 3840x0 \PYZbs{} \PYZhy{}\PYZhy{}output HDMI\PYZhy{}A\PYZhy{}0 \PYZhy{}\PYZhy{}mode 1920x1080 \PYZhy{}\PYZhy{}pos 0x0 \PYZbs{} \PYZsh{} Wait for monitors to initialize sleep 2 Make sure that or something smiliar is at the start of your autstart. Menu.xml,tba RC.xml, tba \PYZsh{}\PYZsh{}\PYZsh{} Steam \PYZsh{}\PYZsh{}\PYZsh{} I\PYZsq{}ll assume you already have Steam installed and configured on your other Desktop Envrionment. Instead, we\PYZsq{}ll skip to launching games and assuring that the game window appears in a spanned resolution. Note that if you use Big Picture to launch games, you need to go into Menu \PYZgt{} Settings \PYZgt{} Display, and tick use Windowed Mode for Big Picture. By default, Big Picture if a fullscreen app on your primary monitor, which sits over gamescope windows. If you want to keep the fullscreen big picture environment, that\PYZsq{}s fine, but what you\PYZsq{}ll have to do on each game launch is Alt+Tab back to Steam Big Picture, press Alt+Space, and press N. In any game in your library, go to launch options. Add this to the launch options: gamescope \PYZhy{}w 5760 \PYZhy{}h 1080 \PYZhy{}W 5760 \PYZhy{}H 1080 \PYZhy{}b \PYZhy{}\PYZhy{}display\PYZhy{}index 2 \PYZhy{}\PYZhy{}force\PYZhy{}grab\PYZhy{}cursor \PYZhy{}\PYZhy{} \PYZpc{}command\PYZpc{} \PYZsh{} \PYZhy{}w \PYZhy{}h, game content width and height. Upscaling this would let you make a pseudo AMD Virtual Super Resolution \PYZsh{} \PYZhy{}W \PYZhy{}H, game window width and height. \PYZsh{} \PYZhy{}b, borderless fullscreen \PYZsh{} \PYZhy{}\PYZhy{}display\PYZhy{}index 2, 2 in my case as explained above. You want this to be your left\PYZhy{}most monitor. \PYZsh{} \PYZhy{}\PYZhy{}force\PYZhy{}grab\PYZhy{}cursor, this keeps the mouse from wigging out when you\PYZsq{}re managing other applications. Now wait, we\PYZsq{}re not done. \PYZus{}\PYZus{}/.config/openbox/gamescope\PYZhy{}positioner.sh \PYZsh{}!/bin/bash \PYZsh{} Gamescope window positioner for Openbox echo \PYZdq{}Starting gamescope window positioner...\PYZdq{} while true; do \PYZsh{} Find ALL gamescope windows and move them xdotool search \PYZhy{}\PYZhy{}class \PYZdq{}gamescope\PYZdq{} 2\PYZgt{}/dev/null | while read WINDOW\PYZus{}ID; do if [ ! \PYZhy{}z \PYZdq{}\PYZdl{}WINDOW\PYZus{}ID\PYZdq{} ]; then \PYZsh{} Get current window position CURRENT\PYZus{}POS=\PYZdl{}(xdotool getwindowgeometry \PYZdq{}\PYZdl{}WINDOW\PYZus{}ID\PYZdq{} | grep Position | awk \PYZsq{}\PYZob{}print \PYZdl{}2\PYZcb{}\PYZsq{}) DESIRED\PYZus{}POS=\PYZdq{}0, 0\PYZdq{} \PYZsh{} Only move if not already in position if [ \PYZdq{}\PYZdl{}CURRENT\PYZus{}POS\PYZdq{} != \PYZdq{}\PYZdl{}DESIRED\PYZus{}POS\PYZdq{} ]; then echo \PYZdq{}Moving gamescope window \PYZdl{}WINDOW\PYZus{}ID to 0,1080\PYZdq{} xdotool windowmove \PYZdq{}\PYZdl{}WINDOW\PYZus{}ID\PYZdq{} 0 0 \PYZsh{} xdotool windowsize \PYZdq{}\PYZdl{}WINDOW\PYZus{}ID\PYZdq{} 5760 1080 fi \PYZsh{} FORCE it to be above everything else, including Steam \PYZsh{} echo \PYZdq{}Forcing gamescope window \PYZdl{}WINDOW\PYZus{}ID to top layer\PYZdq{} \PYZsh{} wmctrl \PYZhy{}i \PYZhy{}r \PYZdq{}\PYZdl{}WINDOW\PYZus{}ID\PYZdq{} \PYZhy{}b add,above \PYZsh{} xdotool windowraise \PYZdq{}\PYZdl{}WINDOW\PYZus{}ID\PYZdq{} fi done sleep 2 done chmod +x /.config/openbox/gamescope\PYZhy{}positioner.sh As insurance, this script catches, sizes, and forcibly moves gamescope windows to 0,0, which is where (in most cases) the top\PYZhy{}left corner of the monitor span will be. This script is launched as part of the Login autostart. \PYZsh{}\PYZsh{}\PYZsh{} Autologin TTY \PYZsh{}\PYZsh{}\PYZsh{} tba \end{Verbatim}