From f540b003f4448fd4b1c399e1567bc5d632ab5b9d Mon Sep 17 00:00:00 2001 From: Will McGugan Date: Thu, 27 Apr 2023 15:05:42 +0100 Subject: [PATCH 1/3] fix superfluous italics --- CHANGELOG.md | 6 ++++++ rich/syntax.py | 4 +--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 21386b2a1..210b1565a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [13.3.5] - 2023-04-27 + +### Fixed + +- Fixed italic indent guides in SVG ouput + ## [13.3.4] - 2023-04-12 ### Fixed diff --git a/rich/syntax.py b/rich/syntax.py index cc0660c23..ac669b834 100644 --- a/rich/syntax.py +++ b/rich/syntax.py @@ -590,7 +590,6 @@ def _get_number_styles(self, console: Console) -> Tuple[Style, Style, Style]: def __rich_measure__( self, console: "Console", options: "ConsoleOptions" ) -> "Measurement": - _, right, _, left = Padding.unpack(self.padding) padding = left + right if self.code_width is not None: @@ -688,7 +687,7 @@ def _get_syntax( lines = ( Text("\n") .join(lines) - .with_indent_guides(self.tab_size, style=style) + .with_indent_guides(self.tab_size, style=style + Style(italic=False)) .split("\n", allow_blank=True) ) @@ -830,7 +829,6 @@ def _get_code_index_for_syntax_position( if __name__ == "__main__": # pragma: no cover - import argparse import sys From 51f70fa410be2606975df6f548bd9e9ac5fd1610 Mon Sep 17 00:00:00 2001 From: Will McGugan Date: Thu, 27 Apr 2023 15:09:50 +0100 Subject: [PATCH 2/3] changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 210b1565a..1792061d7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1942,6 +1942,7 @@ Major version bump for a breaking change to `Text.stylize signature`, which corr - First official release, API still to be stabilized +[13.3.5]: https://github.com/textualize/rich/compare/v13.3.4...v13.3.5 [13.3.4]: https://github.com/textualize/rich/compare/v13.3.3...v13.3.4 [13.3.3]: https://github.com/textualize/rich/compare/v13.3.2...v13.3.3 [13.3.2]: https://github.com/textualize/rich/compare/v13.3.1...v13.3.2 From 3c13948a97b34135c728ad5e2dc6cd08fec5af9e Mon Sep 17 00:00:00 2001 From: Will McGugan Date: Thu, 27 Apr 2023 15:15:45 +0100 Subject: [PATCH 3/3] version bump [skip ci] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1503380bf..84f9c177c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -2,7 +2,7 @@ name = "rich" homepage = "https://github.com/Textualize/rich" documentation = "https://rich.readthedocs.io/en/latest/" -version = "13.3.4" +version = "13.3.5" description = "Render rich text, tables, progress bars, syntax highlighting, markdown and more to the terminal" authors = ["Will McGugan "] license = "MIT"