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

Smallcaps has no effect in math mode #3138

Closed
1 task done
Olexorus opened this issue Jan 5, 2024 · 4 comments
Closed
1 task done

Smallcaps has no effect in math mode #3138

Olexorus opened this issue Jan 5, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@Olexorus
Copy link

Olexorus commented Jan 5, 2024

Description

Using the smallcaps function doesn't seem to work in math mode.

This is simple to reproduce by pasting this into an empty document:

#smallcaps[Normal text]

$#smallcaps[Math mode]$

Rendered

I'm using Typst 0.10.0 (70ca0d2), but this also happens on the web app.

I'm not sure if this is actually a bug or if you're supposed to use it differently in math mode, but I couldn't find anything in the documentation and when I asked on Discord noone had an answer, so I decided to post it here.

Reproduction URL

No response

Operating system

Web app, Linux

Typst version

  • I am using the latest version of Typst
@Olexorus Olexorus added the bug Something isn't working label Jan 5, 2024
@Enter-tainer
Copy link
Contributor

I guess it's a font issue.

image

$ #smallcaps[Test] $

#show math.equation: set text(
  font: ("Cambria Math"),
)

$ #smallcaps[Test] $

#show math.equation: set text(
  font: ("Fira Math"),
)

$ #smallcaps[Test] $

Some math font do have a sc variant

@Olexorus
Copy link
Author

Olexorus commented Jan 6, 2024

Is there a way to write a show rule that changes the font of smallcaps in math mode?

@Enter-tainer
Copy link
Contributor

maybe. you can try. you may also wrap smallcaps call with text(font: ...)[]

@Olexorus
Copy link
Author

Olexorus commented Jan 6, 2024

Thanks, I'll try that, and I'll close this issue since it doesn't seem to be a Typst bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants