Skip to content

Conversation

JeskTop
Copy link
Contributor

@JeskTop JeskTop commented Mar 4, 2020

<rt> and <ruby> spacing is too small. And the fontSize is large, spacing also change.

@JeskTop JeskTop changed the base branch from master to new-parser March 4, 2020 18:10
@JeskTop JeskTop changed the title Rt distance <rt> and <ruby> spacing Mar 4, 2020
@Sub6Resources
Copy link
Owner

I believe this is actually already fixed in the ruby-fixes branch. Correct me if I'm wrong though. That branch will be merged in soon.

@JeskTop
Copy link
Contributor Author

JeskTop commented Mar 5, 2020

@Sub6Resources In ruby-fixes branch, I find this code:
281e8db#diff-37b48ec6b119f1893bf93b57ff3f22e7R378

final rubySize = context.style.fontSize.size / 2;
final rubyYPos = rubySize + 4;

The problem is when rubyYPos = rubySize + <constant number> and ruby fontSize is large, and spacing will smaller.

You can test by this data.

 "p": Style(fontSize: FontSize(56))

WX20200305-144613

But if you set final rubyYPos = rubySize + rubySize / 2;, and spacing will according to font size and look like better.

You can test by this data.

 "p": Style(fontSize: FontSize(56))

2

 "p": Style(fontSize: FontSize(16))

3

@Sub6Resources
Copy link
Owner

I see, thank you. I'll look into merging this soon!

@Larpoux
Copy link

Larpoux commented Apr 2, 2020

This branch is very good for my use.
I hope that it will be merged to the Master branch soon.
Thank you to all of you.

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.

3 participants