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(viewport): properly truncate to size #228

Merged
merged 2 commits into from Sep 2, 2022

Commits on Aug 31, 2022

  1. Copy the full SHA
    306637a View commit details
    Browse the repository at this point in the history

Commits on Sep 1, 2022

  1. fix(viewport): properly truncate to size

    There are many "interesting" cases:
    
    - logical content is wider than display width (long lines).
      In this case, we truncate.
    - logical content is smaller than display height (fewer lines
      than visible).
      In this case, we pad with empty lines up to the specified height.
    - logical content is higher than display height (more lines than
      visible).
      In this case, we truncate.
    
    - style specifies a width wider than the display width.
      In this case, we ignore the style width and
      fit in the display width.
    - style specifies a height higher than the display height.
      Same as width, we ignore the style and fit in the display height.
    - style specifies a narrower width or smaller height than the display.
      In this case we obey the style.
    knz committed Sep 1, 2022
    Copy the full SHA
    688d50f View commit details
    Browse the repository at this point in the history