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

Add a half-width style #39

Open
yb6b opened this issue Mar 3, 2025 · 5 comments
Open

Add a half-width style #39

yb6b opened this issue Mar 3, 2025 · 5 comments

Comments

@yb6b
Copy link

yb6b commented Mar 3, 2025

In CJK (Chinese, Japanese, Korean) language environments, characters are displayed as 1:1 aspect ratio. When mixing English and CJK fonts in VS Code, the English text must use a ​1:2 aspect ratio​ (width:height) to maintain proper cursor alignment.

There are little half-width and mordern programming fonts. Notable examples include Microsoft Cascadia Next, Iosevka, and Noto Sans Mono CJK. It would be great if Martian Mono could also adopt this style for better code readability in mixed-language environments.

@romashamin
Copy link
Member

@yb6b that would be helpful if you could provide a screenshot demonstrating the issue.

@romashamin romashamin changed the title Add a half-width style. Add a half-width style Mar 3, 2025
@romashamin
Copy link
Member

Martian Mono doesn’t include CJK characters in any case. I assume that’s where the issue lies.

@yb6b
Copy link
Author

yb6b commented Mar 3, 2025

Here is a small experiment for illustration.

I clicked the mouse pointer on the first line of VSCode, and then I only pressed the down arrow key on the keyboard twice.

Image

When the caret is moved to the English word "Hello" on the second line, there is an offset in the horizontal position of the caret.

But Source Han Sans HW (HW means half width) did not has the offset.

Image

I found that the width-to-height ratio of Martian Mono Cn is 6:10. Is there a way to make it 5:10?

@romashamin
Copy link
Member

@yb6b thank you! I think I get it—when using half-width Latin letters, each CJK character will still align with every two Latin letters.

This doesn’t seem like a straightforward task, so let me give it some thought.

@yb6b
Copy link
Author

yb6b commented Mar 3, 2025

Yes, you're right. I'm sorry for not making myself clear at first. I'd be very happy if it could be done. Thank you so much!

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

2 participants