I am working on reorganizing our config system to work with Fernando's 
tconfig, and I could use some advice. Currently, a lot of the configuration 
code lives in __init__.py and rcsetup.py. I am thinking of a layout like 
this:

matplotlib/lib/matplotlib/
    __init__
    ... 
    config/
        api # mpl's entry point: all imports come from here
        checkdep # checks for dependencies like ghostscript, dvipng, etc.
        configobj # external project, required by tconfig
        cutils # configuration utilities, like get_home, is_writable_dir, etc.
        mplconfig.py # reads new config files using tconfig
        mpltraits # defines mpl traits like colors, markers, linestyles
        rcparams # configuration using old matplotlibrc files
        rcsetup # provides defaults, setup, for rcparams
        tconfig # Fernando's traited config, requires traits and configobj
        verbose # defines the Verbose class used throughout mpl

the __init__ file would import from config.api: rcParams, which would be the 
existing dict if the old config system is active, or a dict wrapping the new 
config object, along with rc, rcdefaults, etc.

Does this sound reasonable, or could anyone suggest a better organization? 
Should every trait used by mpl be defined in mpltraits, that is, should 
mpltraits provide an interface to enthought traits? Or should mpltraits only 
provide traits that are not predefined by enthought? Is config/ a bad place 
for verbose?

Thanks,
Darren

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to