Skip to content

Scale multi-width unicodes - #817

Merged
alixander merged 4 commits into
d2lang:masterfrom
alixander:japanese
Feb 14, 2023
Merged

alixander merged 4 commits into
d2lang:masterfrom
alixander:japanese

Conversation

@alixander

@alixander alixander commented Feb 14, 2023 •

Copy link
Copy Markdown
Collaborator

screencapture-file-Users-alexanderwang-dev-alixander-d2-e2etests-out-e2e-report-html-2023-02-14-10_15_07

closes #813
closes #513
closes #749
probably missing like 5 other issues @bo-ku-ra 's opened ;)

@alixander alixander mentioned this pull request Feb 14, 2023
@bo-ku-ra

bo-ku-ra commented Feb 14, 2023 •

Copy link
Copy Markdown
Contributor

awesome!

Emoji ZWJ Sequence / U+200D ZERO WIDTH JOINER (ZWJ)
https://emojipedia.org/emoji-zwj-sequence/

especially
Family: Woman, Woman, Girl, Baby is wide.

@bo-ku-ra

Copy link
Copy Markdown
Contributor

i think the test would require a mixed text of double-byte charactors, single-byte charactors, and emojis, too.

@bo-ku-ra

bo-ku-ra commented Feb 14, 2023 •

Copy link
Copy Markdown
Contributor

{style.stroke-width: 15; style.double-border: true} <- there are renderings inside.

  • width 15:max + double-border(v 0.2.0)

https://play.d2lang.com/?l=&script=etzY9bip5XHjzMeN-x83rnrcOPVxY0s12GA9ZPusFAxNrRUg4ihRYaVQUlSaWqvABQgAAP__&

@alixander

Copy link
Copy Markdown
Collaborator Author

@bo-ku-ra updated with your tests. the method is not 100% accurate, it gives it a little too wide, but I think by an acceptable amount. What do you think

@alixander
alixander requested a review from nhooyr February 14, 2023 18:17
@alixander

alixander commented Feb 14, 2023 •

Copy link
Copy Markdown
Collaborator Author

@nhooyr tagged you to just take a glance in case anything raises a flag to you, no need to dig into

@alixander
alixander requested a review from gavin-ts February 14, 2023 18:43

@nhooyr nhooyr left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

✅

Comment thread ci/release/changelogs/next.md Resolved
@bo-ku-ra

Copy link
Copy Markdown
Contributor

@alixander
d2 v0.2.0 was designed with a shorter vertical length, but it looks good.
( maybe the whole diagram looks squashed? )

@alixander
alixander merged commit 53dce56 into d2lang:master Feb 14, 2023
@bo-ku-ra

Copy link
Copy Markdown
Contributor

fyi
https://en.wikipedia.org/wiki/Golden_ratio
https://en.wikipedia.org/wiki/Silver_ratio (<- japanese like it. mickey mouse, doraemon, google logo, etc.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

4 participants