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

get postscriptFontName from name table first #64

Merged
merged 2 commits into from
May 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@ jobs:
if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')"
strategy:
matrix:
python-version: ['3.7', '3.8', '3.9', '3.10']
python-version: ['3.9', '3.12']
platform: [ubuntu-latest, macos-latest, windows-latest]
exclude: # Only test on the oldest and latest supported stable Python on macOS and Windows.
- platform: macos-latest
python-version: 3.8
- platform: windows-latest
python-version: 3.8
- platform: macos-latest
python-version: 3.9
- platform: windows-latest
python-version: 3.9
- platform: macos-latest
python-version: 3.12
- platform: windows-latest
python-version: 3.12
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
Expand Down
3 changes: 3 additions & 0 deletions Lib/extractor/formats/opentype.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,9 @@ def _extractInfoName(source, info):
styleMapFamilyName=_priorityOrder(1),
# styleMapStyleName will be handled in head extraction
copyright=_priorityOrder(0),
# get postscriptFontName first from the name table
# this could be overwritten by the CFF fontName when extracting otf binaries
postscriptFontName=_priorityOrder(6),
trademark=_priorityOrder(7),
openTypeNameDesigner=_priorityOrder(9),
openTypeNameDesignerURL=_priorityOrder(12),
Expand Down
Loading