PDA

View Full Version : [gnome] Command for changing subpixel antialiasing from RGB to VRGB



tupfzom
May 2nd, 2008, 11:17 AM
Hi all,

I have a monitor that can be rotated. I can very quickly rotate the screen settings using the Grandr applet, but I also need to change the subpixel antialiasing from RGB to VRGB or back which is not handled by the applet. The only way I know to do that is clicking my way through the System menu. But this is Linux, and I'm confident there is some console command that does it as well so I can prepare a script that does both rotation (with "xrandr -0 left") and adjust antialiasing.

I have been torturing Google for hours, but I couldn't find any hint. Can someone help me with this?

Thomas W.

encompass
May 2nd, 2008, 11:38 AM
If I am not mistaken this is a gconf setting... if it is... then it is a file... find the file... save it somewhere... then make your change... now all we have to do is make a script to make the file exchange or try to embed it into your rotate. The later would be tough. But I think you could do it.
I can try to help you... but it will take a while.
I would also report this to launchpad.net/ubuntu and they can add that feature to the next version of ubuntu. Great feature to add.

tupfzom
May 2nd, 2008, 02:09 PM
Thanks for your reply, encopass! It gave me the hint for solving the problem!


If I am not mistaken this is a gconf setting... if it is... then it is a file...

Yes it is! It's here: ~/.gconf/desktop/gnome/font_rendering/%gconf.xml. The Gnome key is /desktop/gnome/font_rendering/rgba_order.


find the file... save it somewhere... then make your change... now all we have to do is make a script to make the file exchange or try to embed it into your rotate.

That's not necessary with the great tool I just found: gconftool-2! By typing


gconftool-2 -s /desktop/gnome/font_rendering/rgba_order -t string "vrgb"


everything is done!

Thomas W.

P.S.: How can I mark this thread as solved?

tupfzom
May 2nd, 2008, 05:24 PM
I now have two nice icons on my gnome panel (a "normal" screen and an upright screen) with two tiny scripts behind them. To turn the screen upright:



#!/bin/bash
xrandr -o left
gconftool-2 -s /desktop/gnome/font_rendering/rgba_order -t string "vrgb"
done


and to turn the screen to "normal" position:



#!/bin/bash
xrandr -o normal
gconftool-2 -s /desktop/gnome/font_rendering/rgba_order -t string "rgb"
done


If someone wants to use the icons, I attached them. They could be more fancyful (with some arrows showing they are for rotation), but they look good enough. (I slightly edited the icon I found at /usr/share/icons/hicolor/scalable/apps/gnome-display-properties.svg.)

encompass
May 2nd, 2008, 08:16 PM
Good job! and thanks for posting your scripts it will help others later.
And if you like... you can simply make at the beginning that your problem was solved see below, or something similar. Just edit your first post. :D