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

Must measure output size with Rune.ColumnWidth #41

Closed
migueldeicaza opened this issue Feb 3, 2018 · 8 comments
Closed

Must measure output size with Rune.ColumnWidth #41

migueldeicaza opened this issue Feb 3, 2018 · 8 comments

Comments

@migueldeicaza
Copy link
Collaborator

migueldeicaza commented Feb 3, 2018

Many characters that take up two slots are not properly rendered as we render those two, but do not fully fill the requested region. Need to use Rune.ColumnWidth to compute the current position.

@migueldeicaza migueldeicaza changed the title Must measure output size with Rune.ColumnWidth Must measure output size with Rune.ColumnWidth Feb 3, 2018
@tig
Copy link
Collaborator

tig commented Jun 4, 2020

@migueldeicaza do you have a test case for this?

@tig
Copy link
Collaborator

tig commented Jun 10, 2020

@tig tig added this to the v1.0 milestone Sep 28, 2020
tig added a commit that referenced this issue Oct 20, 2020
Fixes #225 and maybe #41. Allowing Rune.ColumnWidth greater than one.
@tig
Copy link
Collaborator

tig commented Oct 26, 2020

FWIW, I believe at some point I modified the code (in ConsoleDriver? to explicitly ignore Runes with ColumnWidth > 1 and print the default char as a work around of this issue until it can be addressed correctly. In #949, it appears @BDisp discovered that I missed a case.

BDisp referenced this issue in BDisp/Terminal.Gui Oct 26, 2020
@BDisp
Copy link
Collaborator

BDisp commented Oct 26, 2020

@migueldeicaza I think maybe it's time to use System.Text.Rune.

@BDisp
Copy link
Collaborator

BDisp commented Oct 26, 2020

I submitted a PR at gui-cs/NStack#48 to be able to control what kind of rune is being passed to AddRune. I hope that @migueldeicaza takes into account to be able to come up with a solution.

BDisp referenced this issue in BDisp/Terminal.Gui Oct 27, 2020
tig added a commit that referenced this issue Oct 28, 2020
#41 and #949. Unit test to compare the difference between System.Rune and System.Text.Rune.
@migueldeicaza
Copy link
Collaborator Author

The patch from @BDisp is now merged and should be on the new NStack.Core

@BDisp
Copy link
Collaborator

BDisp commented Nov 23, 2020

@migueldeicaza there is another PR (gui-cs/NStack#52) that fixes the "Chess Symbols (U+1fa00-1fa0f)". Thanks.

@migueldeicaza
Copy link
Collaborator Author

Merged - I will release a new NStack in the morning.

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

No branches or pull requests

3 participants