##// 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 12 import os
13 import warnings
13 14
14 15 from IPython.utils.ipstruct import Struct
15 16
@@ -114,8 +115,18 b' class ColorScheme:'
114 115 name: str
115 116 colors: Struct
116 117
117 def __init__(self,__scheme_name_,colordict=None,**colormap):
118 def __init__(self, __scheme_name_, colordict=None, **colormap):
118 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 130 if colordict is None:
120 131 self.colors = Struct(**colormap)
121 132 else:
General Comments 0
You need to be logged in to leave comments. Login now