On Thu, Dec 9, 2010 at 1:12 PM, Ben Gamari <bgam...@gmail.com> wrote:
> It seems that this may have been broken from the beginning. After > noticing that my changes were not taking effect, I added some debug > output and found that sphinx was changing the current working directory > (every example gets built with its own directory being the working > directory). I fail to see how doc/matplotlibrc could be currently used > given most examples are not built from doc/. Well, the matplotlibrc file is checked for when the python process is started, and the current directory when matplotlib is imported is used. Since we launch the build process in the doc directory next to make.py, doc is the current working directory when the plot directive extension is imported and this is used to build the examples. So it is not the directory that the example is in that is important, but the current directory when matplotlib is imported. On import the matplotlib.rc_params function is called to set matplotlib.rcParams. The rc_params function in turn calls matplotlib_fname, which does the following search * current working dir * environ var MATPLOTLIBRC * HOME/.matplotlib/matplotlibrc * MATPLOTLIBDATA/matplotlibrc Hope this helps! JDH ------------------------------------------------------------------------------ _______________________________________________ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-devel