Ce billet n'est plus d'actualité, Pyzo contient maintenant un menu pour changer de thème.
Updated for Pyzo 4.3 (thanks to C.G.)

From Pyzo Website :

Pyzo is a cross-platform Python IDE focused on interactivity and introspection, which makes it very suitable for scientific computing. Its practical design is aimed at simplicity and efficiency. It consists of two main components, the editor and the shell, and uses a set of pluggable tools to help the programmer in various ways. Some example tools are source structure, project manager, interactive help, workspace …

I use Pyzo in every day work and I like it. From my point of view, everything is perfect except the syntax hilighter colors.

And Pyzo is not themable yet.

Nevertheless, Pyzo is written in Python and you just have to edit one file to change the editor colors. I recently tried Sublime Text (wonderful but not free) and found the colors theme very nice.

This post shows you how to use Pyzo with (not exactly) Sublime Text colors.

Open pyzo/codeeditor/base.py and look for the __init__ method :

def __init__(self,*args, **kwds):
        S["Editor.Line numbers"] = "back:%s, fore:%s" % (back2, back3)

        # Apply style

Just add a few lines :

def __init__(self,*args, **kwds):
        S["Editor.Line numbers"] = "back:%s, fore:%s" % (back2, back3)

        theme = "SubInsp"
        if theme == "SubInsp":
            back1, back2, back3 = "#272822", base02, base01
            fore1, fore2, fore3, fore4 = "#00ff00", "#0000ff", "#96df2b", base3
            lsyellow  = "#e6db72"
            lspink = "#f92672"
            lsgreen = "#96df2b"
            lsgrey = "#686c58"
            lslightpink = "#f9aeca" #"#f9d9e3"
            lsorange = "#f9da42"
            lslightblue = "#c5d9ff"
            lswhite = "#ffffff"
            lsviolet = "#ae81f0"
            lsblueviolet = "#71a2ff"
            lsnightblue = "#073642"
            lsnightbluelight = "#586e75"
            lsdarkgrey = "#272822"
            lsflashyblue = "#128ee5"
            lsverydarkgrey = "#1b1c18"

            S  = {}
            S["Editor.text"] = "back:%s, fore:%s" % (lsdarkgrey, lslightblue)
            S['Syntax.identifier'] = "fore:%s, bold:no, italic:no, underline:no" % lswhite
            S["Syntax.nonidentifier"] = "fore:%s, bold:no, italic:no, underline:no" % lslightpink
            S["Syntax.keyword"] = "fore:%s, bold:no, italic:no, underline:no" % lspink

            S["Syntax.functionname"] = "fore:%s, bold:yes, italic:no, underline:no" % lsgreen
            S["Syntax.classname"] = "fore:%s, bold:yes, italic:no, underline:no" % lsorange

            S["Syntax.string"] = "fore:%s, bold:no, italic:no, underline:no" %lsyellow
            S["Syntax.unterminatedstring"] = "fore:%s, bold:no, italic:no, underline:dotted" % lsflashyyellow
            S["Syntax.python.multilinestring"] = "fore:%s, bold:no, italic:no, underline:no" % lsyellow

            S["Syntax.number"] = "fore:%s, bold:no, italic:no, underline:no" % lsviolet
            S["Syntax.comment"] ="fore:%s, bold:no, italic:no, underline:no" % lsgrey
            S["Syntax.todocomment"] = "fore:%s, bold:yes, italic:no, underline:yes" % lsflashyblue
            S["Syntax.python.cellcomment"] = "fore:%s, bold:yes, italic:no, underline:full" % lsorange
            S["Syntax.openparen"]= "fore:%s, bold:no, italic:no, underline:no" % lsorange
            S["Syntax.closeparen"]= "fore:%s, bold:no, italic:no, underline:no" % lsorange

            S["Editor.Long line indicator"] = "linestyle:solid, fore:%s" % lsnightblue
            S["Editor.Highlight current line"] = "back:%s" % lsverydarkgrey
            S["Editor.Indentation guides"] = "linestyle:solid, fore:%s" % lsnightbluelight
            S["Editor.Line numbers"] = "back:%s, fore:%s" % (lsverydarkgrey, lsnightbluelight)
            S["Editor.BreakPoints"] = 'fore:%s,back:%s' %(lsflashyyellow, lsdarkgrey)
  • Note the line: S["Editor.BreakPoints"], necessary in IEP 3.3 to customize the new integrated debugger
  • Note the lines S["Syntax.openparen"]= "fore:%s, bold:no, italic:no, underline:no" % lsorange and S["Syntax.closeparen"]= "fore:%s, bold:no, italic:no, underline:no" % lsorange that avoid black parenthesis and blackets on a black background (Pyzo 4.x)

Restart Pyzo et voilà !

To disable the theme, just comment the line : theme = "SubInsp"

Take a look at the result before having a try :