Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: only apply style to first line when rendering a Line #1247

Merged
merged 1 commit into from
Jul 28, 2024

Conversation

joshka
Copy link
Member

@joshka joshka commented Jul 27, 2024

A Line widget should only apply its style to the first line when
rendering and not the entire area. This is because the Line widget
should only render a single line of text. This commit fixes the issue by
clamping the area to a single line before rendering the text.

A `Line` widget should only apply its style to the first line when
rendering and not the entire area. This is because the `Line` widget
should only render a single line of text. This commit fixes the issue by
clamping the area to a single line before rendering the text.
Copy link

codecov bot commented Jul 27, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.6%. Comparing base (be3eb75) to head (52a6acd).
Report is 1 commits behind head on main.

Additional details and impacted files
@@          Coverage Diff          @@
##            main   #1247   +/-   ##
=====================================
  Coverage   94.6%   94.6%           
=====================================
  Files         65      65           
  Lines      15397   15407   +10     
=====================================
+ Hits       14566   14576   +10     
  Misses       831     831           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@joshka joshka merged commit b344f95 into main Jul 28, 2024
33 checks passed
@joshka joshka deleted the jm/fix-line-style branch July 28, 2024 00:23
joshka added a commit to erak/ratatui that referenced this pull request Oct 14, 2024
…1247)

A `Line` widget should only apply its style to the first line when
rendering and not the entire area. This is because the `Line` widget
should only render a single line of text. This commit fixes the issue by
clamping the area to a single line before rendering the text.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants