Ask Your Question
4

How can one properly configure AwesomeWM for multiple monitors, including cloning, activating additional monitors without logging out, arranging monitors vertically, and setting monitor order?

asked 2021-12-25 11:00:00 +0000

woof gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2022-10-23 13:00:00 +0000

devzero gravatar image

To properly configure AwesomeWM for multiple monitors, you can follow these steps:

  1. Install and Start AwesomeWM: Before we begin, make sure AwesomeWM is installed on your system. You can start AwesomeWM by typing awesome in the terminal.

  2. Define Monitors: AwesomeWM comes with xrandr built in, which allows you to specify how many monitors you have connected to your system, and what their resolution and placement are. To define your monitors, launch the AwesomeWM console by pressing Modkey+Enter, and enter the following command:

xrandr --output HDMI1 --mode 1920x1080 --left-of VGA1

In this example, we define two monitors, with HDMI1 on the left, and VGA1 on the right. Make sure to replace HDMI1 and VGA1 with the names of your monitors.

  1. Clone Monitors: If you want to clone your primary monitor to the secondary monitor, use the following command:

xrandr --output HDMI1 --same-as VGA1

This will set both monitors to the same resolution and show the same content on both screens.

  1. Add Monitors: If you want to add an additional monitor, use the following command:

xrandr --output DP1 --auto --right-of HDMI1

In this example, DP1 is the name of the new monitor, and it is placed to the right of HDMI1. Adjust the name and placement based on your configuration.

  1. Change Monitor Resolution: To change the resolution of a monitor, use the following command:

xrandr --output HDMI1 --mode 1280x720

This sets the resolution of the HDMI1 monitor to 1280x720. Adjust the name and resolution based on your configuration.

  1. Arrange Monitors Vertically: If you want to arrange your monitors vertically, use the following command:

xrandr --output HDMI1 --mode 1920x1080 --rotate left --right-of VGA1

This sets HDMI1 to rotate left, and places it to the right of VGA1.

  1. Set Monitor Order: To set the order of your monitors, use the following command:

xrandr --output HDMI1 --primary

This sets HDMI1 as the primary monitor. Adjust the name based on your configuration.

  1. Save and Use Configuration: To use your configurations permanently, create a file named ~/.config/awesome/xrandr.sh, and add the commands you want to use. Then, add the following line to your ~/.config/awesome/rc.lua file:

awful.util.spawn("sh ~/.config/awesome/xrandr.sh")

This will run your xrandr configurations every time you start AwesomeWM.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2021-12-25 11:00:00 +0000

Seen: 8 times

Last updated: Oct 23 '22