Linux application looks ugly when launched with sudo
-
Good day, colleagues!
I'm writing Linux application that needs root privelleges. The problem is when I launch it from normal user, it looks nice, but when I launch it with sudo it looks ugly (wrong style, fonts, etc).
Could you explain such behaviour?
-
Strange,
But mayby thats because root has different windowmanager settings.
Do you work with stylesheets? -
No, I've just create simple window in Qt Designer.
normal execution:
!http://img13.imageshack.us/img13/47/screenshotnormal.png!
sudo execution:
-
Thats what i tought,
your 'sudo' window is in motif style.
try "this":http://doc.qt.nokia.com/4.7/qplastiquestyle.html -
Maybe this "link":http://helpforlinux.blogspot.com/2009/01/make-sudo-applications-beautiful.html could help.
-
Try running qtconfig via sudo and changing the default widget style to plastique or oxygen or whatever takes your fancy.
-
Executing an application with "sudo", takes the default theme, so not style configuration is applied.
You can customize the root theme, but is a solution per machine, or maybe you can set the style of the application through code with Qt. -
Thank you all, sudo qtconfig did the trick!