Showing the changes to lib/docs (2 of 3 files). Show all
Unified · Split
| @@ -18,13 +18,16 @@ module Docs · 17 unmodified lines | ||
| 18 | 18 | name.remove! 'mpl_toolkits.' |
| 19 | 19 | name.remove! ' API' |
| 20 | 20 | name.remove! %r{ \(.*\)} |
| 21 | − name.downcase! | |
| 22 | 21 | name |
| 23 | 22 | end |
| 24 | 23 | |
| 25 | 24 | def get_type |
| 26 | 25 | return TYPE_BY_SLUG[slug] if TYPE_BY_SLUG.key?(slug) |
| 27 | − name.split('.').first | |
| 26 | + type = name.split('.').first | |
| 27 | + type.downcase! | |
| 28 | + type.remove! ' module' | |
| 29 | + type.remove! ' class' | |
| 30 | + type | |
| 28 | 31 | end |
| 29 | 32 | |
| 30 | 33 | def additional_entries |
| @@ -32,19 +35,19 @@ module Docs · 1 unmodified line | ||
| 32 | 35 | |
| 33 | 36 | css('.class > dt[id]', '.exception > dt[id]', '.attribute > dt[id]').each do |node| |
| 34 | 37 | entry_name = node['id'].remove('matplotlib.').remove('mpl_toolkits.') |
| 35 | − entries << [entry_name, node['id']] | |
| 38 | + entries << [entry_name, node['id']] unless entry_name.casecmp(name) == 0 | |
| 36 | 39 | end |
| 37 | 40 | |
| 38 | 41 | css('.data > dt[id]').each do |node| |
| 39 | 42 | if node['id'].split('.').last.upcase! # skip constants |
| 40 | 43 | entry_name = node['id'].remove('matplotlib.').remove('mpl_toolkits.') |
| 41 | − entries << [entry_name, node['id']] | |
| 44 | + entries << [entry_name, node['id']] unless entry_name.casecmp(name) == 0 | |
| 42 | 45 | end |
| 43 | 46 | end |
| 44 | 47 | |
| 45 | 48 | css('.function > dt[id]', '.method > dt[id]', '.classmethod > dt[id]').each do |node| |
| 46 | 49 | entry_name = node['id'].remove('matplotlib.').remove('mpl_toolkits.') |
| 47 | − entries << [entry_name + '()', node['id']] | |
| 50 | + entries << [entry_name + '()', node['id']] unless entry_name.casecmp(name) == 0 | |
| 48 | 51 | end |
| 49 | 52 | |
| 50 | 53 | entries |
| @@ -16,10 +16,19 @@ module Docs · 15 unmodified lines | ||
| 16 | 16 | options[:skip] = %w(api_changes.html tutorial.html faq.html) |
| 17 | 17 | |
| 18 | 18 | options[:attribution] = <<-HTML |
| 19 | − © 2012–2016 Matplotlib Development Team. All rights reserved.<br> | |
| 19 | + © 2012–2017 Matplotlib Development Team. All rights reserved.<br> | |
| 20 | 20 | Licensed under the Matplotlib License Agreement. |
| 21 | 21 | HTML |
| 22 | 22 | |
| 23 | + version '2.0' do | |
| 24 | + self.release = '2.0.0' | |
| 25 | + self.base_urls = [ | |
| 26 | + "http://matplotlib.org/#{release}/api/", | |
| 27 | + "http://matplotlib.org/#{release}/mpl_toolkits/mplot3d/", | |
| 28 | + "http://matplotlib.org/#{release}/mpl_toolkits/axes_grid/api/" | |
| 29 | + ] | |
| 30 | + end | |
| 31 | + | |
| 23 | 32 | version '1.5' do |
| 24 | 33 | self.release = '1.5.3' |
| 25 | 34 | self.base_urls = [ |