diffpy / diffpy.pdfgui

graphical user interface for real space structure refinement to PDF
Other
18 stars 27 forks source link

Fix icon #19

Closed chiahaoliu closed 7 years ago

chiahaoliu commented 7 years ago

This is a PR to fix invalid icon path of pdfgui when it works with matplotlib 2.0.

It addresses half of fix discussed at issue #15 by overriding toolitems class variable of NavigationToolbar2WxAgg class so that we can avoid touching private method. Here is how the toolbar looks like now:

image

@pavoljuhas since I was trying to avoid non-public API, the position of saving icon and printing icon are exchanged. The functionalities remain the same, please let me know if you are okay with that.

attn: @tacaswell

codecov[bot] commented 7 years ago

Codecov Report

Merging #19 into master will decrease coverage by <.01%. The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #19      +/-   ##
==========================================
- Coverage   25.67%   25.67%   -0.01%     
==========================================
  Files          90       90              
  Lines       11921    11924       +3     
==========================================
  Hits         3061     3061              
- Misses       8860     8863       +3
Impacted Files Coverage Δ
src/diffpy/pdfgui/gui/extendedplotframe.py 0% <0%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 38d2bb0...d88dc76. Read the comment docs.

pavoljuhas commented 7 years ago

@chiahaoliu - please check my updates and let me know if it is good to go.

The main change is the old icon looked to small - it was 16x16 whereas current matplotlib uses 24x24. Here is the look with a new larger icon:

pdfgui-plot-mpl1

pdfgui-plot-mpl2

pavoljuhas commented 7 years ago

NOTE: remove unused stock_save_as_mpl2.png if this is good to go.

chiahaoliu commented 7 years ago

@pavoljuhas Thanks for the cleaning! It covers lots of aspects I didn't think of.

I pushed commit of removing unused icon file, please let me know further modification is needed.