Resolution changing

I am using Manjaro i3 community edition.

With optimus switch, when I switch between nvidia and intel modes, the resolution of certain applications (like pycharm) change. Could anyone throw any light on this?

Likely related to https://wiki.archlinux.org/index.php/NVIDIA_Optimus#Resolution,_screen_scan_wrong._EDID_errors_in_Xorg.log

certain apps look smaller with nvidia mode, yes?

if you edit /etc/switch/nvidia/nvidia-xorg.conf you should see a DPI option line thats commented out, you can uncomment the line and adjust the values as needed 96x96, 120x120, etc... just be sure whenever you make edits to files in /etc/switch/ directories that you set the mode again after so the changes get applied.

Yes exactly :frowning:

I don't see it :frowning:

[reik@reik-msi ~]$ cat /etc/switch/nvidia/nvidia-xorg.conf
#/etc/X11/xorg.conf.d/99-nvidia.conf
#adjust BusID to match your nvidia GPU


Section "Module"
    Load "modesetting"
EndSection

Section "Device"
    Identifier "nvidia"
    Driver "nvidia"
    BusID "PCI:1:0:0"
    Option "AllowEmptyInitialConfiguration"
EndSection

Maybe I have an older version?

Is optimus-switch on AUR?
I have it from git, is there a way to safely pull and update my installed optimus-switch without breaking stuff?

There is an optimus-manager package in the repo.

Also you can search the forum for optimus - plenty of issues to dive into.

I actually want optimus-switch and not optimus-manager.

yeah, i added that for convenience later. you dont need to pull the whole repo just nvidia-xorg.conf

there's not too much difference from what you already have, just little changes here and there.

replace the contents of /etc/switch/nvidia/nvidia-xorg.conf with the new ones. and sudo set-nvidia.sh after to apply the changes

Option  "DPI" "1920 x 1080"

thats a whole lot of DPI, im assuming you changed it to a sane value?

Haha yes. I confused DPI with resolution and also another error. That's why I deleted it xD
Thank you!

1 Like

i just can't figer it out

#/etc/X11/xorg.conf.d/99-nvidia.conf
#adjust BusID to match your nvidia GPU
#uncomment and edit the DPI option as needed
#to fix scaling issues.


Section "Module"
    Load "modesetting"
EndSection

Section "Device"
    Identifier "nvidia"
    Driver  "nvidia"   
    BusID   "PCI:1:0:0"
    #Option  "DPI" "140 x 140"    #adjust this value as needed to fix scaling
    Option  "AllowEmptyInitialConfiguration"
    Option      "ModeDebug" 
EndSection

Section "Extensions"
    Option  "Composite" "Enable"
EndSection
Graphics:  Device-1: Intel HD Graphics 630 vendor: ASUSTeK driver: i915 v: kernel bus ID: 00:02.0 chip ID: 8086:591b 
           Device-2: NVIDIA GP107M [GeForce GTX 1050 Mobile] vendor: ASUSTeK driver: nvidia v: 430.40 bus ID: 01:00.0 
           chip ID: 10de:1c8d 
           Display: x11 server: X.Org 1.20.5 driver: modesetting,nvidia compositor: kwin_x11 resolution: 1920x1080~60Hz 
           OpenGL: renderer: GeForce GTX 1050/PCIe/SSE2 v: 4.6.0 NVIDIA 430.40 direct render: Yes 

I tried every thing

the DPI option line does nothing unless you uncomment it by removing the # at the beginning of the line, like this


Section "Device"
    Identifier "nvidia"
    Driver  "nvidia"   
    BusID   "PCI:1:0:0"
    Option  "DPI" "140 x 140"    #adjust this value as needed to fix scaling
    Option  "AllowEmptyInitialConfiguration"
    Option      "ModeDebug" 
EndSection

and remember, any changes to files in /etc/switch/* require you to set the mode again to apply the changes.

after edits to /etc/switch/nvidia you would, sudo set-nvidia.sh afterwards

Forum kindly sponsored by Bytemark