8000 Doc v2 rel notes2 by tacaswell · Pull Request #7025 · matplotlib/matplotlib · GitHub
[go: up one dir, main page]

Skip to content

Doc v2 rel notes2 #7025

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 29 commits into from
Sep 19, 2016
Merged

Doc v2 rel notes2 #7025

merged 29 commits into from
Sep 19, 2016

Conversation

tacaswell
Copy link
Member

No description provided.

ax.bar(range(5), [1, 4, 9, 16, 25],
tick_label=tick_labels, align='center')
ax.xaxis.set_tick_params(labelsize=20)
ax.set_title('Участок под застройку с смайликам')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The meaning of the string is The construction site with an emoticon (and there is an error in the end of the string, should be со смайликом for singular or со смайликами for plural). I think it was something else in the original meaning. I can make a translation for you if you wish.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I put 'plot with emoji' into google translate and that is what came out. Getting Cyrillic to render is a common question. The goal here was to show it works by default now.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Google translate made me laugh once again 😃
It will be Диаграмма с эмодзи or Диаграмма со смайликами.

@tacaswell tacaswell added this to the 2.0 (style change major release) milestone Sep 5, 2016
(bottom, left) of the figure or axes. If the value is negative,
however, the origin is from the (right, top) of the figure or axes,
analogous to negative indexing of sequences.
(bottom, left) of the figure or axes.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think someone else noted earlier that this should be (left, bottom) to be consistent about the order.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'bottom, left' sounds more natural to me and matches the (row, col) numpy indexing.

The inconsistency was with the now deleted 'right, top'.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"bottom-left" is fine, but (bottom, left) looks like an argument specification, which should be an (x, y) pair.

@tacaswell
Copy link
Member Author

@efiring I am currently re-writing the stuff in text_props.rst

@@ -513,6 +555,8 @@ Legends

- The legend now has rounded corners by default.

- And a lighter border, I think? cf. #6770. (@QuLogic)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

-> "The legend defaults now include rounded corners, a lighter boundary, and partially transparent boundary and background."

adds more international and math characters, but otherwise has the
same appearance. Latin, Greek, Cyrillic, Armenian, Georgian, Hebrew,
and Arabic are `all supported
<http://dejavu-fonts.org/wiki/Main_Page>`__ (but right-to-left render
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

render -> rendering?

@NelleV
Copy link
Member
NelleV commented Sep 6, 2016

LGTM 👍

mpl.rcParams['hatch.linewidth'] = 1.0 / dpi # previous ps and Agg hatch linewidth


There is no API level control of the hacth linewidth.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hatch

demo(fig, {}, 'v2.0', 2)

The size of the padding in the x and y directions is controlled by the
``'axes.xmargin'`` and ``'axes.ymargin'`` rcParams respectively. If
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"If" -> "Whether"

@tacaswell
Copy link
Member Author
tacaswell commented Sep 12, 2016

@efiring I am brain-dead for the night. You should have the power to push to my branch now if you want to take over on this.

The things that are left to do:

  • fix the prose around the legend section
  • all of the tick width / size / pad tweaking + label pad tweaking + default subplots position tweaking
  • boxplots ( @phobson would you be willing to write up a before/after for boxplots?)
  • mplot3D ( @WeatherGod would you be willing to a before/after for mplot3D?)
  • mathext.rm
  • zorder things

I am happy if people keep pushing stuff to this branch / opening PRs against it or if we just merge this and iterate on it in a new PR.

@phobson
Copy link
Member
phobson commented Sep 12, 2016

here's what I'd say about boxplots

``boxplots``
------------

Previously, boxplots were composed of a mish-mash styles that were, for better for worse, inherited from Matlab. 
Most of the elements were blue, but the medians were red.
The fliers (outliers) were plus-symbols (`+`) and the whiskers were dashed lines, which created ambiguity if the caps were omitted. 

For the new defaults, everything is black except for the median and mean lines (if drawn), which are set to the first two elements of the current color cycle.
Also, the default flier markers are now hollow circles, which maintain the ability of the plus-symbols to overlap without obscuring data too much.

xytext=(0, -2), textcoords='offset pixels',
bbox={'facecolor': 'w'})

ax.set_title('Диаграмма со смайликами')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jni @stefanv You should use something like that to illustrate python3 unicode!

@NelleV
Copy link
Member
NelleV commented Sep 14, 2016

All my comments are very minor comments.
The patch looks great and I think it could be merged as is.

@NelleV NelleV changed the title Doc v2 rel notes2 [MRG+1] Doc v2 rel notes2 Sep 14, 2016
@@ -606,6 +606,7 @@ Legends
with mpl.rc_context(rc=rcparams):
x = range(N)
y = np.cumsum(np.random.randn(N) )
# unpack the single Line2D artist
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a tab here.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gah! I do not understand why emacs is putting tabs in!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's also surprising that the tests didn't pick this up.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe sphinx is still forgiving when parsing the rst?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Docs are built with Python 2, so any examples using tabs are probably not a big issue, plus this line is a comment anyway.

I don't think PEP8 is run on any inline examples.

Copy link
Member
@QuLogic QuLogic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few minor things.


import matplotlib as mpl
import matplotlib.pyplot as plt
import numpy
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as np; probably has no effect either way.

- `~matplotlib.artist.Artist.right_margin`
- `~matplotlib.artist.Artist.margins`

along with the complimentary ``get_*`` and ``set_*` D54 ` methods. When
Copy link
Member
@QuLogic QuLogic Sep 15, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

complementary.

========================== ======================================================================================================================
alpha `float`
backgroundcolor any matplotlib :ref:`color <colors>`
bbox `~matplotlib.patches.Rectangle` prop dict plus key ``'pad'`` which is a pad in points
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't quite know what this is trying to say, even in the original.

+---------------------+----------------------------------------------------+
| rcParam | usage |
+=====================+====================================================+
| ``'font.family'`` | List of either names of font or ``{'cursive', |
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"names of fonts" or "font names".

@efiring efiring merged commit e4a7c01 into matplotlib:v2.x Sep 19, 2016
@tacaswell tacaswell deleted the doc_v2_rel_notes2 branch September 20, 2016 01:46
@tacaswell
Copy link
Member Author

I will open a new PR soon addressing the remaining issues here.

@tacaswell
Copy link
Member Author

unless someone beats me to it ;)

@QuLogic QuLogic changed the title [MRG+1] Doc v2 rel notes2 Doc v2 rel notes2 Oct 16, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants
0