Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[Bug]: math_fontfamily="cm" prevents replacement of minus by unicode minus in\mathdefault #21687

Closed
@anntzer

Description

@anntzer

Bug summary

All's in the title (and the examples).

Code for reproduction

frompylabimport*figtext(.5,.6,r"$\mathdefault{a-b}$",math_fontfamily="dejavusans")figtext(.5,.5,r"$\mathdefault{a-b}$",math_fontfamily="cm")

Actual outcome

test
Both lines use the text default font of DejaVu Sans, but setting math_fontfamily to cm prevented replacement of minus by unicode minus.

Expected outcome

Unicode minus in both cases

Additional information

(I probably have a fix that'll come after tearing down most mathtext deprecations that expire in 3.6, namely getting rid of themath kwarg in the various font classes and instead make the minus->unicode_minus replacement earlier, during the parsing stage.)

Operating system

linux

Matplotlib Version

3.5

Matplotlib Backend

qt5agg

Python version

39

Jupyter version

ENOSUCHLIB

Installation

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp