How To: Replace LXDE Panel With Gnome Panel

Write tutorials and howtos in here
There are more tutorials here http://community.linuxmint.com/tutorial/welcome
Forum rules
Do not start a support topic here please. Before you post please read this

How To: Replace LXDE Panel With Gnome Panel

Postby Dean on Fri Sep 18, 2009 5:37 pm

I have seen this question asked a few times without any real answer given, other then the fact that it can't be done. Some may ask, "why would you want to do this?" Simply put, the LXDE panel is ugly and it is not as functional as the gnome-panel. The other question that my come to mind is "how will this effect my performance" Ironically, it wont. When running “top” the cpu and memory usage of gnome panel matches that of lxpanel which for me is usually around 2%. So if your concerned about performance on an older system, you should have no problems. I will also show you how to edit your mintMenu to logout of the lxsession instead of the gnome-session as well as how to completely replace nautilus with pcmanfm.



Replacing lxpanel with gnome-panel:

If you are running LXDE from the main version of Ubuntu or Mint: (which comes with Gnome)

Code: Select all
sudo apt-get install lxde
If you have not already done so.

Once you installed LXDE, log out and change your session to LXDE. In order to replace the LXDE panel with the Gnome panel we will have to edit the autostart file in /etc/xdg/lxsession/LXDE/ . You can do this by pasting the following in the terminal.

Code: Select all
sudo leafpad /etc/xdg/lxsession/LXDE/autostart
You should now see the following:

@lxde-settings
@xscreensaver -no-splash
@lxpanel --profile LXDE
@pcmanfm -d

Simply replace "@lxpanel --profile LXDE" with "@gnome-panel". Save the file, logout, then log back in to your LXDE session and you should now see the Gnome panel in place of your LXDE panel. It should now look like this.

@lxde-settings
@xscreensaver -no-splash
@gnome-panel
@pcmanfm -d

If you are running a version of Ubuntu or Mint that has kde, xfce, flux, etc. or if your installing from a mini.iso you will have to install gnome panel separately after installing LXDE.


Code: Select all
sudo apt-get install gnome-panel
After you have installed gnome panel follow the same steps listed above.



Editing Gnome Main Menu

Note: This is simply a workaround that allows your to easily be able to logout of lxde without having to recompile gnome-menu and editing the source.

First you will have to download pessulus (don't worry you can remove it after we are done without effecting changes)

Code: Select all
Sudo apt-get install pessulus
Start up pessulus. You will see some tabs that should include General, Panel, Epiphany Web Browser, and Gnome Screensaver. Click on panel and check the box that says Disable logout. This program will also allow you to disable several other options such as applets, which you may want to do if you want to disable gnome specific ones.

Now you can remove the program if you would like

Code: Select all
sudo apt-get remove pessulus
Now we are going to make a custom logout button to go into the menu. Right click on the menu and select edit menu. You can put this logout anywhere you like but for easy access we will add it to the applications section. Simply click on applications, then the "new item" tab and add the following:

Name: Logout or shut down (which ever you prefer)
Command: lxsession-logout

Click ok and that's it.



Editing the Gnome Bar Menu


This is the same as the above steps accept you will need to add the custom logout to the system part of the menu. I would also suggest cleaning up your menu by going to

Code: Select all
/usr/share/applications/
and get rid of the About GNOME.desktop and help.desktop which will put your custom logout closer to the bottom where it should be.



Editing mintMenu:


Go to

Code: Select all
 /usr/lib/linuxmint/mintMenu/plugins/system_management.py
and edit 125 and 131, replace "gnome-session-save --logout-dialog" with "lxsession-logout" on both lines.

Button5 = easyButton( "system-log-out", self.iconsize, [_("Logout")], -1, -1 )
Button5.connect( "clicked", self.ButtonClicked, "gnome-session-save --logout-dialog" )
Button5.show()
self.systemBtnHolder.pack_start( Button5, False, False )
self.mintMenuWin.setTooltip( Button5, _("Log out or switch user") )

Button6 = easyButton( "system-shutdown", self.iconsize, [_("Quit")], -1, -1 )
Button6.connect( "clicked", self.ButtonClicked, "gnome-session-save --shutdown-dialog" )
Button6.show()


To


Button5 = easyButton( "system-log-out", self.iconsize, [_("Logout")], -1, -1 )
Button5.connect( "clicked", self.ButtonClicked, "lxsession-logout" )
Button5.show()
self.systemBtnHolder.pack_start( Button5, False, False )
self.mintMenuWin.setTooltip( Button5, _("Log out or switch user") )

Button6 = easyButton( "system-shutdown", self.iconsize, [_("Quit")], -1, -1 )
Button6.connect( "clicked", self.ButtonClicked, "lxsession-logout" )
Button6.show()



Replace nautilus with pcmanfm (mintMenu):

You can download the mintMenu and it's dependencies [url="http://packages.linuxmint.com/"]here[/url]

sudo leafpad /usr/lib/linuxmint/mintMenu/plugins/places.py

Edit lines 104-105

Button2 = easyButton( "user-home", self.iconsize, [_("Home Folder")], -1, -1 )
Button2.connect( "clicked", self.ButtonClicked, "nautilus --no-desktop" )


To

Button2 = easyButton( "user-home", self.iconsize, [_("Home Folder")], -1, -1 )
Button2.connect( "clicked", self.ButtonClicked, "pcmanfm" )


and edit lines 135-136

Button4 = easyButton( "gnome-fs-desktop", self.iconsize, [_("Desktop")], -1, -1 )
Button4.connect( "clicked", self.ButtonClicked, "nautilus " + desktopDir )

To


Button4 = easyButton( "gnome-fs-desktop", self.iconsize, [_("Desktop")], -1, -1 )
Button4.connect( "clicked", self.ButtonClicked, "pcmanfm " + desktopDir )

Note: To my knowledge, there is no "my computer" or "network" folders for pcmanfm, so if you would like to keep the functionability of the "computer" and "network" button then just keep nautilus for those settings which are in buttons 1 and 3. If this changes I will update this, but as of lxpanel 5.1 these features have not been implimented. There also no trash at this moment for pcmanfm so anything you do delete through the pcmanfm file manager will be permanently deleted and the trash so you can either delete lines 119-162, leave them alone, or wait till pcmanfm has the trash feature and edit these lines in the future. There are a few work arounds for adding a trash system in pcmanfm which I may add to the tutorial in the future. Let me know if I'm missing anything.


Replacing nautilus with pcmanfm (gnome-menu):

Step 1

Code: Select all
sudo leafpad /usr/share/applications/nautilus-computer.desktop
Edit the following lines

[Desktop Entry]
Encoding=UTF-8
Name=Computer
Comment=Browse all local and remote disks and folders accessible from this computer
TryExec=nautilus
Exec=nautilus --no-desktop computer:
Icon=computer
Terminal=false
StartupNotify=true
Type=Application
Categories=GNOME;GTK;Core;
OnlyShowIn=GNOME;
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=nautilus
X-GNOME-Bugzilla-Component=general
X-GNOME-Bugzilla-Version=2.26.2
X-Ubuntu-Gettext-Domain=nautilus

To

[Desktop Entry]
Encoding=UTF-8
Name=Computer
Comment=Browse all local and remote disks and folders accessible from this computer
TryExec=pcmanfm
Exec=pcmanfm /
Icon=computer
Terminal=false
StartupNotify=true
Type=Application
Categories=GNOME;GTK;Core;
OnlyShowIn=GNOME;
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=pcmafm
X-GNOME-Bugzilla-Component=general
X-GNOME-Bugzilla-Version=2.26.2
X-Ubuntu-Gettext-Domain=pcmanfm

Step 2

Code: Select all
sudo leafpad /usr/share/applications/nautilus-folder-handler.desktop
[Desktop Entry]
Encoding=UTF-8
Name=Open Folder
TryExec=nautilus
Exec=nautilus --no-desktop %U
NoDisplay=true
Terminal=false
Icon=folder-open
StartupNotify=true
Type=Application
MimeType=x-directory/gnome-default-handler;x-directory/normal;inode/directory;application/x-gnome-saved-search;
OnlyShowIn=GNOME;
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=nautilus
X-GNOME-Bugzilla-Component=general
X-GNOME-Bugzilla-Version=2.26.2
X-Ubuntu-Gettext-Domain=nautilus

To

[Desktop Entry]
Encoding=UTF-8
Name=Open Folder
TryExec=pcmanfm
Exec=pcmanfm %U
NoDisplay=true
Terminal=false
Icon=folder-open
StartupNotify=true
Type=Application
MimeType=x-directory/gnome-default-handler;x-directory/normal;inode/directory;application/x-gnome-saved-search;
OnlyShowIn=GNOME;
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=pcmanfm
X-GNOME-Bugzilla-Component=general
X-GNOME-Bugzilla-Version=2.26.2
X-Ubuntu-Gettext-Domain=pcmanfm
Attachments
Screenshot-1.png
Screenshot-1.png (488.57 KiB) Viewed 8152 times
Screenshot.png
Screenshot.png (552.96 KiB) Viewed 8152 times
Last edited by Dean on Sun Aug 15, 2010 1:19 am, edited 12 times in total.
Dean
Level 1
Level 1
 
Posts: 35
Joined: Thu May 28, 2009 4:01 pm
Location: Jacksonville NC

Linux Mint is funded by ads and donations.
 

Re: How To: Replace LXDE Panel With Gnome Panel

Postby Husse on Sun Sep 20, 2009 11:14 am

This is interesting - I think I'll tell McLovin (who is trying to make a Mint LXDE)
Image
Don't fix it if it ain't broken, don't break it if you can't fix it
Husse
Level 21
Level 21
 
Posts: 19717
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Re: How To: Replace LXDE Panel With Gnome Panel

Postby Losgann on Mon Sep 21, 2009 10:22 pm

Agreed, this is interesting. I'd like to experiment with it, but is there any way to get the gnome panel without pulling in the entirety of the gnome desktop environment?
User avatar
Losgann
Level 3
Level 3
 
Posts: 120
Joined: Mon Aug 25, 2008 9:34 pm
Location: Connecticut, USA

Re: How To: Replace LXDE Panel With Gnome Panel

Postby Dean on Tue Sep 22, 2009 1:05 pm

Yeah, you don't have to install all of gnome to use the panel, but you will have to install the gnome-panel dependencies. As far as the menu goes, you will have to edit it in order to make sure that it utilizes all of lxde features/settings. For example, you would have to reconfigure the log-out, file manager, and anything that points to a folder such as home. If you don't then it will use or try to use gnomes default log-out and filemananger. I little bit of work, but I think its worth it.
Dean
Level 1
Level 1
 
Posts: 35
Joined: Thu May 28, 2009 4:01 pm
Location: Jacksonville NC

Re: How To: Replace LXDE Panel With Gnome Panel

Postby Dean on Wed Sep 23, 2009 2:04 am

I have edited the tutorial to include replacing nautilus with pcamfm and loging out of lxsession with mintmenu
Dean
Level 1
Level 1
 
Posts: 35
Joined: Thu May 28, 2009 4:01 pm
Location: Jacksonville NC

Re: How To: Replace LXDE Panel With Gnome Panel

Postby Dean on Thu Oct 08, 2009 5:19 pm

I have now updated this tutorial to include replacing the gnome logout with the lxde logout. Though there are still a few things that could be tweaked (much of which has to be done through editing and recompiling the source) you should now have a fully functional gnome-panel.
Dean
Level 1
Level 1
 
Posts: 35
Joined: Thu May 28, 2009 4:01 pm
Location: Jacksonville NC

Re: How To: Replace LXDE Panel With Gnome Panel

Postby wlake on Sat Oct 24, 2009 5:55 am

I found this very interesting. I did it somewhat differently. I just used openbox as standalone with gnome-panel. So far I really like it. For the logout, I got oblogout from Crunchbang. It seems quite speedy
wlake
Level 2
Level 2
 
Posts: 61
Joined: Thu Jul 24, 2008 2:30 pm

Re: How To: Replace LXDE Panel With Gnome Panel

Postby PcPixel on Wed Sep 15, 2010 9:02 am

I followed this guide using LinuxMint 9 LXDE, and am amazed by the results. The desktop isn't perfect (no volume control in the panel, some screen savers do not work, etc.) but the performance gain is disturbing. I've got my netbook running this LXDE/Gnome hybrid and I love it. If there was a way to somehow merge the two together and make it flawless, I'd be ALL over it.
PcPixel
Level 1
Level 1
 
Posts: 33
Joined: Fri Feb 06, 2009 11:50 am
Location: Rochester, NY.

Re: How To: Replace LXDE Panel With Gnome Panel

Postby Dean on Sat Jan 08, 2011 11:56 am

I apologize for not actively updating this project and being more active on the forums. Had a lot of things come up in my life during the time of the original post and was unable to go any further with it. Now I'm running a full time computer repair shop out of my home town, so now I have even less time. I originally was going to be working on the LXDE version of Linux Mint when it was first coming out (then my life exploded) and we had discussed possibly incorporating this idea into the edition. In any case, if I ever get a chance again, I will update this thread with a more seamless set-up. Good luck and if you find a better way of approaching this project and or a way to make it better in general, please post your results.

Thanks,

Dean
Dean
Level 1
Level 1
 
Posts: 35
Joined: Thu May 28, 2009 4:01 pm
Location: Jacksonville NC

Re: How To: Replace LXDE Panel With Gnome Panel

Postby daktras on Sat Feb 05, 2011 2:52 pm

it would be nice if we could have lxde meta package edited to not have to inculde openbox for those who done want to use it great tutorial i am abou tto alter my session here but i want to get ride of open box. i wonder if lxappearance can be made to control metacity instead of openbox?
daktras
Level 1
Level 1
 
Posts: 1
Joined: Sat Feb 05, 2011 2:48 pm

Linux Mint is funded by ads and donations.
 

Return to Tutorials / Howtos

Who is online

Users browsing this forum: Google Adsense [Bot] and 8 guests