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 the TeXGyreHeros font as one of the default and a hack to use it #123

Merged
merged 6 commits into from
Jul 24, 2024

Conversation

Kolaru
Copy link
Owner

@Kolaru Kolaru commented Jul 24, 2024

This PR add (a quite terrible) support TeXGyreHeros for font (Makie's default, a sans serif font).

The font family can be used as generate_tex_elements(latex_string, FontFamily("TeXGyreHeros")).

Alternatively, to avoid intermediates, the command \fontfamily{TeXGyreHeros} can be used in the latex string itself, e.g. L"\fontfamily{TeXGyreHeros}$p_z$ (a. u.).

Most layouting is quite bad overall, but should be good enough for indices and superscripts.

Example:

image

To support other font, a FontFamily needs to be provided, that is composed of 5 fonts (regular, bold, italic, bolditalic, and math).

@Kolaru Kolaru merged commit 6847fe7 into master Jul 24, 2024
2 checks passed
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.

1 participant