Page 2 of 2
Re: MDM Themes
Posted: Sat Jun 09, 2012 7:16 am
by paulmac
Trapper wrote:
A way to customize the GTK theme would prove to be useful. For me, it would even be more useful if I could override the highlight color with an entry in my theme's .xml
Found it!
http://projects.gnome.org/gdm/docs/2.16 ... greetertag
The GDM theme format is specified in XML format contained within a <greeter> tag. You may specify a GTK+ theme to be used with this theme by using the gtk-theme element in the greeter tag as in the following example.
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE greeter SYSTEM "greeter.dtd">
<greeter gtk-theme="Crux">
[...]
</greeter>
Re: MDM Themes
Posted: Sat Jun 09, 2012 8:55 am
by Trapper
paulmac wrote: It seems changing /usr/share/ubuntu-system-adjustments/defaults.conf will only work if there isn't an overide in /etc/mdm/mdm.conf.
I found this in the header comments:
defaults.conf wrote:
# This file should not be updated by hand. Since MDM 2.13.0.4, configuration
# choices in the MDM System Configuration file (/etc/mdm/mdm.conf) will
# override the default values specified in this file.
I added a theme line to /etc/mdm/mdm.conf and it persists after reboot.
you can restart mdm with sudo kill -HUP <mdm pid>
shotgun approach: sudo killall -HUP mdm
Both of these will also kill your X session and return you to mdm greeter.
edit:
You can put a 96x96 <username>.png into /usr/share/pixmaps/faces to have a custom face/icon in the greeter. Strangely <username>.jpg renamed to <username>.png will also work.
Thanks for this info paulmac. I will give it a spin.
Re: MDM Themes
Posted: Wed Nov 21, 2012 4:22 pm
by twodogs
I just use a script to convert any GDM theme to a MDM theme. Works great!
Copy the code and save as a shell script (ex: Convert GDM theme to MDM.sh). Put the script in /home/username/.gnome2/nautilus-scripts or nemo-scripts and make sure it is checked as 'executable.'
Download a GDM theme and run this script on the downloaded file by right clicking, navigating to >scripts>Convert GDM theme to MDM.
Presto!
Code: Select all
#!/usr/bin/env python
# Convert GDM theme to MDM by esteban1uy
import pygtk
import tarfile
import os
import sys
import tempfile
import gtk
pygtk.require('2.0')
if gtk.pygtk_version < (2,3,90):
raise SystemExit
def look_in_directory(directory):
for f in os.listdir(directory):
if os.path.isfile(os.path.join(directory, f)):
if f == "GdmGreeterTheme.desktop":
return os.path.join(directory, f)
if os.path.isdir(os.path.join(directory, f)):
if look_in_directory(os.path.join(directory, f)) != "":
return os.path.join(directory, f)
dialog = gtk.FileChooserDialog("Select theme file",
None,
gtk.FILE_CHOOSER_ACTION_OPEN,
(gtk.STOCK_CANCEL, gtk.RESPONSE_CANCEL,
gtk.STOCK_OPEN, gtk.RESPONSE_OK))
dialog.set_default_response(gtk.RESPONSE_OK)
filter = gtk.FileFilter()
filter.set_name("All files")
filter.add_pattern("*.tar.gz")
dialog.add_filter(filter)
response = dialog.run()
if response == gtk.RESPONSE_OK:
fullpathToTar = dialog.get_filename()
fullpath = os.path.dirname(fullpathToTar)
tar = tarfile.open(fullpathToTar, "r:gz")
destinationPath = tempfile.mkdtemp() + "/"
tar.extractall(destinationPath)
GdmFile = look_in_directory(destinationPath)
if GdmFile != "":
o = open(GdmFile+"/MdmGreeterTheme.desktop","a")
for line in open(GdmFile+"/GdmGreeterTheme.desktop"):
line = line.replace("GdmGreeterTheme","MdmGreeterTheme")
o.write(line)
o.close()
innerfolder = os.path.split(os.path.dirname(GdmFile+"/"))[1]
newtar = tarfile.open(fullpath + "/"+innerfolder+"_for_MDM.tar.gz", "w:gz")
newtar.add(GdmFile+"/",innerfolder+"/")
newtar.close()
elif response == gtk.RESPONSE_CANCEL:
exit()
dialog.destroy()
Re: MDM Themes
Posted: Wed Nov 21, 2012 5:18 pm
by GeneC
Twodogs...
Thanks for that it works brilliantly..
I used it on LMDE/KDE that I also had Thunar as a file manager.
I use Thunar custom actions. I am sure there is a way to use it in Dolphin, but being new to KDE have yet to figure that out. If anyone know how to use it in Dolphin, please tell.
========================
Edit:
Perhaps you should start a new thread with this script in HOW TO's:
http://forums.linuxmint.com/viewforum.php?f=42
Its good...
Re: MDM Themes
Posted: Wed Nov 21, 2012 11:41 pm
by twodogs
Re: MDM Themes
Posted: Thu Nov 22, 2012 3:49 am
by Oscar799
In Mint 14 MDM is compatible with GDM 2 themes
MDM
MDM was given a lot of attention and comes with exciting new features.
MDM now supports legacy GDM 2 themes. About 30 of them are installed by default in Linux Mint 14 and you can find 2,000 more in gnome-look.org.
From here
http://www.linuxmint.com/rel_nadia_whatsnew.php#mdm
Re: MDM Themes
Posted: Thu Nov 22, 2012 8:36 am
by twodogs
Oscar799 wrote:In Mint 14 MDM is compatible with GDM 2 themes
MDM
MDM was given a lot of attention and comes with exciting new features.
MDM now supports legacy GDM 2 themes. About 30 of them are installed by default in Linux Mint 14 and you can find 2,000 more in gnome-look.org.
From here
http://www.linuxmint.com/rel_nadia_whatsnew.php#mdm
Isn't 13 LTS, though? In six months time 14 will be old hat.