So… I’ve had 2 monitors working for a long time, and now I also got the TV plugged into the PC… that worked great. so far.
I wanted to play some media on the TV so I installed Kodi which I used a ton before. Inside Kodi I tried switching to a different monitor (via Video settings), which already got a little weird because it stayed on the primary monitor while just reducing or increasing resolution of the Kodi application itself. I then tried the “blank other displays” option in Kodi and that’s when things went sideways…
So first off after disabling the option again, the other displays didn’t turn back on. I then went into the KDE system settings -> display and re-enabled them. Problem is that now the configuration for the second monitor and the TV seems to be swapped and I can’t seem to find a way to swap it back.
I tried enabling and disabling the displays in the right order, disconnecting the TV, rebooting, all kinds of things.
What I mean with swapped is that the task bar that is supposed to be on the second monitor now seems stuck at the TV even after unplugging it. Wallpaper is also also swapped, which is how I noticed it in the first place…
Any idea on how to revert this without having to set up all the KDE panels myself again? I can’t seem to find KDE’s settings directory either.
What I found is ~/.local/share/kscreen, with a bunch of files that seem to be the configuration for the monitor arrangements. But I don’t know how KDE determines which one to use. From the filenames I could also imagine it’s just hashing the monitor EDID’s to figure out the attached monitors or something.
Either way, no idea what to do here to revert whatever Kodi did with the “Blank screens” option
Oh yeah, sound was also fked up until I rebooted (seems like it was speeding up everything …), but it’s working now.
I have only used KDE once or twice, I’m not the best person to answer this. However, if you list the contents of kscreen (I believe there’s a config file), I’ll see if I can’t help you out.
Each with different configs for different arrangements. The only issue is that I don’t know how or where KDE chooses which file to use.
Also don’t know if that would even solve the issue.
I figured that too, but I assume then I would have to set up all the widgets again, which is what I wanted to avoid. I’ll probably mv them to the home-dir or something instead so I can restore them if it doesn’t work.
Well, I only have the task bars really, but I don’t think it’s intended having to do them over again. So it’s also sort of a learning thing
Well… yes, but what I’m worried about is that the panels might be stored separately, but how does it assign the panel configurations for a configured monitor to a physical output?
I mean I assume the panel configuration is a set of settings, which is then applied to a physical output… somehow.
That’s pretty much what I’m wondering from the start… because presumably I would just need to switch the 2 monitors in whatever configuration this is stored in.
So moving the files didn’t work. I moved the directory, shut down the PC and started it again. So it should have been clean I’d expect.
On boot it also asked me how the screen layout it. Interestingly the filename for the layout it created is the same as one of the old ones, so I assume it is some kind of hash, the file contents differ though.
Going to move/copy the old files back and try with the kscreen command.
That also makes me wonder how to get rid of the old config though since I don’t know if any of it is still being used and just not visible due to an “invisible” monitor…
Just tried the console, and this is weird:
[tarulia@localhost kscreen]$ kscreen-console --commands
Unknown option 'commands'.
[tarulia@localhost kscreen]$ kscreen-console --config
Unknown option 'config'.
[tarulia@localhost kscreen]$ kscreen-console --help
Usage: kscreen-console [options] bug|config|outputs|monitor|json [args...]
KScreen Console is a CLI tool to query KScreen status
Commands:
bug Show information needed for a bug report
config Show KScreen config files
outputs Show output information
monitor Monitor for changes
json Show current KScreen config
Options:
-h, --help Displays this help.
Arguments:
command Command to execute
[args...] Arguments for the specified command
also tried kscreen-console config because it’s listed as a command, not an option, but that’s not it either
after some more digging I found where Plasma stores the panel configuration, but it’s not exactly straight forward… It’s one big configuration file: ~/.config/plasma-org.kde.plasma.desktop-appletsrc. It has literally everything in there… just really need to figure out how to swap the monitors…
Nice! I found it! Using a separate post so I can pin it as a solution on the top:
The relevant config-file is located here:
~/.config/plasmashellrc
It’s a simple text file so just open it up. Somewhere in it you fill find a section similar to this:
[ScreenConnectors]
0=DP-2
1=HDMI-1
2=HDMI-2
For me the identifiers 1 and 2 were mixed up. I swapped them, saved, rebooted, and it was fine.
Presumably I could have just swapped the HDMI connectors on the actual GPU. However I am pretty sure I didn’t swap them initially, so I don’t know why they got mixed up in the first place.