Skip to content

Commit

Permalink
Remove debug
Browse files Browse the repository at this point in the history
  • Loading branch information
willmcgugan committed Jun 22, 2024
1 parent e5be6ff commit b118074
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 38 deletions.
36 changes: 0 additions & 36 deletions src/textual/command.py
Original file line number Diff line number Diff line change
Expand Up @@ -852,41 +852,6 @@ async def _search_for(
for search in searches:
search.cancel()

@staticmethod
def _sans_background(style: Style) -> Style:
"""Returns the given style minus the background color.
Args:
style: The style to remove the color from.
Returns:
The given style, minus its background.
"""
# Here we're pulling out all of the styles *minus* the background.
# This should probably turn into a utility method on Style
# eventually. The reason for this is we want the developer to be
# able to style the help text with a component class, but we want
# the background to always be the background at any given moment in
# the context of an OptionList. At the moment this act of copying
# sans bgcolor seems to be the only way to achieve this.
return Style(
blink2=style.blink2,
blink=style.blink,
bold=style.bold,
color=style.color,
conceal=style.conceal,
dim=style.dim,
encircle=style.encircle,
frame=style.frame,
italic=style.italic,
link=style.link,
overline=style.overline,
reverse=style.reverse,
strike=style.strike,
underline2=style.underline2,
underline=style.underline,
)

def _refresh_command_list(
self, command_list: CommandList, commands: list[Command], clear_current: bool
) -> None:
Expand Down Expand Up @@ -936,7 +901,6 @@ async def _gather_commands(self, search_value: str) -> None:
help_style = self.get_component_rich_style(
"command-palette--help-text", partial=True
)
self.log(help_style)

# The list to hold on to the commands we've gathered from the
# command providers.
Expand Down
2 changes: 0 additions & 2 deletions src/textual/widgets/_option_list.py
Original file line number Diff line number Diff line change
Expand Up @@ -562,12 +562,10 @@ def _remove_option(self, index: int) -> None:
for option_id, option_index in self._option_ids.items()
if option_index != index
}
# self._refresh_content_tracking(force=True)
self._refresh_lines()
# Force a re-validation of the highlight.
self.highlighted = self.highlighted
self._mouse_hovering_over = None
# self.refresh()

def remove_option(self, option_id: str) -> Self:
"""Remove the option with the given ID.
Expand Down

0 comments on commit b118074

Please sign in to comment.