mirror of
https://github.com/1j01/textual-paint.git
synced 2024-12-23 14:51:50 +03:00
Clean up some things
This commit is contained in:
parent
bb9042a6c0
commit
3fe9fed6ad
@ -819,14 +819,6 @@ class NodeInfo(Container):
|
|||||||
# TODO: find the specific line number of the rule set
|
# TODO: find the specific line number of the rule set
|
||||||
break
|
break
|
||||||
return format_styles_block(rule_set.styles, rule_set.selectors, format_location_info((path, line_number) if path else None))
|
return format_styles_block(rule_set.styles, rule_set.selectors, format_location_info((path, line_number) if path else None))
|
||||||
# css = rule_set.css
|
|
||||||
# selectors, declarations_and_end_curly = css.split("{", 1)
|
|
||||||
# return Text.assemble(
|
|
||||||
# selectors,
|
|
||||||
# "{ ",
|
|
||||||
# format_location_info((path, line_number) if path else None),
|
|
||||||
# declarations_and_end_curly,
|
|
||||||
# )
|
|
||||||
|
|
||||||
styles_text = Text.assemble(
|
styles_text = Text.assemble(
|
||||||
inline_style_text,
|
inline_style_text,
|
||||||
@ -935,7 +927,9 @@ class NodeInfo(Container):
|
|||||||
class ResizeHandle(Widget):
|
class ResizeHandle(Widget):
|
||||||
"""A handle for resizing a panel.
|
"""A handle for resizing a panel.
|
||||||
|
|
||||||
This is a child of the panel, and is positioned on the edge of the panel.
|
This should be a child of the panel.
|
||||||
|
Therefore, one of the sides of the divide needs to be a container.
|
||||||
|
It will be positioned on the edge of the panel according to the `side` parameter.
|
||||||
The panel can use min-width, min-height, max-width, and max-height to limit the size.
|
The panel can use min-width, min-height, max-width, and max-height to limit the size.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
@ -1012,9 +1006,6 @@ class ResizeHandle(Widget):
|
|||||||
return container.height if self._horizontal_resize else 1
|
return container.height if self._horizontal_resize else 1
|
||||||
|
|
||||||
def render_line(self, y: int) -> Strip:
|
def render_line(self, y: int) -> Strip:
|
||||||
# char = "⣿" if self._horizontal_resize else "⠶"
|
|
||||||
# char = "┃" if self._horizontal_resize else "━"
|
|
||||||
# char = "│" if self._horizontal_resize else "─"
|
|
||||||
char = "║" if self._horizontal_resize else "═" * self.size.width
|
char = "║" if self._horizontal_resize else "═" * self.size.width
|
||||||
return Strip([Segment(char, self.rich_style)])
|
return Strip([Segment(char, self.rich_style)])
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user