@@ -2266,7 +2266,7 @@ def set_constants(self, *constants, verbose=True):
22662266 self .flush ()
22672267 self ._on_constants_updated ()
22682268
2269- def create_constant (self , expression , * , verbose = True ):
2269+ def create_constant (self , expression , verbose = True , ** kwargs ):
22702270 """Append a constant to the stored list.
22712271
22722272 Parameters
@@ -2275,6 +2275,8 @@ def create_constant(self, expression, *, verbose=True):
22752275 Expression for the new constant.
22762276 verbose : boolean (optional)
22772277 Toggle talkback. Default is True
2278+ **kwargs
2279+ extra kwargs are passed to `Constant.__init__`
22782280
22792281 See Also
22802282 --------
@@ -2286,7 +2288,7 @@ def create_constant(self, expression, *, verbose=True):
22862288 if expression in self .constant_expressions :
22872289 wt_exceptions .ObjectExistsWarning .warn (expression )
22882290 return self .constants [self .constant_expressions .index (expression )]
2289- constant = Constant (self , expression )
2291+ constant = Constant (self , expression , ** kwargs )
22902292 if constant .units is None :
22912293 constant .convert (constant .variables [0 ].units )
22922294 self ._constants .append (constant )
0 commit comments