@@ -409,29 +409,26 @@ C/C++ extensions
409409Keyword argument processing
410410---------------------------
411411
412- Matplotlib makes extensive use of ``**kwargs `` for pass-through
413- customizations from one function to another. A typical example is in
414- :func: `matplotlib.pyplot.text `. The definition of the pylab text
415- function is a simple pass-through to
416- :meth: `matplotlib.axes.Axes.text `::
412+ Matplotlib makes extensive use of ``**kwargs `` for pass-through customizations
413+ from one function to another. A typical example is in `matplotlib.pyplot.text `.
414+ The definition of the pylab text function is a simple pass-through to
415+ `matplotlib.axes.Axes.text `::
417416
418417 # in pylab.py
419418 def text(*args, **kwargs):
420419 ret = gca().text(*args, **kwargs)
421420 draw_if_interactive()
422421 return ret
423422
424- :meth: `~matplotlib.axes.Axes.text ` in simplified form looks like this,
425- i.e., it just passes all ``args `` and ``kwargs `` on to
426- :meth: `matplotlib.text.Text.__init__ `::
423+ `~matplotlib.axes.Axes.text ` in simplified form looks like this, i.e., it just
424+ passes all ``args `` and ``kwargs `` on to ``matplotlib.text.Text.__init__ ``::
427425
428426 # in axes/_axes.py
429427 def text(self, x, y, s, fontdict=None, withdash=False, **kwargs):
430428 t = Text(x=x, y=y, text=s, **kwargs)
431429
432- and :meth: `~matplotlib.text.Text.__init__ ` (again with liberties for
433- illustration) just passes them on to the
434- :meth: `matplotlib.artist.Artist.update ` method::
430+ and ``matplotlib.text.Text.__init__ `` (again with liberties for illustration)
431+ just passes them on to the `matplotlib.artist.Artist.update ` method::
435432
436433 # in text.py
437434 def __init__(self, x=0, y=0, text='', **kwargs):
@@ -471,10 +468,10 @@ local arguments and the rest are passed on as
471468Using logging for debug messages
472469--------------------------------
473470
474- Matplotlib uses the standard python `logging ` library to write verbose
475- warnings, information, and
476- debug messages. Please use it! In all those places you write :func: ` print() `
477- statements to do your debugging, try using :func: ` log.debug() ` instead!
471+ Matplotlib uses the standard Python `logging ` library to write verbose
472+ warnings, information, and debug messages. Please use it! In all those places
473+ you write ` print ` calls to do your debugging, try using ` logging.debug `
474+ instead!
478475
479476
480477To include `logging ` in your module, at the top of the module, you need to
@@ -489,8 +486,8 @@ To include `logging` in your module, at the top of the module, you need to
489486
490487will log to a logger named ``matplotlib.yourmodulename ``.
491488
492- If an end-user of Matplotlib sets up `logging ` to display at levels
493- more verbose than `logging.WARNING ` in their code with the Matplotlib-provided
489+ If an end-user of Matplotlib sets up `logging ` to display at levels more
490+ verbose than `` logging.WARNING ` ` in their code with the Matplotlib-provided
494491helper::
495492
496493 plt.set_loglevel("debug")
@@ -527,7 +524,7 @@ There are five levels at which you can emit messages.
527524 steps of layouting or rendering) should only log at this level.
528525
529526By default, `logging ` displays all log messages at levels higher than
530- `logging.WARNING ` to `sys.stderr `.
527+ `` logging.WARNING ` ` to `sys.stderr `.
531528
532529The `logging tutorial `_ suggests that the difference between `logging.warning `
533530and `.cbook._warn_external ` (which uses `warnings.warn `) is that
@@ -537,11 +534,11 @@ persistent. Moreover, note that `.cbook._warn_external` will by default only
537534emit a given warning *once * for each line of user code, whereas
538535`logging.warning ` will display the message every time it is called.
539536
540- By default, `warnings.warn ` displays the line of code that has the `warn ` call.
541- This usually isn't more informative than the warning message itself. Therefore,
542- Matplotlib uses `.cbook._warn_external ` which uses `warnings.warn `, but goes
543- up the stack and displays the first line of code outside of Matplotlib.
544- For example, for the module::
537+ By default, `warnings.warn ` displays the line of code that has the `` warn ``
538+ call. This usually isn't more informative than the warning message itself.
539+ Therefore, Matplotlib uses `.cbook._warn_external ` which uses `warnings.warn `,
540+ but goes up the stack and displays the first line of code outside of
541+ Matplotlib. For example, for the module::
545542
546543 # in my_matplotlib_module.py
547544 import warnings
@@ -582,10 +579,9 @@ and running the same script will display::
582579Writing examples
583580----------------
584581
585- We have hundreds of examples in subdirectories of
586- :file: `matplotlib/examples `, and these are automatically generated
587- when the website is built to show up in the `examples
588- <../gallery/index.html> ` section of the website.
582+ We have hundreds of examples in subdirectories of :file: `matplotlib/examples `,
583+ and these are automatically generated when the website is built to show up in
584+ the :ref: `examples <gallery >` section of the website.
589585
590586Any sample data that the example uses should be kept small and
591587distributed with Matplotlib in the
0 commit comments