epsfixbackground
Fix background colors in a MATLAB EPS file.
Contents
Syntax
epsfixbackground(FIG,EPSFILE) epsfixbackground(FIG,EPSFILE,OUTFILE)
Description
EPSFIXBACKGROUND(FIG,EPSFILE) scans the MATLAB-generated EPS file specified by the string EPSFILE and fix the plot background (i.e., figure and axes) format issues, especially the background colors that MATLAB EPS driver does not fill correctly. This function addresses the following:
1. Separate grid and other dotted line (for EPSSETLINESTYLE) 2. Mark figure background fill (for EPSSETBGCOLOR) 3. Set figure background color to that of the figure 4. Set axes background color to according to axes 'Color' property - 'none' - Remove MP PP and MP stroke commands altogether - [r g b](grayscale) - set using gs command - [r g b](color) - add new RGB color as necessary
EPSFIXBACKGROUND(FIG,EPSFILE,OUTFILE) saves the modified EPS data to a file specified by the string OUTFILE.