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

pdf/ps: Track full character map in CharacterTracker#30566

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

Conversation

QuLogic
Copy link
Member

PR summary

By tracking both character codes and glyph indices, we can handle producing multiple font subsets if needed by a file format.

This was split out of#30512, but based on#30335.

PR checklist

By tracking both character codes and glyph indices, we can handleproducing multiple font subsets if needed by a file format.
glyphs=self._character_tracker.used.get(filename)
ifglyphs:
fonts[Fx]=self.embedTTF(filename,glyphs)
charmap=self._character_tracker.used.get((filename,0))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

do we need to loop and add all the partitions?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Ah, this looks like more prep work as I see we never set subset size.

@tacaswell
Copy link
Member

"power cycled" to drop the already merged commit from the diff.

ifnotmpl.rcParams['ps.useafm']:
forfont_path,glyphsinps_renderer._character_tracker.used.items():
ifnotglyphs:
for (font,subset_index),charmapin \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

but we do loop here?

Copy link
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

PS is a little different from PDF in that it just dumps all the fonts in theCharacterTracker instance, while PDF has its own tracking of fonts, so it needs a bit more in-depth change (that continues on#30512.)

This change here doesn't modify any logic, but just changes the loop to work over the new structure of the.used attribute.

@tacaswell
Copy link
Member

I am a bit confused by the sub-setting logic. I think I've lost track of "is implemented" vs "will be implemented".

@tacaswell
Copy link
Member

We understand both the macos 13 and mypy failures as unrelated.

@tacaswelltacaswell merged commit43d5d4e intomatplotlib:text-overhaulSep 17, 2025
55 of 62 checks passed
@github-project-automationgithub-project-automationbot moved this fromIn Progress toDone inFont and text overhaulSep 17, 2025
@QuLogicQuLogic deleted the full-charmap-tracking branchSeptember 17, 2025 01:37
@QuLogic
Copy link
MemberAuthor

We understand both the macos 13 and mypy failures as unrelated.

Yes, I'll mergemain after the macOS CI is fixed

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@tacaswelltacaswelltacaswell left review comments

@anntzeranntzeranntzer approved these changes

Assignees
No one assigned
Projects
Status: Done
Milestone
v3.11.0
Development

Successfully merging this pull request may close these issues.

3 participants
@QuLogic@tacaswell@anntzer

[8]ページ先頭

©2009-2025 Movatter.jp