New themes for MDM in Mint 13

Please post suggestions for improvement of Cinnamon here
https://github.com/linuxmint/Cinnamon

New themes for MDM in Mint 13

Postby Oyabunbaba on Sat May 26, 2012 9:32 am

Where i can find new theme for login menu MDM in new mint Maya? By default there are only 2.
Last edited by Oyabunbaba on Mon May 28, 2012 6:04 am, edited 1 time in total.
http://mintnext.blogspot.com/ My tips & tricks site for Mint users (^ _ ^)
User avatar
Oyabunbaba
Level 2
Level 2
 
Posts: 86
Joined: Wed Feb 08, 2012 3:00 pm

Linux Mint is funded by ads and donations.
 

Re: New themes for MDM in Mint 13 Cinnamon

Postby esteban1uy on Sat May 26, 2012 10:42 am

You can easily adapt any GDM theme from deviantart or gnome-look:
http://browse.deviantart.com/customization/skins/linuxutil/?qh=&section=&q=gdm
http://gnome-look.org/index.php?xcontentmode=150

Once you've downloaded a theme pack, decompress it, edit the file named GdmGreeterTheme.desktop and replace the line [GdmGreeterTheme] with [MdmGreeterTheme], then rename that file to MdmGreeterTheme.desktop and compress the whole folder to a tar.gz file. Then you can open MDM setup and install the adapted theme.

For example, this is my Maya Cinnamon login:
Image
Sorry, I only speak Spanish
User avatar
esteban1uy
Level 5
Level 5
 
Posts: 734
Joined: Sat Nov 12, 2011 6:20 am

Re: New themes for MDM in Mint 13 Cinnamon

Postby Oyabunbaba on Sat May 26, 2012 10:55 am

Thank you esteban1uy i try use GDM theme but I do as you say and still the "file not tar.gz or tar file" any suggestions?
http://mintnext.blogspot.com/ My tips & tricks site for Mint users (^ _ ^)
User avatar
Oyabunbaba
Level 2
Level 2
 
Posts: 86
Joined: Wed Feb 08, 2012 3:00 pm

Re: New themes for MDM in Mint 13 Cinnamon

Postby cwwgateway on Sat May 26, 2012 6:17 pm

Oyabunbaba wrote:Thank you esteban1uy i try use GDM theme but I do as you say and still the "file not tar.gz or tar file" any suggestions?

Does this happen when you try to add it to MDM? For some reason, the MdmGreeterTheme.desktop file added a second .desktop to the end (so it looked like "MdmGreeterTheme.desktop.desktop"). I had to rename it and remove the second .desktop before it would work.
Dell XPS 15 l502x - Debian Testing 64-bit NetInst Xfce, SolydX 64-bit Debian Testing, SolydK 64-bit SolydXK Testing
Old Gateway Pentium 4 Desktop - Arch Linux 64-bit Xfce and SolydX 32-bit Sid
cwwgateway
Level 5
Level 5
 
Posts: 837
Joined: Fri Nov 11, 2011 10:44 pm

Re: New themes for MDM in Mint 13 Cinnamon

Postby Oyabunbaba on Sun May 27, 2012 3:25 am

Yes this happen when am drag&drop the tar.gz to the window of theme selection in MDM, and the window with message "file not tar.gz or tar file" will pop up. first asking if i want install theme and then this window.
I also noticed it is ading another .desktop but i remove it.
http://mintnext.blogspot.com/ My tips & tricks site for Mint users (^ _ ^)
User avatar
Oyabunbaba
Level 2
Level 2
 
Posts: 86
Joined: Wed Feb 08, 2012 3:00 pm

Re: New themes for MDM in Mint 13 Cinnamon

Postby esteban1uy on Sun May 27, 2012 10:30 am

I made a little script for Nautilus to convert some GDM themes to MDM.
Copy the following code, open gedit and paste it, save it to /home/YOUR_PERSONAL_FOLDER/.gnome2/nautilus-scripts/ with the name Convert GDM theme to MDM.
Then open nautilus, navigate to that folder, right-click the script file, select "Properties" and under "Permissions" tick "Allow executing file as program".
Now you can download any GDM theme pack, right-click and select "Convert..." from the scripts sub-menu.

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()


Edit: If you're using MATE desktop, save the script to /home/YOUR_PERSONAL_FOLDER/.config/caja/scripts/ (thanks therobertsonz).
Last edited by esteban1uy on Sun May 27, 2012 11:42 pm, edited 2 times in total.
Sorry, I only speak Spanish
User avatar
esteban1uy
Level 5
Level 5
 
Posts: 734
Joined: Sat Nov 12, 2011 6:20 am

Re: New themes for MDM in Mint 13 Cinnamon

Postby diva4 on Sun May 27, 2012 11:17 am

Hi esteban1uy,

can you post the link to your GDM theme shown in your 1st post?
Or have you created it yourselve?

Best regards
Diva4
diva4
Level 1
Level 1
 
Posts: 3
Joined: Sun May 27, 2012 10:38 am

Re: New themes for MDM in Mint 13 Cinnamon

Postby esteban1uy on Sun May 27, 2012 11:26 am

diva4 wrote:Hi esteban1uy,

can you post the link to your GDM theme shown in your 1st post?
Or have you created it yourselve?

Best regards
Diva4

Hi Diva4!

Here it is: http://gnome-look.org/content/show.php/Doe+GDM?content=52791

You can convert it to MDM using the script I recently posted.

Cheers!
Sorry, I only speak Spanish
User avatar
esteban1uy
Level 5
Level 5
 
Posts: 734
Joined: Sat Nov 12, 2011 6:20 am

Re: New themes for MDM in Mint 13 Cinnamon

Postby diva4 on Sun May 27, 2012 3:14 pm

Thank you esteban1uy,

it's working fine.

Best regards Diva4
diva4
Level 1
Level 1
 
Posts: 3
Joined: Sun May 27, 2012 10:38 am

Re: New themes for MDM in Mint 13 Cinnamon

Postby cwwgateway on Sun May 27, 2012 9:35 pm

esteban1uy wrote:I made a little script for Nautilus to convert some GDM themes to MDM.

Thank's for the script :) .
Dell XPS 15 l502x - Debian Testing 64-bit NetInst Xfce, SolydX 64-bit Debian Testing, SolydK 64-bit SolydXK Testing
Old Gateway Pentium 4 Desktop - Arch Linux 64-bit Xfce and SolydX 32-bit Sid
cwwgateway
Level 5
Level 5
 
Posts: 837
Joined: Fri Nov 11, 2011 10:44 pm

Re: New themes for MDM in Mint 13 Cinnamon

Postby therobertsonz on Sun May 27, 2012 9:40 pm

Just a little help for any future newbs such as myself if you are using Mint 13 with Mate. esteban1uy's script worked great for me, but I had to figure out a few things. Instead of the suggested nautilus-scripts folder it needs to go into username/.config/caja/scripts . Nautilus is Caja in Mate and you have a different script location. If you get into your folder under home and don't see .config, then press CTRL+h to toggle between hidden and unhidden folders. These are hidden for a reason, so make sure you are careful mucking around in the hidden folders. I converted the Leaf GDM theme to MDM and it looks very nice. Good luck and thanks esteban1uy. Great script and definitely outside my skill level. Much appreciated.
therobertsonz
Level 1
Level 1
 
Posts: 5
Joined: Mon May 30, 2011 9:45 am

Re: New themes for MDM in Mint 13 Cinnamon

Postby esteban1uy on Sun May 27, 2012 10:09 pm

Thank you therobertsonz!
I completely forgot that for MATE edition the script must be saved to ~/.config/caja/scripts :oops:
Sorry, I only speak Spanish
User avatar
esteban1uy
Level 5
Level 5
 
Posts: 734
Joined: Sat Nov 12, 2011 6:20 am

Re: New themes for MDM in Mint 13 Cinnamon

Postby therobertsonz on Mon May 28, 2012 12:51 am

You got us Mate users 95 percent of the way there, and as long as you have that hypnotoad avatar, everything you do is unquestionably perfect.:D
therobertsonz
Level 1
Level 1
 
Posts: 5
Joined: Mon May 30, 2011 9:45 am

Re: New themes for MDM in Mint 13 Cinnamon

Postby CrashedHash on Wed May 30, 2012 11:40 am

esteban1uy wrote:I made a little script for Nautilus to convert some GDM themes to MDM.
Copy the following code, open gedit and paste it, save it to /home/YOUR_PERSONAL_FOLDER/.gnome2/nautilus-scripts/ with the name Convert GDM theme to MDM.
Then open nautilus, navigate to that folder, right-click the script file, select "Properties" and under "Permissions" tick "Allow executing file as program".
Now you can download any GDM theme pack, right-click and select "Convert..." from the scripts sub-menu.

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()


Edit: If you're using MATE desktop, save the script to /home/YOUR_PERSONAL_FOLDER/.config/caja/scripts/ (thanks therobertsonz).


Thanks alot :D Works like a charm!
Linux Mint 13 Maya MATE x64

Check out http://wall.alphacoders.com for some amazing wallpapers!
CrashedHash
Level 1
Level 1
 
Posts: 15
Joined: Sat May 12, 2012 6:00 pm

Re: New themes for MDM in Mint 13

Postby Inoki on Thu May 31, 2012 12:58 pm

Is there a way to make this work on XFCE? I'm using Linux Mint Debian.
TOSHIBA Satellite L650 C13 w/ Dual core Intel Core i3
GFX & Audio: Intel Integrated GFX Controller; Intel 5 Series/3400 Series Chipset High Definition Audio
Network: Realtek RTL8191SEvB Wireless LAN Controller, Atheros AR8152 v1.1 Fast Ethernet
Inoki
Level 4
Level 4
 
Posts: 201
Joined: Sat Jul 31, 2010 4:11 am
Location: Slovak Republic

Re: New themes for MDM in Mint 13

Postby cwwgateway on Thu May 31, 2012 6:36 pm

Inoki wrote:Is there a way to make this work on XFCE? I'm using Linux Mint Debian.

The idea would work, but the script would have to be adapted to thunar or you'd have to install nautilus.
Dell XPS 15 l502x - Debian Testing 64-bit NetInst Xfce, SolydX 64-bit Debian Testing, SolydK 64-bit SolydXK Testing
Old Gateway Pentium 4 Desktop - Arch Linux 64-bit Xfce and SolydX 32-bit Sid
cwwgateway
Level 5
Level 5
 
Posts: 837
Joined: Fri Nov 11, 2011 10:44 pm

Re: New themes for MDM in Mint 13

Postby esteban1uy on Thu May 31, 2012 6:48 pm

cwwgateway wrote:
Inoki wrote:Is there a way to make this work on XFCE? I'm using Linux Mint Debian.

The idea would work, but the script would have to be adapted to thunar or you'd have to install nautilus.


Well... not really.
The script is independent from Nautilus, it doesn't rely on Nautilus to pass some parameters. The use as a Nautilus script is just because it's a great placeholder, you don't have to manually create a menu entry or something like that to easily use it, just right click and go (try it, right click wherever you want and the script will equally run).
But if you don't have Nautilus you can still start the script from a terminal and it will work the same way.
For example, save the script with the name .GDM2MDM.py inside your personal folder, then open a terminal and execute this command:
Code: Select all
python .GDM2MDM.py

That's all.

Of course, you can add that command to Thunar's custom actions: http://forums.linuxmint.com/viewtopic.php?f=110&t=66076
Sorry, I only speak Spanish
User avatar
esteban1uy
Level 5
Level 5
 
Posts: 734
Joined: Sat Nov 12, 2011 6:20 am

Re: New themes for MDM in Mint 13

Postby cwwgateway on Thu May 31, 2012 8:28 pm

esteban1uy wrote:
cwwgateway wrote:
Inoki wrote:Is there a way to make this work on XFCE? I'm using Linux Mint Debian.

The idea would work, but the script would have to be adapted to thunar or you'd have to install nautilus.


Well... not really.
The script is independent from Nautilus, it doesn't rely on Nautilus to pass some parameters. The use as a Nautilus script is just because it's a great placeholder, you don't have to manually create a menu entry or something like that to easily use it, just right click and go (try it, right click wherever you want and the script will equally run).
But if you don't have Nautilus you can still start the script from a terminal and it will work the same way.
For example, save the script with the name .GDM2MDM.py inside your personal folder, then open a terminal and execute this command:
Code: Select all
python .GDM2MDM.py

That's all.

Of course, you can add that command to Thunar's custom actions: http://forums.linuxmint.com/viewtopic.php?f=110&t=66076

Sorry, thanks for explaining.
Dell XPS 15 l502x - Debian Testing 64-bit NetInst Xfce, SolydX 64-bit Debian Testing, SolydK 64-bit SolydXK Testing
Old Gateway Pentium 4 Desktop - Arch Linux 64-bit Xfce and SolydX 32-bit Sid
cwwgateway
Level 5
Level 5
 
Posts: 837
Joined: Fri Nov 11, 2011 10:44 pm

Re: New themes for MDM in Mint 13 Cinnamon

Postby oddball on Fri Jun 01, 2012 9:44 am

cwwgateway wrote:
Oyabunbaba wrote:Thank you esteban1uy i try use GDM theme but I do as you say and still the "file not tar.gz or tar file" any suggestions?

Does this happen when you try to add it to MDM? For some reason, the MdmGreeterTheme.desktop file added a second .desktop to the end (so it looked like "MdmGreeterTheme.desktop.desktop"). I had to rename it and remove the second .desktop before it would work.


I have the same problem. Pressing "add" in the login window preferences gives me that. I also tried to manually cp the file in usr/share/mdm/themes but nothing happens. At least I don't get the second .desktop in the end :mrgreen:
oddball
Level 1
Level 1
 
Posts: 4
Joined: Fri Jun 01, 2012 9:14 am

Re: New themes for MDM in Mint 13

Postby Oyabunbaba on Sat Jun 02, 2012 5:49 am

oddball, don't ask me why, just remove .desktop at all, right click /rename and remove it totally, now should work ;)
http://mintnext.blogspot.com/ My tips & tricks site for Mint users (^ _ ^)
User avatar
Oyabunbaba
Level 2
Level 2
 
Posts: 86
Joined: Wed Feb 08, 2012 3:00 pm

Linux Mint is funded by ads and donations.
 
Next

Return to Cinnamon

Who is online

Users browsing this forum: Google [Bot] and 9 guests