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

Feature Request: use different font #7

Closed
Seasawher opened this issue Oct 29, 2023 · 12 comments
Closed

Feature Request: use different font #7

Seasawher opened this issue Oct 29, 2023 · 12 comments
Labels
enhancement New feature or request

Comments

@Seasawher
Copy link

I am always grateful to lean4web. Thanks.

It would look even more beautiful if fonts like JuliaMono could be used.
https://juliamono.netlify.app/

@Seasawher
Copy link
Author

All I had to do was change the browser font myself... Sorry, I didn't realise that.

@Seasawher Seasawher closed this as not planned Won't fix, can't repro, duplicate, stale Oct 29, 2023
@Seasawher Seasawher reopened this Apr 21, 2024
@Seasawher
Copy link
Author

Not everyone can conceive of installing a font and changing the settings in their browser. Wouldn't it be nice to choose a font that displays Unicode readably by default?

@joneugster
Copy link
Collaborator

It would be very reasonable to have a reasonable default font!

(not google though, I believe there is something about google fonts not bein GDPR conform or some nonesense like that)

@joneugster joneugster added the enhancement New feature or request label Apr 22, 2024
@Seasawher
Copy link
Author

My mother tongue is Japanese and I usually use the font Juisee for Lean.

See https://github.com/yuru7/juisee

It would be preferable if this could be made convenient for non-English speakers.

@joneugster
Copy link
Collaborator

joneugster commented Apr 23, 2024

I'd happily accept a PR that adds the correct fonts. working on it right now :)

Currently Mac-users also have a hard time because for most of them it does not load a mono-space font.

@joneugster
Copy link
Collaborator

On my end it looks very reasonable, doesn't it?

CSS says: font-family: "Droid Sans Mono", "monospace", monospace

Do you think it would be satisfactory to just ship "droid sans mono" together with the bundle?

Screenshot_20240423_092520

@Seasawher
Copy link
Author

Sorry, I don't know how to install Droid Sans Mono and can't try it myself.

Looks good, but do the Unicode symbols used in mathematics show up clearly?

@joneugster
Copy link
Collaborator

I realised that 'Droid Sans Mono' was just a random font on my computer. I did change the editor to use JuliaMono now.

Could you test at https://lean.math.hhu.de/ and see if it all looks good @Seasawher ?

@Seasawher
Copy link
Author

Seasawher commented Apr 24, 2024

Thanks for the quick response. I have tested it.

I found a problem:

When you try to define longlonglong....name, there was a problem with the cursor "lagging" behind the displayed character.

longname_font

In the image above, the cursor is shown as being in the middle of the line, but it actually exists at the end of the line.

see https://lean.math.hhu.de/#code=def%20longlonglonglonglonglonglonglonglongname%20%3A%3D%22hoge%22%0D%0A%0D%0A

@Seasawher
Copy link
Author

Seasawher commented Apr 24, 2024

I found another problem... I think this is a bug in Julia Mono rather than in Lean4 Web, but the kanji character for "点" (which means "dot") is displayed incorrectly.

image

see: cormullion/juliamono#206

@joneugster
Copy link
Collaborator

In the image above, the cursor is shown as being in the middle of the line, but it actually exists at the end of the line.

I cannot reproduce this on my end. Could it be some local (CSS) caching? If it persists, please open a new issue about it!

Regarding "点" , reading the linked issue, I think we just need to update the font in a few weeks.

@Seasawher
Copy link
Author

I think this issue itself has been resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants