plasma5 screen management going wrong

Bug Reporter bugreporter11 at gmail.com
Fri Jul 13 03:00:58 BST 2018


On Thu, Jul 12, 2018 at 7:06 PM, Bug Reporter <bugreporter11 at gmail.com> wrote:
> On Thu, Jul 12, 2018 at 6:03 PM, Bug Reporter <bugreporter11 at gmail.com> wrote:
>> see below
>>
>> On Thu, Jul 12, 2018 at 2:20 AM, Duncan <1i5t5.duncan at cox.net> wrote:
>>> Bug Reporter posted on Wed, 11 Jul 2018 21:05:22 -0400 as excerpted:
>>>
>>>> see below
>>>>
>>>> On Mon, Jul 2, 2018 at 2:25 AM, Duncan <1i5t5.duncan at cox.net> wrote:
>>>>> Bug Reporter posted on Sun, 01 Jul 2018 21:17:29 -0400 as excerpted:
>
>> Some questions include:
>>
>> - Upon putting the laptop on the dock (multiple external monitors) can
>> I run my randr script (or command) to activate the dock-connected
>> monitors without logging out of plasma?
>
> YES.
>
>>
>> - Upon undocking, I assume I would run another randr script to disable
>> the external monitors, then I would undock the laptop.
>
> YES
>
>>
>> - Say I have two different docking stations (one in the east coast
>> office one in the west coast office). Say both have the identical
>> monitor layout (e.g., two 1920x1080 HDMI monitors side by side). Will
>> the same randr dock-connect script work at the other office? The
>> monitors will have different EDID's, of course. But the relative
>> positions and the resolutions will be the same.
>
> This would appear to depend upon the names of the screens, such as
> "DP-2-1". My guess is that if the dock itself is the same model
> device, the display ports may be named the same by xrandr. Obviously,
> it is not hard to come up with the required command for additional
> office locations. However, it would be more convenient if a
> non-technical user (one who can barely use a terminal) had exactly one
> command to execute for docking, regardless of the office. But, in
> worst case, I can see making scripts or aliases such as "dock-east"
> and "dock-west". The undock script/alias would always be the same.
>
>>
>> - With xorg conf files, I assume that switching from the undocked to
>> the docked configuration requires logging out of plasma, restarting X,
>> and logging back in. Correct?
>
> I don't know. I did not create any xorg.conf files yet. Will I need to
> create them?
>
>>
>> - Are there frequent or common situations where one could lose all
>> monitor output and a non-sudo user would be required to restart the
>> computer?
>
> After just a little testing, this seems like a robust solution.
>
> However, the key to whether or not this will be practical for me is
> power management. Having to remove KDE's PowerDevil means I now have
> to go and explore alternative means of managing power on a laptop. Any
> suggestions?

The lack of powerdevil may be the showstopper in this process. So I
started looking for a config file that might disable kscreen. I did
not find any yet, but I did find kscreen-doctor. This might be the way
to leave kscreen installed and to manage it the way one would manage
screens with xorg conf files or with xrandr.

Interestingly, `kscreen-doctor -i` tells me: Preferred KScreen backend
: KSC_XRandR.so

KSC_XRandR.so: /usr/lib/qt/plugins/kf5/kscreen/KSC_XRandR.so

I don't know exactly what that is, but the name gives me the feeling
that kscreen-doctor might be able to be used like xrandr... any
thoughts?

# /usr/bin/kscreen-doctor --help

Usage: /usr/bin/kscreen-doctor [options] [output.<name>.<setting>
output.<name>.setting [...]]
kscreen-doctor allows to change the screen setup from the command-line.

Setting the output configuration is done in an atomic fashion, all settings
are applied in a single command.
kscreen-doctor can be used to enable and disable outputs, to position screens,
change resolution (mode setting), etc.. You should put all your options into
a single invocation of kscreen-doctor, so they can all be applied at once.

Usage examples:

   Show output information:
   $ kscreen-doctor -o
   Output: 1 eDP-1 enabled connected Panel Modes: Modes: 1:800x600 at 60
[...] Geometry: 0,0 1280x800
   Output: 70 HDMI-2 enabled connected  HDMI Modes: 1:800x600 at 60 [...]
Geometry: 1280,0 1920x1080

   Disable the hdmi output, enable the laptop panel and set it to a
specific mode
   $ kscreen-doctor output.HDMI-2.disable output.eDP-1.mode.1
output.eDP-1.enable

   Position the hdmi monitor on the right of the laptop panel
   $ kscreen-doctor output.HDMI-2.position.0,1280 output.eDP-1.position.0,0

   Set resolution mode
   $ kscreen-doctor output.HDMI-2.mode.1920x1080 at 60

   Set scale (note: fractional scaling is only supported on wayland)
   $ kscreen-doctor output.HDMI-2.scale.2

   Set rotation (possible values: none, left, right, inverted)
   $ kscreen-doctor output.HDMI-2.rotation.left


Options:
  -h, --help           Displays this help.
  -i, --info           Show runtime information: backends, logging, etc.
  -j, --json           Show configuration in JSON format
  -o, --outputs        Show outputs
  -d, --dpms <off>     Display power management (wayland only)
  -l, --log <comment>  Write a comment to the log file

Arguments:
  config               Specific output settings are separated by spaces, each
                       setting is in the form of
                       output.<name>.<setting>[.<value>]
                       For example:
                       $ kscreen-doctor output.HDMI-2.enable \
                                      output.eDP-1.mode.4 \
                                      output.eDP-1.position.1280,0
                       Multiple settings are passed in order to have
                       kscreen-doctor apply these settings in one go.

I do not see a man page for kscreen-doctor and I don't see it
discussed on any wikis. Does anyone here have any experience using it?

I would like to know what the modes numbers mentioned above are. For
example, what is mode 4 in "output.eDP-1.mode.4"?




More information about the kde mailing list