File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -328,7 +328,7 @@ def _apply_params(self, **kw):
328328 # -> points. grab the integer from the `Text` object
329329 # instead of saving the string representation
330330 v = getattr (self .label1 , 'get_' + k )()
331- setattr (self , '_ ' + k , v )
331+ setattr (self , '_label ' + k , v )
332332
333333
334334class XTick (Tick ):
Original file line number Diff line number Diff line change @@ -4213,6 +4213,17 @@ def test_pandas_indexing_hist():
42134213 fig , axes = plt .subplots ()
42144214 axes .hist (ser_2 )
42154215
4216+ @cleanup
4217+ def test_axis_set_tick_params_labelsize_labelcolor ():
4218+ # Tests fix for issue 4346
4219+ axis_1 = plt .subplot ()
4220+ axis_1 .yaxis .set_tick_params (labelsize = 30 , labelcolor = 'red' , direction = 'out' )
4221+
4222+ # Expected values after setting the ticks
4223+ assert axis_1 .yaxis .majorTicks [0 ]._size == 4.0
4224+ assert axis_1 .yaxis .majorTicks [0 ]._color == 'k'
4225+ assert axis_1 .yaxis .majorTicks [0 ]._labelsize == 30.0
4226+ assert axis_1 .yaxis .majorTicks [0 ]._labelcolor == 'red'
42164227
42174228if __name__ == '__main__' :
42184229 import nose
You can’t perform that action at this time.
0 commit comments