##// END OF EJS Templates
Merge pull request #179 from Carreau/global-configurable...
Matthias Bussonnier -
r10931:425cd964 merge
parent child Browse files
Show More
@@ -31,6 +31,7 b' from IPython.utils.traitlets import (Bool)'
31 31 from nbconvert.exporters.export import export_by_name
32 32 from nbconvert.exporters.exporter import Exporter
33 33 from nbconvert.transformers import extractfigure
34 from nbconvert.utils.config import GlobalConfigurable
34 35
35 36 #-----------------------------------------------------------------------------
36 37 #Globals and constants
@@ -93,6 +94,7 b' class NbConvertApp(Application):'
93 94
94 95 #Register class here to have help with help all
95 96 self.classes.insert(0, Exporter)
97 self.classes.insert(0, GlobalConfigurable)
96 98
97 99
98 100 def start(self, argv=None):
@@ -17,7 +17,9 b' GlobalConfigurable.display_data_priority'
17 17 # Classes and functions
18 18 #-----------------------------------------------------------------------------
19 19
20 class DataTypeFilter(object):
20 from ..utils.config import GlobalConfigurable
21
22 class DataTypeFilter(GlobalConfigurable):
21 23 """ Returns the preferred display format """
22 24
23 25 display_data_priority = ['html', 'pdf', 'svg', 'latex', 'png', 'jpg', 'jpeg' , 'text']
@@ -28,4 +30,4 b' class DataTypeFilter(object):'
28 30 for fmt in self.display_data_priority:
29 31 if fmt in output:
30 32 return [fmt]
31 return [] No newline at end of file
33 return []
@@ -19,12 +19,13 b' It exposes a convenient class to inherit from to access configurability.'
19 19 from __future__ import print_function, absolute_import
20 20
21 21 from IPython.config.configurable import Configurable
22 from ..utils.config import GlobalConfigurable
22 23
23 24 #-----------------------------------------------------------------------------
24 25 # Classes and Functions
25 26 #-----------------------------------------------------------------------------
26 27
27 class ConfigurableTransformer(Configurable):
28 class ConfigurableTransformer(GlobalConfigurable):
28 29 """ A configurable transformer
29 30
30 31 Inherit from this class if you wish to have configurability for your
1 NO CONTENT: file renamed from nbconvert1/converters/config.py to nbconvert/utils/config.py
General Comments 0
You need to be logged in to leave comments. Login now