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

Move reflowing the buffer to TextBuffer #4197

Merged
3 commits merged into from
Jan 14, 2020
Merged

Conversation

zadjii-msft
Copy link
Member

@zadjii-msft zadjii-msft commented Jan 13, 2020

Summary of the Pull Request

In pursuit of reflowing the terminal buffer on resize, move the reflow algorithm to the TextBuffer. This does not yet add support for reflowing in the Windows Terminal.

References

#4200 I suppose

PR Checklist

  • There's not really an issue for this yet, I'm just breaking this work up into as many PRs as possible to help the inevitable bisect.
  • I work here
  • Ideally, all the existing tests will pass
  • [n/a] Requires documentation to be updated

Detailed Description of the Pull Request / Additional comments

In SCREEN_INFORMATION::ResizeScreenBuffer, the screenbuffer needs to create a new buffer, and copy the contents of the old buffer into the new one. I'm moving that "copy contents from the old buffer to the new one" step to it's own helper, as a static function on TextBuffer. That way, when the time comes to implement this for the Terminal, the hard part of the code will already be there.

Validation Steps Performed

Ideally, all the tests will still pass.

@zadjii-msft zadjii-msft added Area-Output Related to output processing (inserting text into buffer, retrieving buffer text, etc.) Product-Conhost For issues in the Console codebase labels Jan 13, 2020
Copy link
Member

@carlos-zamora carlos-zamora left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Even though this doesn't close an issue. Is there one that should at least be referenced?

Copy link
Member

@miniksa miniksa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix the SA and we're good.

@zadjii-msft zadjii-msft added the AutoMerge Marked for automatic merge by the bot when requirements are met label Jan 14, 2020
@ghost
Copy link

ghost commented Jan 14, 2020

Hello @zadjii-msft!

Because this pull request has the AutoMerge label, I will be glad to assist with helping to merge this pull request once all check-in policies pass.

p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (@msftbot) and give me an instruction to get started! Learn more here.

@zadjii-msft
Copy link
Member Author

x86 looks stuck on the unittests, so
/azp run

@ghost ghost merged commit cc9d2ca into master Jan 14, 2020
@ghost ghost deleted the dev/migrie/f/ResizeWithReflow-001 branch January 14, 2020 21:34
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Output Related to output processing (inserting text into buffer, retrieving buffer text, etc.) AutoMerge Marked for automatic merge by the bot when requirements are met Product-Conhost For issues in the Console codebase
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants