@@ -190,7 +190,7 @@ def _reset_text(
190
190
else :
191
191
label_position_yoffset = self ._ascent // 2
192
192
193
- self .tilegrid = displayio .TileGrid (
193
+ self ._tilegrid = displayio .TileGrid (
194
194
self ._bitmap ,
195
195
pixel_shader = self ._palette ,
196
196
width = 1 ,
@@ -203,36 +203,36 @@ def _reset_text(
203
203
)
204
204
205
205
if self ._label_direction == "UPR" :
206
- self .tilegrid .transpose_xy = True
207
- self .tilegrid .flip_x = True
206
+ self ._tilegrid .transpose_xy = True
207
+ self ._tilegrid .flip_x = True
208
208
if self ._label_direction == "DWR" :
209
- self .tilegrid .transpose_xy = True
210
- self .tilegrid .flip_y = True
209
+ self ._tilegrid .transpose_xy = True
210
+ self ._tilegrid .flip_y = True
211
211
if self ._label_direction == "UPD" :
212
- self .tilegrid .flip_x = True
213
- self .tilegrid .flip_y = True
212
+ self ._tilegrid .flip_x = True
213
+ self ._tilegrid .flip_y = True
214
214
215
215
# Clear out any items in the local_group Group, in case this is an update to
216
216
# the bitmap_label
217
217
for _ in self ._local_group :
218
218
self ._local_group .pop (0 )
219
219
self ._local_group .append (
220
- self .tilegrid
220
+ self ._tilegrid
221
221
) # add the bitmap's tilegrid to the group
222
222
223
223
# Update bounding_box values. Note: To be consistent with label.py,
224
224
# this is the bounding box for the text only, not including the background.
225
225
if self ._label_direction in ("UPR" , "DWR" ):
226
226
self ._bounding_box = (
227
- self .tilegrid .x ,
228
- self .tilegrid .y ,
227
+ self ._tilegrid .x ,
228
+ self ._tilegrid .y ,
229
229
tight_box_y ,
230
230
box_x ,
231
231
)
232
232
else :
233
233
self ._bounding_box = (
234
- self .tilegrid .x ,
235
- self .tilegrid .y ,
234
+ self ._tilegrid .x ,
235
+ self ._tilegrid .y ,
236
236
box_x ,
237
237
tight_box_y ,
238
238
)
0 commit comments