Skip to content

API: shrink default figure size #6290

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 12, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/matplotlib/rcsetup.py
Original file line number Diff line number Diff line change
Expand Up @@ -1121,7 +1121,7 @@ def validate_hist_bins(s):
'figure.titleweight': ['normal', six.text_type],

# figure size in inches: width by height
'figure.figsize': [[8.0, 6.0], validate_nseq_float(2)],
'figure.figsize': [[6.4, 4.8], validate_nseq_float(2)],
'figure.dpi': [100, validate_float], # DPI
'figure.facecolor': ['w', validate_color], # facecolor; white
'figure.edgecolor': ['w', validate_color], # edgecolor; white
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
9 changes: 8 additions & 1 deletion lib/matplotlib/tests/test_backend_pgf.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
import matplotlib.pyplot as plt
from matplotlib.compat import subprocess
from matplotlib.testing.compare import compare_images, ImageComparisonFailure
from matplotlib.testing.decorators import _image_directories, switch_backend
from matplotlib.testing.decorators import (_image_directories, switch_backend,
cleanup)


baseline_dir, result_dir = _image_directories(lambda: 'dummy func')
Expand Down Expand Up @@ -79,6 +80,7 @@ def create_figure():


# test compiling a figure to pdf with xelatex
@cleanup(style='classic')
@switch_backend('pgf')
def test_xelatex():
if not check_for('xelatex'):
Expand All @@ -92,6 +94,7 @@ def test_xelatex():


# test compiling a figure to pdf with pdflatex
@cleanup(style='classic')
@switch_backend('pgf')
def test_pdflatex():
if not check_for('pdflatex'):
Expand All @@ -108,6 +111,7 @@ def test_pdflatex():


# test updating the rc parameters for each figure
@cleanup(style='classic')
@switch_backend('pgf')
def test_rcupdate():
if not check_for('xelatex') or not check_for('pdflatex'):
Expand Down Expand Up @@ -137,6 +141,7 @@ def test_rcupdate():


# test backend-side clipping, since large numbers are not supported by TeX
@cleanup(style='classic')
@switch_backend('pgf')
def test_pathclip():
if not check_for('xelatex'):
Expand All @@ -155,6 +160,7 @@ def test_pathclip():


# test mixed mode rendering
@cleanup(style='classic')
@switch_backend('pgf')
def test_mixedmode():
if not check_for('xelatex'):
Expand All @@ -171,6 +177,7 @@ def test_mixedmode():


# test bbox_inches clipping
@cleanup(style='classic')
@switch_backend('pgf')
def test_bbox_inches():
if not check_for('xelatex'):
Expand Down
2 changes: 1 addition & 1 deletion matplotlibrc.template
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ backend : $TEMPLATE_BACKEND
# See http://matplotlib.org/api/figure_api.html#matplotlib.figure.Figure
#figure.titlesize : medium # size of the figure title
#figure.titleweight : normal # weight of the figure title
#figure.figsize : 8, 6 # figure size in inches
#figure.figsize : 6.4, 4.8 # figure size in inches
#figure.dpi : 100 # figure dots per inch
#figure.facecolor : white # figure facecolor; 0.75 is scalar gray
#figure.edgecolor : white # figure edgecolor
Expand Down