mirror of
https://github.com/1j01/textual-paint.git
synced 2024-12-23 06:41:32 +03:00
Handle NoWidget
Why did this get dom_node = Container(classes={'inspector_highlight'}, pseudo_classes={'enabled'})?
This commit is contained in:
parent
892d12e8fb
commit
377a883d3b
@ -830,7 +830,10 @@ class Inspector(Container):
|
||||
|
||||
# show_box("region", dom_node.region, "blue")
|
||||
# show_box("scrollable_content_region", dom_node.scrollable_content_region, "red")
|
||||
map_geometry = self.screen.find_widget(dom_node)
|
||||
try:
|
||||
map_geometry = self.screen.find_widget(dom_node)
|
||||
except NoWidget:
|
||||
return
|
||||
regions = subtract_regions(map_geometry.region, map_geometry.clip)
|
||||
for index, region in enumerate(regions):
|
||||
show_box(f"clipped:{index}", region, "aquamarine")
|
||||
|
Loading…
Reference in New Issue
Block a user