Multi-monitor setup

Greetings all,

I have an N-vidia card, a driver of which does support a multi-monitor setup. I had two monitors working by invoking a command xrandr --output VGA-0 --auto --output DVI-I-1 --auto --right-of VGA-0 .

Is there another way, e.g., by adding a configuration to /usr/local/etc/X11/xorg.conf.d, or somehow in the N-vidia settings?

Kindest regards,

M
 
In Xfce, I just configure how I want monitor layout in Settings/Display, then it comes up that way every time I start Xfce.
 
I have an N-vidia card, a driver of which does support a multi-monitor setup. I had two monitors working by invoking a command xrandr --output VGA-0 --auto --output DVI-I-1 --auto --right-of VGA-0 .

Is there another way, e.g., by adding a configuration to /usr/local/etc/X11/xorg.conf.d, or somehow in the N-vidia settings?
First, install x11/nvidia-settings (if you haven’t already done so) and run it. Check if it detects the monitors correctly. I think you can also configure multi-monitor mode there.
 
I hate to confess it, but I also use nvidia-settings. It's a GUI app that allows you to move the monitors around the way you want them. (Hate to confess it because I'm embarrassed to admit I rely on a GUI app to get it the way I like it.)
 
Hi ekvz,

I though about it, but then the system will always come in multimode setup. I would like to dynamically change it. Sorry that I did not mention it.

Hi tingo,

I do not use XFCE.

Hi Olie, Scrotto,

I was unaware of the package, thank you for bringing it to my attention. If it works like on Windows, I could change the setup via the package.

Kindest regards,

M
 
I though about it, but then the system will always come in multimode setup. I would like to dynamically change it.

I see. Well, depending on what's offered by your WM you might be able to define some keybindings. Actually that's what i am using myself to switch from my laptop screen to an external monitor myself. As long as you don't need a ton of options that seems to be the most pragmatic approach since you already know how to archive your goal in terms of shell commands anyways.
 
Hi ekvz,

thank you for the suggestion, that is a great idea. Could you give me some hints how you approached the keybindings? This is a plain vanilla FreeBSD install.

Kindest regards,

M
 
Could you give me some hints how you approached the keybindings? This is a plain vanilla FreeBSD install.

Well, this largely depends on your desktop environment/window manager. I could give you an example but it would only be meaningful if you use IceWM, which is unlikely i think. I guess you'll have to consult the manual of your DE/WM about this, sorry.
 
I'd recommend against using nvidia-settings and keeping xrandr call in your ~/.xinitrc (depending on how you start X), as it's readable and already does what you need.
 
If You don't want to use xrandr then You can create a file in /usr/local/etc/X11/xorg.conf.d/20-monitor.conf which has (e.g.):
Code:
Section "Monitor"
    Identifier  "VGA1"
    Modeline "1920x1080_60.00"
    Option      "Primary" "true"
    Option "DPMS" "true"
EndSection

Section "Monitor"
    Identifier  "HDMI1"
    Modeline "1920x1080_60.00"
    Option      "LeftOf" "VGA1"
    Option "DPMS" "true"
EndSection
 
Hi xthough, Minibari,

thank you for the suggestions, but they are static. I will try to figure out the keybiding as ekvz suggested.

Kindest regards,

M
 
Hi ekvz,

thank you for the suggestion, that is a great idea. Could you give me some hints how you approached the keybindings? This is a plain vanilla FreeBSD install.

You can create keybindings in Openbox's ~/.config/openbox/rc.xml file. Put there xrandr(1) commands to dynamically change one monitor left/right to the other, syntax:
Code:
<keybind key="key-combination">
   <action name="Execute">
      <command>xrandr .....</command>
   </action>
</keybind>
or you can use a X hotkey daemon like x11/sxhkd.
 
Hi xthough, Minibari,

thank you for the suggestions, but they are static. I will try to figure out the keybiding as ekvz suggested.

Kindest regards,

M
You can use x11/xbindkeys for that. e.g:
$ xbindkeys -k
Code:
m:0x4 + c:32
Control + o
m:0x4 + c:33
Control + p
.xbindkeysrc :
Code:
"xrandr --output VGA-0 --auto --output DVI-I-1 --auto --right-of VGA-0"
m:0x4 + c:32
Control+o
"xrandr --output DVI-I-1 --auto --output VGA-0 --auto --right-of DVI-I-1"
m:0x4 + c:33
Control+p

or if You want a "graphical" menu, x11/dmenu can do that.
e.g.
 
Hi T-Daemon, Minibari,

thank you for al the specifics. Now, the problem is, which of the great solutions to use. ;)

I think I will try the T-Daemon's as it appears to be most with the spirit of OpenBox.

Kindest regards,

M
 
Back
Top