[WORKAROUND]Mageia 9 Plasma Graphical Glitches at Login

This forum is dedicated to basic help and support :

Ask here your questions about basic installation and usage of Mageia. For example you may post here all your questions about getting Mageia isos and installing it, configuring your printer, using your word processor etc.

Try to ask your questions in the right sub-forum with as much details as you can gather. the more precise the question will be, the more likely you are to get a useful answer

[WORKAROUND]Mageia 9 Plasma Graphical Glitches at Login

Postby banjo » Mar 9th, '24, 22:28

I am running Magiea 9 using the on-board Intel graphics. I have two monitors connected to the graphics. When I set up Plasma to start with an empty session, and start my desired applications in Autostart, Plasma starts the applications and then moves all of them to the center of the left screen when I log in.

Inxi information

Code: Select all
System:
  Host: linux6core Kernel: 6.6.18-desktop-1.mga9 arch: x86_64 bits: 64
    Desktop: KDE Plasma v: 5.27.10 Distro: Mageia 9
Machine:
  Type: Desktop Mobo: Micro-Star model: MPG Z490 GAMING EDGE WIFI (MS-7C79)
    v: 1.0 serial: <superuser required> UEFI: American Megatrends v: 1.C0
    date: 06/10/2022
CPU:
  Info: 6-core 11th Gen Intel Core i5-11400 [MT MCP] speed (MHz): avg: 800
    min/max: 800/4400
Graphics:
  Device-1: Intel RocketLake-S GT1 [UHD Graphics 730] driver: i915 v: kernel
  Display: x11 server: X.org v: 1.21.1.8 with: Xwayland v: 22.1.9 driver: X:
    loaded: modesetting,v4l dri: iris gpu: i915 resolution: 1: 1920x1080~60Hz
    2: 1920x1080~60Hz
  API: OpenGL v: 4.6 Mesa 23.3.5 renderer: Mesa Intel Graphics (RKL GT1)
Network:
  Device-1: Intel Comet Lake PCH CNVi WiFi driver: iwlwifi
  Device-2: Realtek RTL8125 2.5GbE driver: r8169
Drives:
  Local Storage: total: 954.81 GiB used: 50.6 GiB (5.3%)
Info:
  Processes: 316 Uptime: 54m Memory: 31.2 GiB used: 2.59 GiB (8.3%)
  Shell: Bash inxi: 3.3.26


Most of the applications that I am running are standalone applications that I wrote myself. They are simply executable files, and are not installed via rpm. However, one of the applications is gkrellm, which is officially installed from the repositories.

The backstory: In past versions of Plasma (Mag 7 and Mag 8), I have seen flaky behavior when I allowed Plasma to save and restore my sessions, so I gave up on that and now I tell it to open an empty session. Then, I run the apps myself using the Startup and Shutdowhn => Autostart system. This is working fine on Mageia 8.

My applications work by saving their geometry in their own configuration file when they close, and then they read that information back in at startup and restore their size and position with calls to QT. All of my apps use QT for their graphics. If I run the applications manually, this system works fine.

I do not know how gkrellm saves its geometry information.

So I set up my desktop with my applications on the far right like this (the two screens have different background images):

PlasmaLoginProblem-Screenshot_20240309_111503-1920.png
PlasmaLoginProblem-Screenshot_20240309_111503-1920.png (2.19 MiB) Viewed 4821 times


I log out and then log back in, and the desktop starts up like this:

PlasmaLoginProblem-Screenshot_20240309_112553-1920.png
PlasmaLoginProblem-Screenshot_20240309_112553-1920.png (2.17 MiB) Viewed 4821 times



If I move the applications back to where I want them to be, then log out and back in, Plasma centers them all on the left screen again.

I would be suspicious of a bug in the positioning of my own applications on the screen except that gkrellm suffers from the same problem.

I have tried some different things to get around the problem, for example, I set up the system to save my session at logout and restore it. When I did that, and logged out, nothing of my session was saved to .config/ksmserverrc. When I logged back in, it restored an old old session with a different program in it, and none of the ones I was running when I logged out.

Here's the ~/.config/ksmserverrc

Code: Select all
[$Version]
update_info=ksmserver_update_loginMode_value.upd:ksmserver_update_loginMode_value_default_enum

[LegacySession: saved at previous logout]
count=0

[LegacySession: saved by user]
count=0

[Session: saved at previous logout]
clientId1=1028c1d320b210000166923851700000433930004
clientId2=1028c1d320b210000166923899200000433930021
count=2
program1=/usr/bin/kalendarac
program2=/home/brian/bin/MOBO
restartCommand1=/usr/bin/kalendarac,-session,1028c1d320b210000166923851700000433930004_1669239519_818043
restartCommand2=/home/brian/bin/MOBO,-session,1028c1d320b210000166923899200000433930021_1669239519_820930
restartStyleHint1=0
restartStyleHint2=0
userId1=brian
userId2=brian

[Session: saved by user]
clientId1=10156104d1e4000171000189600000070090004
clientId2=10156104d1e4000171000189600000070090006
clientId3=10156104d1e4000170984107500000183110004
clientId4=10156104d1e4000170984107500000183110005
clientId5=10156104d1e4000170984107500000183110006
clientId6=10156104d1e4000170984107500000183110007
clientId7=10156104d1e4000170984107500000183110008
clientId8=10156104d1e4000170984107500000183110013
count=8
program1=/usr/bin/hp-systray
program2=/usr/bin/kalendarac
program3=/home/brian/bin/mobo
program4=/home/brian/bin/NixieClock3
program5=/home/brian/bin/Wx
program6=/home/brian/bin/mac
program7=/home/brian/bin/DGEyes
program8=/usr/bin/gkrellm
restartCommand1=/usr/bin/hp-systray,-session,10156104d1e4000171000189600000070090004_1710001945_343446,-name,hp-systray
restartCommand2=/usr/bin/kalendarac,-session,10156104d1e4000171000189600000070090006_1710001945_343446
restartCommand3=/home/brian/bin/mobo,-session,10156104d1e4000170984107500000183110004_1710001945_343457
restartCommand4=/home/brian/bin/NixieClock3,-session,10156104d1e4000170984107500000183110005_1710001945_343469
restartCommand5=/home/brian/bin/Wx,-session,10156104d1e4000170984107500000183110006_1710001945_343467
restartCommand6=/home/brian/bin/mac,-session,10156104d1e4000170984107500000183110007_1710001945_343477
restartCommand7=/home/brian/bin/DGEyes,-session,10156104d1e4000170984107500000183110008_1710001945_343614
restartCommand8=/usr/bin/gkrellm,--sm-client-id,10156104d1e4000170984107500000183110013
restartStyleHint1=0
restartStyleHint2=0
restartStyleHint3=0
restartStyleHint4=0
restartStyleHint5=0
restartStyleHint6=0
restartStyleHint7=0
restartStyleHint8=0
userId1=brian
userId2=brian
userId3=brian
userId4=brian
userId5=brian
userId6=brian
userId7=brian
userId8=brian



Then, I set it up to resotre a manually saved session, configured the desktop, and saved the session. When I log back in, it usually restores the session properly, although occasionally some of my applications end up on the left screen anyway.

My Mageia 8 system (KDE Plasma 5.20.4 Distro: Mageia 8 mga8) has always had a similar issue where the intial login after a reboot confuses the screens and sets them up incorrectly. But that corrects itself after the initial login, so we just live with it. I did find that on Mageia 8 (Plasma 5.20.4) if I boot the system first and then turn on the monitors it works fine, and the screens and apps initialize properly.

So, I tried doing that on the Mageia 9 system, booting first and then turning on the monitors, but that did not fix the issue. Honestly, laying out my desktop every time I log in is not an acceptable situation. My current workaround is to set up Plasma to restore a manually saved session, but that doesn't always work either.

Any ideas of what to try to fix this would be appreciated. These glitches seem to involve some complex communications between the monitors, the graphics card, SDDM, Plasma, and who knows what else.

I am currently installing Mageia 9 on my Mageia 8 computer, which uses the Nvidia RTX 3050 graphics card. When I get that done, I will report back whether or not the problem appears on the Nvidia graphics hardware. If it does not, then it is dependent on the onboard Intel graphics on the other computer.

Thanks,
Banjo
(_)=='=~
Last edited by banjo on Mar 17th, '24, 15:45, edited 1 time in total.
If only the best bird sang, the forest would be a very quiet place.
User avatar
banjo
 
Posts: 476
Joined: May 4th, '11, 03:50
Location: Reading, Massachusetts

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby doktor5000 » Mar 9th, '24, 23:16

Why not simply configure the initial placement via kwin rules with X and Y coordinates for those windows ?
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18032
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby banjo » Mar 11th, '24, 14:58

I can give that a try to see if it has any effect, but my goal when writing the programs was to allow me to drop them where I want them and they will be there the next time I run them. Setting fixed locations might defeat that purpose.

It would be interesting to see what effect that would have. I have not used kwin rules, so it is something new to learn.
If only the best bird sang, the forest would be a very quiet place.
User avatar
banjo
 
Posts: 476
Joined: May 4th, '11, 03:50
Location: Reading, Massachusetts

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby doktor5000 » Mar 11th, '24, 18:09

It might help if you would add some details how you implemented the initial window placement in your Qt programs.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18032
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby banjo » Mar 12th, '24, 00:09

I have a MainWindow class that has a QWidget that is designed in QT Designer for displaying the information (e.g. a clock face). That display widget is set as the central widget of the Mainwindow class.

In the mainwindow constructor it calls an init() method that reads its configuration file into a Config object and initializes the program.

Code: Select all
MainWindow::MainWindow(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::MainWindow)
{
    ui->setupUi(this);

    this->init();

}


In the init() method I remove all the decorations to make the clock face float on the background.

Code: Select all
    this->setCentralWidget(displayWidget);

    // Get rid of all the decorations
    this->setWindowFlags(Qt::FramelessWindowHint | Qt::WindowSystemMenuHint);
    // Make the MainWindow transparent
    this->setAttribute(Qt::WA_TranslucentBackground, true);



It sets up some context menu items, starts an update timer, then uses the geometry values to set the size and location of the window.

Code: Select all
    // Move the window to the specified location and resize it.
    this->resize(configPtr->config_width, configPtr->config_height);
    this->move(configPtr->config_xloc, configPtr->config_yloc);


That's pretty much it. The rest of the code reacts to the timer signal and/or menu clicks and updates the graphics.

This has worked fine for quite a while now.

I don't remember if I have recompiled the programs on Mag 9 or not. I could try that and see if it makes a difference.

I still have not found time to try Mageia 9 on my other computer with the Nvidia card in it. I will try to get that done.
If only the best bird sang, the forest would be a very quiet place.
User avatar
banjo
 
Posts: 476
Joined: May 4th, '11, 03:50
Location: Reading, Massachusetts

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby doktor5000 » Mar 12th, '24, 19:20

From what I read, you should be calling setGeometry at some point: https://doc.qt.io/qt-5/qwidget.html#setGeometry-1
Maybe it's better if you ask that in the KDE forums, maybe someone there has some hints what goes wrong.

Also check if one of those helps:
https://www.reddit.com/r/kde/comments/g ... g_monitor/
https://store.kde.org/p/1617641
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18032
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby banjo » Mar 13th, '24, 23:40

Thanks for the pointers. I will take a look and see what I can do for a workaround.

I installed Mageia 9 on this other computer with the Nvidia card in it, and the problems persist, so it does not seem to depend on the graphics system.

Here is the inxi for this computer

Code: Select all
[poobah@localhost ~]$ inxi -b
System:
  Host: localhost Kernel: 6.6.14-desktop-2.mga9 arch: x86_64 bits: 64
    Desktop: KDE Plasma v: 5.27.5 Distro: Mageia 9
Machine:
  Type: Desktop Mobo: Micro-Star model: MPG Z590 GAMING PLUS (MS-7D07) v: 2.0
    serial: <superuser required> UEFI: American Megatrends LLC. v: A.10
    date: 04/09/2021
CPU:
  Info: 8-core 11th Gen Intel Core i7-11700K [MT MCP] speed (MHz): avg: 800
    min/max: 800/4900:5000
Graphics:
  Device-1: NVIDIA GA106 [Geforce RTX 3050] driver: nvidia v: 535.154.05
  Display: x11 server: X.org v: 1.21.1.8 with: Xwayland v: 22.1.9 driver: X:
    loaded: nvidia,v4l gpu: nvidia resolution: 1: 1920x1080~60Hz
    2: 1920x1080~60Hz
  API: OpenGL v: 4.6.0 NVIDIA 535.154.05 renderer: NVIDIA GeForce RTX
    3050/PCIe/SSE2
Network:
  Device-1: Intel Ethernet I225-V driver: igc
Drives:
  Local Storage: total: 1.82 TiB used: 33.97 GiB (1.8%)
Info:
  Processes: 327 Uptime: 16m Memory: 31.25 GiB used: 2.02 GiB (6.5%)
  Shell: Bash inxi: 3.3.26
[poobah@localhost ~]$


Logging out and logging back in results in random outcomes. Sometimes it leaves all of the windows alone, sometimes it just moves gkrellm to the center of the primary screen. Sometimes it moves all of the apps to the left hand screen.

Here is the original setup of the screens.

Mag9PlasmaScreensOriginalSetup.png
Mag9PlasmaScreensOriginalSetup.png (175.73 KiB) Viewed 4670 times


I log out and then log back in, and sometimes it just moves gkrellm.

Mag9PlasmaScreensJustGkrellmMoved.png
Mag9PlasmaScreensJustGkrellmMoved.png (173.71 KiB) Viewed 4670 times


Sometimes, it centers all of the windows on the left hand screen.

Mag9PlasmaScreensEverythingMoved.png
Mag9PlasmaScreensEverythingMoved.png (172.17 KiB) Viewed 4670 times


It also resorted my desktop icons once (just once), but I didn't get a screencap of that.

It feels like a problem that might be caused by asynchronous processes starting at random times, and the boot sequence changes each time it runs.... but that is just a guess. I don't know how it works.

Setting the location of my own application windows has always worked on previous versions of Plasma (Mag7 and Mag8), and Plasma is also messing with gkrellm as well, so I doubt it is something wrong in my applications. But you never know.

I will start looking into workarounds to see if I can get my desktop to work properly.

I might also ask on the KDE forum as well.

Stay tuned.
If only the best bird sang, the forest would be a very quiet place.
User avatar
banjo
 
Posts: 476
Joined: May 4th, '11, 03:50
Location: Reading, Massachusetts

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby doktor5000 » Mar 14th, '24, 01:30

Might probably be helpful if you would mention your Xserver setup and what you configured in plasma for the other screen, and maybe the xrandr output.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18032
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby banjo » Mar 15th, '24, 20:37

I am back on my i5 computer with the Intel graphics. Since I see similar issues on both computers, I will trouble shoot it on this once because getting access to this computer is easier.

On this computer, the Xserver setup was the default when I installed Mag 9. I installed the OS as Mag 9 beta 1, and the system had only one monitor then. I added the second m monitor later.

Here is a screencap of the Plasma settings for the displays.

Screenshot_20240315_135922.png
Screenshot_20240315_135922.png (145.57 KiB) Viewed 4600 times


I'm not sure how to dump the Xserver setup. Here is /etc/X11/xorg.conf

Code: Select all
# File generated by XFdrake (rev 262502)

# **********************************************************************
# Refer to the xorg.conf man page for details about the format of
# this file.
# **********************************************************************

Section "ServerFlags"
    Option "DontZap" "False" # disable <Ctrl><Alt><BS> (server abort)
    #DontZoom # disable <Ctrl><Alt><KP_+>/<KP_-> (resolution switching)
    AllowMouseOpenFail # allows the server to start up even if the mouse does not work
EndSection

Section "Module"
    Load "v4l" # Video for Linux
EndSection

Section "Monitor"
    Identifier "monitor1"
    VendorName "Plug'n Play"
    ModelName "HP M22f FHD"
    HorizSync 30-86
    VertRefresh 48-75
   
    # Monitor supported modeline (75.0 Hz vsync, 83.9 kHz hsync, ratio 16/9, 102 dpi)
    ModeLine "1920x1080" 174.5 1920 1968 2000 2080 1080 1083 1088 1119 -hsync +vsync
   
    # Monitor supported modeline (50.0 Hz vsync, 37.5 kHz hsync, ratio 16/9, 68 dpi)
    ModeLine "1280x720" 74.25 1280 1720 1760 1980 720 725 730 750 +hsync +vsync
   
    # Monitor supported modeline (60.0 Hz vsync, 45.0 kHz hsync, ratio 16/9, 68 dpi)
    ModeLine "1280x720" 74.25 1280 1390 1430 1650 720 725 730 750 +hsync +vsync
   
    # Monitor supported modeline (50.0 Hz vsync, 56.2 kHz hsync, ratio 16/9, 102 dpi)
    ModeLine "1920x1080" 148.5 1920 2448 2492 2640 1080 1084 1089 1125 +hsync +vsync
   
    # Monitor supported CEA modeline (50.0 Hz vsync, 37.5 kHz hsync, ratio 16/9, 68 dpi)
    ModeLine "1280x720" 74.25 1280 1720 1760 1980 720 725 730 750 +hsync +vsync
   
    # Monitor supported CEA modeline (60.0 Hz vsync, 45.0 kHz hsync, ratio 16/9, 68 dpi)
    ModeLine "1280x720" 74.25 1280 1390 1430 1650 720 725 730 750 +hsync +vsync
   
    # Monitor supported CEA modeline (50.0 Hz vsync, 56.2 kHz hsync, ratio 16/9, 102 dpi)
    ModeLine "1920x1080" 148.5 1920 2448 2492 2640 1080 1084 1089 1125 +hsync +vsync
   
    # Monitor supported CEA modeline (60.0 Hz vsync, 67.5 kHz hsync, ratio 16/9, 102 dpi)
    ModeLine "1920x1080" 148.5 1920 2008 2052 2200 1080 1084 1089 1125 +hsync +vsync
   
    # Monitor preferred modeline (60.0 Hz vsync, 67.5 kHz hsync, ratio 16/9, 102 dpi)
    ModeLine "1920x1080" 148.5 1920 2008 2052 2200 1080 1084 1089 1125 +hsync +vsync
   
    # Apple iMac modes
    ModeLine "1024x768"   78.525 1024 1049 1145 1312   768  769  772  800 +hsync +vsync
    ModeLine "800x600"    62.357  800  821  901 1040   600  601  604  632 +hsync +vsync
    ModeLine "640x480"    49.886  640  661  725  832   480  481  484  514 +hsync +vsync
   
    # Apple monitors tend to do 832x624
    ModeLine "832x624"    57      832  876  940 1152   624  625  628  667 -hsync -vsync
   
    # Apple PowerBook G3
    ModeLine "800x600"    100     800  816  824  840   600  616  624  640 -hsync -vsync
   
    # Apple TI Powerbook
    ModeLine "1152x768"   78.741 1152 1173 1269 1440   768  769  772  800 +vsync +vsync
   
    # Pismo Firewire G3
    ModeLine "1024x768"   65     1024 1032 1176 1344   768  771  777  806 -hsync -vsync
   
    # iBook2
    ModeLine "1024x768"   65     1024 1048 1184 1344   768  771  777  806 -hsync -vsync
   
    # 17" Apple Studio Display
    ModeLine "1024x768"   112.62 1024 1076 1248 1420 768 768 780 808 +hsync +vsync
   
    # HiRes Apple Studio Display
    ModeLine "1280x1024"  135    1280 1288 1392 1664  1024 1027 1030 1064
   
    # Another variation
    ModeLine "1280x1024"  134.989 1280 1317 1429 1688  1024 1025 1028 1066 +hsync +vsync
   
    # TV fullscreen mode or DVD fullscreen output.
    # 768x576 @ 79 Hz, 50 kHz hsync
    ModeLine "768x576"     50.00  768  832  846 1000   576  590  595  630
   
    # 768x576 @ 100 Hz, 61.6 kHz hsync
    ModeLine "768x576"     63.07  768  800  960 1024   576  578  590  616
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1920x1080_120"  368.76  1920 2072 2288 2656  1080 1081 1084 1157  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1920x1080_100"  302.02  1920 2072 2280 2640  1080 1081 1084 1144  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1920x1080_85"  252.93  1920 2064 2272 2624  1080 1081 1084 1134  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1920x1080_75"  220.64  1920 2056 2264 2608  1080 1081 1084 1128  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1920x1080_60"  172.80  1920 2040 2248 2576  1080 1081 1084 1118  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1920x1080_50"  141.45  1920 2032 2232 2544  1080 1081 1084 1112  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1600x900_120"  255.69  1600 1728 1904 2208  900 901 904 965  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1600x900_100"  208.90  1600 1720 1896 2192  900 901 904 953  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1600x900_85"  174.79  1600 1712 1888 2176  900 901 904 945  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1600x900_75"  152.28  1600 1704 1880 2160  900 901 904 940  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1600x900_60"  119.00  1600 1696 1864 2128  900 901 904 932  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1600x900_50"  97.04  1600 1680 1848 2096  900 901 904 926  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1368x768_120"  185.67  1368 1472 1624 1880  768 769 772 823  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1368x768_100"  151.73  1368 1464 1616 1864  768 769 772 814  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1368x768_85"  125.67  1368 1456 1600 1832  768 769 772 807  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1368x768_75"  110.19  1368 1456 1600 1832  768 769 772 802  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1368x768_60"  85.86  1368 1440 1584 1800  768 769 772 795  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1368x768_50"  69.92  1368 1424 1568 1768  768 769 772 791  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1360x765_120"  182.63  1360 1456 1608 1856  765 766 769 820  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1360x765_100"  149.22  1360 1456 1600 1840  765 766 769 811  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1360x765_85"  124.65  1360 1448 1592 1824  765 766 769 804  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1360x765_75"  108.34  1360 1440 1584 1808  765 766 769 799  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1360x765_60"  84.40  1360 1424 1568 1776  765 766 769 792  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1360x765_50"  69.34  1360 1416 1560 1760  765 766 769 788  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1280x720_120"  161.56  1280 1376 1512 1744  720 721 724 772  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1280x720_100"  131.85  1280 1368 1504 1728  720 721 724 763  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1280x720_85"  110.01  1280 1360 1496 1712  720 721 724 756  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1280x720_75"  95.65  1280 1352 1488 1696  720 721 724 752  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1280x720_60"  74.48  1280 1336 1472 1664  720 721 724 746  -HSync +Vsync
   
    # modeline generated by gtf(1) [handled by XFdrake]
    ModeLine "1280x720_50"  60.47  1280 1328 1456 1632  720 721 724 741  -HSync +Vsync
EndSection

Section "Device"
    Identifier "device1"
    VendorName "Intel Corporation"
    BoardName "Intel Kernel Mode setting (Xorg modesetting)"
    Driver "modesetting"
    Option "DPMS"
EndSection

Section "Screen"
    Identifier "screen1"
    Device "device1"
    Monitor "monitor1"
    DefaultColorDepth 24
   
    Subsection "Display"
        Depth 8
        Modes "1920x1080" "1600x900" "1366x768" "1360x765" "1280x720"
    EndSubsection
   
    Subsection "Display"
        Depth 15
        Modes "1920x1080" "1600x900" "1366x768" "1360x765" "1280x720"
    EndSubsection
   
    Subsection "Display"
        Depth 16
        Modes "1920x1080" "1600x900" "1366x768" "1360x765" "1280x720"
    EndSubsection
   
    Subsection "Display"
        Depth 24
        Modes "1920x1080" "1600x900" "1366x768" "1360x765" "1280x720"
    EndSubsection
EndSection

Section "ServerLayout"
    Identifier "layout1"
    Screen "screen1"
EndSection



And here is the output from xrandr

Code: Select all
Screen 0: minimum 320 x 200, current 3840 x 1080, maximum 16384 x 16384
HDMI-1 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 476mm x 267mm
   1920x1080     60.00*+  74.97    74.97    50.00    60.00*   50.00    59.94 
   1920x1080_75  75.00 
   1920x1080_60  60.00 
   1920x1080_50  50.00 
   1680x1050     59.88 
   1600x900_75   75.00 
   1600x900_60   60.00 
   1600x900      60.00 
   1600x900_50   50.00 
   1280x1024     75.02    60.02 
   1440x900      59.90 
   1368x768_75   75.00 
   1368x768_60   60.00 
   1368x768_50   50.00 
   1360x765_75   75.00 
   1360x765_60   60.00 
   1360x765_50   50.00 
   1280x800      59.91 
   1280x720_75   75.00 
   1280x720_60   60.00 
   1280x720      50.00    60.00    50.00    60.00    50.00    59.94 
   1280x720_50   50.00 
   1152x768      68.35 
   1024x768      74.81    60.00    60.00 
   832x624       74.18 
   800x600       60.32 
   720x576       50.00 
   720x480       60.00    59.94 
   640x480       60.00    59.94 
   720x400       70.08 
HDMI-2 disconnected (normal left inverted right x axis y axis)
DP-1 disconnected (normal left inverted right x axis y axis)
HDMI-3 connected primary 1920x1080+1920+0 (normal left inverted right x axis y axis) 476mm x 268mm
   1920x1080     60.00*+  50.00    59.94 
   1680x1050     59.88 
   1280x1024     60.02 
   1440x900      59.90 
   1280x800      59.91 
   1152x864      75.00 
   1280x720      60.00    50.00    59.94 
   1024x768      70.07    60.00 
   800x600       60.32    56.25 
   720x576       50.00 
   720x480       60.00    59.94 
   640x480       66.67    60.00    59.95    59.94 
   720x400       70.08 



My current workaround is to set the session to restore a manually saved session. That works reasonably well, but the session manager overrides the place and size settings done by my applications. So if I move one of my apps and then log out without manually saving the session, the move that I did is ignored.

I tried setting Plasma to save the session at logout, and when logging in, it lost all of my apps. When I logged in again, it didn't even run the apps.

I need a way to tell the session manager to just leave the windows alone unless I move them with the mouse. Then, when I log in and start the apps, they can take care of themselves.
If only the best bird sang, the forest would be a very quiet place.
User avatar
banjo
 
Posts: 476
Joined: May 4th, '11, 03:50
Location: Reading, Massachusetts

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby doktor5000 » Mar 15th, '24, 20:49

banjo wrote:I need a way to tell the session manager to just leave the windows alone unless I move them with the mouse. Then, when I log in and start the apps, they can take care of themselves.

Well did you try excluding them? See e.g. https://bugs.kde.org/show_bug.cgi?id=242760 for an example, should be possible from systemsettings, or by editing the config.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18032
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby banjo » Mar 16th, '24, 17:23

I opened the System Settings dialog and excluded the apps in the Session manager. It had no effect. Plasma still centers the applications on the left hand screen when I log in.

I expected that excluding my applications might not fix my executables because they are not officially installed applications, just binary executable files that I run. I was surprised that it also failed to fix the problem for gkrellm. I set plasma up to just exclude gkrellm, and it still centered gkrellm on the left hand screen.

I also tried a trick where I added a 5 second delay after startup to one of my applications, and after 5 seconds it resets its position on the screen. That also failed to have any effect on the position of the app.

I checked my config file, and the correct locations are in the file.

So, after a 5 second delay, calling

Code: Select all
    this->resize(configPtr->config_width, configPtr->config_height);
    this->move(configPtr->config_xloc, configPtr->config_yloc);


did not move the application window to its proper location. It remained centered on the left hand screen.

I confirmed that the call is being made by running the app from a console and seeing the print statement that I put in when it calls the method that moves the app.

So it looks as though QT is now simply ignoring my positioning commands.

When I set up Plasma to restore a manually saved session, it restores the apps to where Plasma saw them and ignores my calls to set the position and size of the window.

I set up gkrellm to the location that I wanted it, and dumped out the location information

Code: Select all
[brian@linux6core ~/.gkrellm2/data]$ pwd
/home/brian/.gkrellm2/data
[brian@linux6core ~/.gkrellm2/data]$ ls
inet  net  startup_position
[brian@linux6core ~/.gkrellm2/data]$ cat startup_position
3662 132


I logged out and then logged back in. grellm is centered on the left hand screen.

I dumped out the startup location for gkrellm.

Code: Select all
[brian@linux6core ~]$ cd .gkrellm2/data
[brian@linux6core ~/.gkrellm2/data]$ ls
inet  net  startup_position
[brian@linux6core ~/.gkrellm2/data]$ cat startup_position
879 196
[brian@linux6core ~/.gkrellm2/data]$


The startup location for gkrellm has been changed to its location on the left hand screen. So, Plasma has officially moved grellm to its new position, and gkrellm has set itself up to restore its position there.

My applications save their location when I exit the programs, so they have not updated their locations after being moved. However, Plasma is ignoring the attempt for my applications to set their location and size.

Summarizing the problem: When told to open an empty session, Plasma centers all of the apps at startup on the center of the left hand screen. Plasma is also ignoring calls to QT to move windows to specific locations.

I might try changing my code to see if a setGeometry call will stick.

I have also not yet posted the question on KDE forum yet.

Stay tuned.
If only the best bird sang, the forest would be a very quiet place.
User avatar
banjo
 
Posts: 476
Joined: May 4th, '11, 03:50
Location: Reading, Massachusetts

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby banjo » Mar 16th, '24, 20:29

Quick update. After the login has settled down, my apps work normally. If I move my app on the screen, close it down, and then run it manually it works fine. The QT commands that set the location and size work, and it comes back up where I shut it down.

I have posted my question on the KDE Plasma forum.
If only the best bird sang, the forest would be a very quiet place.
User avatar
banjo
 
Posts: 476
Joined: May 4th, '11, 03:50
Location: Reading, Massachusetts

Re: Mageia 9 Plasma Graphical Glitches at Login

Postby banjo » Mar 17th, '24, 03:26

I have created a workaround that fixes this problem.

I created a bash script called RunApps.sh. It sleeps for a few seconds and then launches all of my desktop apps. Here is the entire script.

Code: Select all
#! /bin/bash
#
# This script delays the running of my applications for
# a few seconds to allow Plasma to settle down to avoid a Plasma
# bug that messes up the locations of the windows when logging in.
#
# Sleep for a few seconds to let Plasma settle down
sleep 5s
# Run all of my desktop apps
/home/brian/bin/dgeyes &
/home/brian/bin/mac &
/home/brian/bin/mobo &
/home/brian/bin/Wx &
/home/brian/bin/NixieClock3 &
gkrellm &


Then, I set up the Autostart feature to run my script.

Screenshot_20240316_211510.png
Screenshot_20240316_211510.png (101.53 KiB) Viewed 4493 times


When I log in, Plasma sets up the desktop, and then after a few seconds my apps run normally, just like they used to.

Launching my apps this way looks the most normal to me, the only difference being a small delay before my apps start up. I can live with that.

I am guessing that the problem is a sequencing problem wherein Plasma runs the apps before the desktop is ready to accept the move commands. But that is just a guess.

I will see what the KDE Plasma folks think.
If only the best bird sang, the forest would be a very quiet place.
User avatar
banjo
 
Posts: 476
Joined: May 4th, '11, 03:50
Location: Reading, Massachusetts

Re: [WORKAROUND]Mageia 9 Plasma Graphical Glitches at Login

Postby morgano » Mar 17th, '24, 22:50

I have been doing like that for years.
I do not rely on the desktop system for this ( by now old experience...)
And i have set the DE to not restore programs at login.

Like you I use the autostart feature, have in ~/.config/autostart a startscript.sh.desktop that points to my script.
Before, I had the script directly in the autostart folder, but that do not work good nowadays - IIRC some DE require there to only be .desktop links.
Over the years more programs themselves create and remove .desktop links there, so nowadays omitted from my script; currently nextcloud (client) and dropbox.

I used to have my script in ~/.config/autostart-scripts/ and automatically launched by the DE.
But upgrading to mga9, Plasma(?) automatically moved it to /home/morgan/.config/old-autostart-scripts/startscript.sh,
and made a "desktop entry" /home/morgan/.config/autostart/startscript.sh.desktop pointing to it!
I was a bit surprised when i wanted to edit my script and found it gone but knew it still executed :)


Like yours it starts with some seconds delay so Plasma first settles and executes the other .desktop files in autostart - then my script launch gkrellm, syncthing (which in turn is set to launch firefox (for its GUI)), thunderbird, ktorrent and some more, with sleep instructions in between, and ordered so the login dialogues comes up in a sane order. It is embarrassingly lame that systems still these days shift focus to new dialogues while user is in the middle of entering secret passwords in dialogs!
At home & work Mandriva since 2006, Mageia 2011. Thinkpad T40, T43, T60, T400, T510, Dell M4400, M6300, Acer Aspire 7. Workstation using LVM, LUKS, VirtualBox, BOINC
morgano
 
Posts: 1481
Joined: Jun 15th, '11, 17:51
Location: Kivik, Sweden

Re: [WORKAROUND]Mageia 9 Plasma Graphical Glitches at Login

Postby banjo » Mar 17th, '24, 23:21

Long ago I would rely on the automatic session restoration, but it started providing random results. Sometimes the apps would come up, and sometimes they wouldn't. Sometimes some of them would run and not others. I tried it briefly in Mag 9, and it didn't remember or run my apps at all. In fact, it had an old version of a session with apps that would not even run.

So I told it to give me an empty session and I would run them myself. That worked for a long time, but in Mag 9 it failed. I guess it takes longer now for Plasma to settle down.

I have been using KDE since my Mandrake days (2003?), and I really like it, so I didn't want to give up on it. But it has lately been a bit unstable.

Well, my script works for me now, so I will power on. It is a nice system that I am comfortable with.

Banjo
(_)=='=~
If only the best bird sang, the forest would be a very quiet place.
User avatar
banjo
 
Posts: 476
Joined: May 4th, '11, 03:50
Location: Reading, Massachusetts


Return to Basic support

Who is online

Users browsing this forum: No registered users and 1 guest