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

Adjust GetBoundingRect() for Inclusive end #4449

Merged
merged 1 commit into from
Feb 3, 2020

Conversation

carlos-zamora
Copy link
Member

Summary of the Pull Request

GetBoundingRect() has inclusive endpoints. I previously assumed end was exclusive so I drew the bounding rect wrong.

This also means that we should allow start and end to be the same. Which means that FailFastIf would get hit...

@carlos-zamora carlos-zamora added Area-Accessibility Issues related to accessibility Product-Terminal The new Windows Terminal. Product-Conhost For issues in the Console codebase labels Feb 3, 2020
Copy link
Contributor

@DHowett-MSFT DHowett-MSFT left a comment

Choose a reason for hiding this comment

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

In what instance will start==end but the range not be degenerate? I don't like this one bit.

@ghost ghost added the Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something label Feb 3, 2020
@carlos-zamora
Copy link
Member Author

In what instance will start==end but the range not be degenerate? I don't like this one bit.

The prerequisite for this function is start and end are both inclusive. So, start==end really means end = start + 1 (end being exclusive after this conversion). Thus making the range non-degenerate.

Thus, we can simplify the FailFastIf to be start > end or end < start

@ghost ghost removed the Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something label Feb 3, 2020
Copy link
Contributor

@DHowett-MSFT DHowett-MSFT left a comment

Choose a reason for hiding this comment

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

Alright this makes sense after o*line discussion

@DHowett-MSFT
Copy link
Contributor

we need types for exclusive and inclusive points and stuff

@miniksa miniksa added the AutoMerge Marked for automatic merge by the bot when requirements are met label Feb 3, 2020
@ghost
Copy link

ghost commented Feb 3, 2020

Hello @miniksa!

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.

Do note that I've been instructed to only help merge pull requests of this repository that have been opened for at least 8 hours, a condition that will be fulfilled in about 6 hours 10 minutes. No worries though, I will be back when the time is right! 😉

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.

@carlos-zamora
Copy link
Member Author

@msftbot merge this in -1 minutes

@ghost
Copy link

ghost commented Feb 3, 2020

Hello @carlos-zamora!

Because you've given me some instructions on how to help merge this pull request, I'll be modifying my merge approach. Here's how I understand your requirements for merging this pull request:

  • I won't merge this pull request until after the UTC date Mon, 03 Feb 2020 21:25:32 GMT, which is in 1 minute

If this doesn't seem right to you, you can tell me to cancel these instructions and use the auto-merge policy that has been configured for this repository. Try telling me "forget everything I just told you".

@carlos-zamora carlos-zamora merged commit d375461 into master Feb 3, 2020
@carlos-zamora carlos-zamora deleted the dev/cazamor/acc/bugfix-utr-getboundingrect branch February 3, 2020 21:25
@ghost
Copy link

ghost commented Feb 13, 2020

🎉Windows Terminal Preview v0.9.433.0 has been released which incorporates this pull request.:tada:

Handy links:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Accessibility Issues related to accessibility AutoMerge Marked for automatic merge by the bot when requirements are met Product-Conhost For issues in the Console codebase Product-Terminal The new Windows Terminal.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants