Wednesday, December 26, 2012

How to disable screen blanking on gnome-shell

When watching movies on gnome shell with VLC, the screen blanks out time to time. First it was from the timeout defined in brightness setting panel. But when i disable the screen off setting some how it started to happen with a 10 min timeout again. So when i googled i found out about the below shell extension.
https://extensions.gnome.org/extension/241/yet-another-inhibit-suspend-extension-user-menu/

But this didn't solved the problem as well. But this extension will stop gnome shell from being idle, which will avoid locking your screen. So now it was time to dig more into this problem. After going through various forums i found out that the xserver has a power management mode and a screensaver which will actually turn off the display to save power. And for my surprise this had a default timeout of 10 mints :).

So i did a small modification to the above extension (which i will submit as a patch to the original developer later after some testing), which will execute the javascript statement on disabling screen locking :

Util.spawn(['xset', 's', 'off']);

And on enabling screen locking :

Util.spawn(['xset', 's', 'on']);

What the above "xset s" does is enabling and disabling the screensaver of xserver.

So at least now i have a solution for VLC when watching movies. Hope that this support will added into VLC core soon so that we don't need to have a extra extension installed.


Thursday, December 13, 2012

Gnome shell popup menu problem [Solved]

Well if you are a gnome shell user and using eclipse for development you may have come across this bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=343278. Well some thinks its related to java and some thinks its related to SWT. But my friends its a gnome shell bug or i would say a feature that's not yet implemented :).

My Story:
I was sick of unity because of the slowness and high memory usage which is believe its really unnecessary. Yes Yes i know the memory are cheap these days, but still i don't like to wast my memory unnecessarily.

So i went on searching for a DE that fits my needs, i tried gnome shell but gave up because of this problem.
Then KDE ................ Hmmmmm nop not my choice feels bit odd, may be due to the fact that i was a gnome user for very long time now.
Then i tried Cinnamon, well it was not the one i was looking for either. But for for my surprise it didn't had the right click problem. I knew that cinnamon was a fork of gnome shell and if cinnamon can fix this why not gnome :).

Well i did some search on the cinnamon issue list and came across the following issue https://github.com/linuxmint/Cinnamon/issues/482

Great now its time to find the change that they have done. So i went through the cinnamon commit history to find the changes and end up with the following commits.

https://github.com/linuxmint/Cinnamon/commit/f8c7922777b102dc574bb3695fc649b89879ebab

https://github.com/linuxmint/muffin/commit/9e45c4c8f1cc2f92f266a5f8e1c4e83d4ce70ef1

https://github.com/linuxmint/muffin/commit/0e575275078d4b8b518978448bba60f404b3746d

Now you need to clone mutter and gnome shell code from the gnome git repository. Then you need to create new branches based on the 3.6.1 tag for both the projects.

When appling changes you will need to map some files from cinnamon to gnome shell, muffin to mutter as follows since there are some file name differences.

Cinnamon     : src/cinnamon-global.c
Gnome Shell : src/shell-global.c

Muffin     : src/meta/compositor-muffin.h

Mutter    : src/meta/compositor-mutter.h


Now compile and install the changes. The problem will be solved :). I wonder why gnome shell developers are not considering taking this fix in from cinnamon :(.


Saturday, December 1, 2012

Make firefox blends into gnome 3 shell

Recently i decided to move the gnome shell due the unity being more memory hungry (still not greedy as windows) and slow. Gnome shell was fast for me and responsive that unity. So when i moved to Ubuntu Gnome Remix the default browser was Epiphany. I love the look and feel of it and the maximize mode which removes the titlebars to get more space. But still i miss firefox due to the add-ons I'm used to. So here comes the search for firefox add-on to make it look like Epiphany. i found the following add-ons which did the trick.

https://addons.mozilla.org/en-US/firefox/addon/adwaita/?src=userprofile
Above Gnome 3 add-on will make your firefox looks more like a gnome 3 application with Adwaita theme.






https://addons.mozilla.org/en-US/firefox/addon/htitle/?src=userprofile
Above will hide titlebars when you maximize firefox.






Thanks for generous people who contribute on making those two plugins.