Skip to content

Commit 897a3ae

Browse files
Eliminate line continuation character in favor of parens; enhance alignment to emphasize we're accessing different records and doing similar things to them
1 parent 4d96e60 commit 897a3ae

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

lib/matplotlib/font_manager.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -323,10 +323,11 @@ def ttfFontProperty(font):
323323
# missing in some alternative Python implementations and we are only going
324324
# to look for ASCII substrings, where any ASCII-compatible encoding works
325325
# - or big-endian UTF-16, since important Microsoft fonts use that.
326-
sfnt2 = sfnt.get((1, 0, 0, 2), b'').decode('latin-1').lower() or \
327-
sfnt.get((3, 1, 0x0409, 2), b'').decode('utf_16_be').lower()
328-
sfnt4 = sfnt.get((1, 0, 0, 4), b'').decode('latin-1').lower() or \
329-
sfnt.get((3, 1, 0x0409, 4), b'').decode('utf_16_be').lower()
326+
sfnt2 = (sfnt.get((1, 0, 0, 2), b'').decode('latin-1').lower() or
327+
sfnt.get((3, 1, 0x0409, 2), b'').decode('utf_16_be').lower())
328+
sfnt4 = (sfnt.get((1, 0, 0, 4), b'').decode('latin-1').lower() or
329+
sfnt.get((3, 1, 0x0409, 4), b'').decode('utf_16_be').lower())
330+
330331
if sfnt4.find('oblique') >= 0:
331332
style = 'oblique'
332333
elif sfnt4.find('italic') >= 0:

0 commit comments

Comments
 (0)