Commit af25598d authored by ulrich_y's avatar ulrich_y
Browse files

small fixes for user-library

parent c5b4fdbf
......@@ -35,7 +35,7 @@ def alpha_composite(bg, fg, alpha):
bg = hex2rgb(matplotlib.colors.to_hex(bg))
fg = hex2rgb(matplotlib.colors.to_hex(fg))
return '#%02x%02x%02x' % (
255.*((1-alpha) * bg[0] + alpha * fg[0]),
255.*((1-alpha) * bg[1] + alpha * fg[1]),
255.*((1-alpha) * bg[2] + alpha * fg[2])
int(255.*((1-alpha) * bg[0] + alpha * fg[0])),
int(255.*((1-alpha) * bg[1] + alpha * fg[1])),
int(255.*((1-alpha) * bg[2] + alpha * fg[2]))
)
......@@ -16,7 +16,8 @@ rc('text.latex', preamble='\n'.join([
'\\usepackage{amsmath}',
'\\usepackage{upgreek}',
'\\newcommand{\\Einv}{E\\hspace*{-6pt}/}',
'\\newcommand{\\D}{\\mathrm{d}}'
'\\newcommand{\\D}{\\mathrm{d}}',
'\\providecommand{\mathdefault}[1][]{}'
]))
#Taken from http://greg-ashton.physics.monash.edu/setting-nice-axes-labels-in-matplotlib.html
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment