@@ -1155,94 +1155,70 @@ def get_points(self):
11551155 self ._check (points )
11561156 return points
11571157
1158- def set_locked_x0 (self , x0 ):
1159- """
1160- Set the value to be used for the locked x0.
1161-
1162- Parameters
1163- ----------
1164- x0 : float or None
1165- The locked value for x0, or None to unlock.
1166- """
1167- self ._locked_points .mask [0 , 0 ] = x0 is None
1168- self ._locked_points .data [0 , 0 ] = x0
1169- self .invalidate ()
1170-
1171- def get_locked_x0 (self ):
1158+ @property
1159+ def locked_x0 (self ):
11721160 """
1173- Get the value used for the locked x0.
1161+ float or None: The value used for the locked x0.
11741162 """
11751163 if self ._locked_points .mask [0 , 0 ]:
11761164 return None
11771165 else :
11781166 return self ._locked_points [0 , 0 ]
11791167
1180- def set_locked_y0 (self , y0 ):
1181- """
1182- Set the value to be used for the locked y0.
1183-
1184- Parameters
1185- ----------
1186- y0 : float or None
1187- The locked value for y0, or None to unlock.
1188- """
1189- self ._locked_points .mask [0 , 1 ] = y0 is None
1190- self ._locked_points .data [0 , 1 ] = y0
1168+ @locked_x0 .setter
1169+ def locked_x0 (self , x0 ):
1170+ self ._locked_points .mask [0 , 0 ] = x0 is None
1171+ self ._locked_points .data [0 , 0 ] = x0
11911172 self .invalidate ()
11921173
1193- def get_locked_y0 (self ):
1174+ @property
1175+ def locked_y0 (self ):
11941176 """
1195- Get the value used for the locked y0.
1177+ float or None: The value used for the locked y0.
11961178 """
11971179 if self ._locked_points .mask [0 , 1 ]:
11981180 return None
11991181 else :
12001182 return self ._locked_points [0 , 1 ]
12011183
1202- def set_locked_x1 (self , x1 ):
1203- """
1204- Set the value to be used for the locked x1.
1205-
1206- Parameters
1207- ----------
1208- x1 : float or None
1209- The locked value for x1, or None to unlock.
1210- """
1211- self ._locked_points .mask [1 , 0 ] = x1 is None
1212- self ._locked_points .data [1 , 0 ] = x1
1184+ @locked_y0 .setter
1185+ def locked_y0 (self , y0 ):
1186+ self ._locked_points .mask [0 , 1 ] = y0 is None
1187+ self ._locked_points .data [0 , 1 ] = y0
12131188 self .invalidate ()
12141189
1215- def get_locked_x1 (self ):
1190+ @property
1191+ def locked_x1 (self ):
12161192 """
1217- Get the value used for the locked x1.
1193+ float or None: The value used for the locked x1.
12181194 """
12191195 if self ._locked_points .mask [1 , 0 ]:
12201196 return None
12211197 else :
12221198 return self ._locked_points [1 , 0 ]
12231199
1224- def set_locked_y1 (self , y1 ):
1225- """
1226- Set the value to be used for the locked y1.
1227-
1228- Parameters
1229- ----------
1230- y1 : float or None
1231- The locked value for y1, or None to unlock.
1232- """
1233- self ._locked_points .mask [1 , 1 ] = y1 is None
1234- self ._locked_points .data [1 , 1 ] = y1
1200+ @locked_x1 .setter
1201+ def locked_x1 (self , x1 ):
1202+ self ._locked_points .mask [1 , 0 ] = x1 is None
1203+ self ._locked_points .data [1 , 0 ] = x1
12351204 self .invalidate ()
12361205
1237- def get_locked_y1 (self ):
1206+ @property
1207+ def locked_y1 (self ):
12381208 """
1239- Get the value used for the locked y1.
1209+ float or None: The value used for the locked y1.
12401210 """
12411211 if self ._locked_points .mask [1 , 1 ]:
12421212 return None
12431213 else :
12441214 return self ._locked_points [1 , 1 ]
12451215
1216+ @locked_y1 .setter
1217+ def locked_y1 (self , y1 ):
1218+ self ._locked_points .mask [1 , 1 ] = y1 is None
1219+ self ._locked_points .data [1 , 1 ] = y1
1220+ self .invalidate ()
1221+
12461222
12471223class Transform (TransformNode ):
12481224 """
0 commit comments