##// END OF EJS Templates
Deprecate more complicated way of defining colors....
Matthias Bussonnier -
Show More
@@ -10,6 +10,7 b''
10
10
11
11
12 import os
12 import os
13 import warnings
13
14
14 from IPython.utils.ipstruct import Struct
15 from IPython.utils.ipstruct import Struct
15
16
@@ -116,6 +117,16 b' class ColorScheme:'
116
117
117 def __init__(self,__scheme_name_,colordict=None,**colormap):
118 def __init__(self, __scheme_name_, colordict=None, **colormap):
118 self.name = __scheme_name_
119 self.name = __scheme_name_
120 if colormap:
121 warnings.warn(
122 "Passing each colors as a kwarg to ColorScheme is "
123 "considered for deprecation. Please pass a "
124 "dict as single dict as second parameter. If you are using this"
125 "Feature, please comment an subscribe to issue "
126 "https://github.com/ipython/ipython/issues/14304",
127 PendingDeprecationWarning,
128 stacklevel=2,
129 )
119 if colordict is None:
130 if colordict is None:
120 self.colors = Struct(**colormap)
131 self.colors = Struct(**colormap)
121 else:
132 else:
General Comments 0
You need to be logged in to leave comments. Login now