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