luma.core.legacy

These methods were originally present in the old MAX7219 driver, and are preserved here only to aid migration away from that library. The functions are denoted ‘legacy’ to discourage use - you are encouraged to use the various drawing capabilities in the Pillow library instead.

luma.core.legacy.show_message(device, msg, y_offset=0, fill=None, font=None, scroll_delay=0.03)[source]

Scrolls a message right-to-left across the devices display.

Parameters
  • device – The device to scroll across.

  • msg (str) – The text message to display (must be ASCII only).

  • y_offset (int) – The row to use to display the text.

  • fill – The fill color to use (standard Pillow color name or RGB tuple).

  • font – The font (from luma.core.legacy.font) to use.

  • scroll_delay (float) – The number of seconds to delay between scrolling.

luma.core.legacy.text(draw, xy, txt, fill=None, font=None)[source]

Draw a legacy font starting at x, y using the prescribed fill and font.

Parameters
  • draw (PIL.ImageDraw) – A valid canvas to draw the text onto.

  • txt (str) – The text string to display (must be ASCII only).

  • xy (tuple) – An (x, y) tuple denoting the top-left corner to draw the text.

  • fill – The fill color to use (standard Pillow color name or RGB tuple).

  • font – The font (from luma.core.legacy.font) to use.

luma.core.legacy.textsize(txt, font=None)[source]

Calculates the bounding box of the text, as drawn in the specified font. This method is most useful for when the proportional wrapper is used.

Parameters

luma.core.legacy.font

Fixed-width font definitions. The following fonts are available:

Font name

Notes

Source

ATARI_FONT

Designed for a terminal emulator written for an Atari 800.

http://gnu.ethz.ch/linuks.mine.nu/atari/

CP437_FONT

See https://en.wikipedia.org/wiki/Code_page_437 for further details.

unascribed

LCD_FONT

Only contains characters 0x20-0x7F inclusive and Cyrillic chars 0x80-0xBF (except ‘Ёё’); all others will appear as blanks.

http://www.avrfreaks.net/forum/code-57-512-and-712-fonts?name=PNphpBB2&file=viewtopic&t=69880

SEG7_FONT

Only contains characters 0x41-0x5A & 0x30-0x39 inclusive; all others will appear as blanks.

https://www.dafont.com/digital-7.font

SINCLAIR_FONT

Based on the character set from the Sinclair ZX Spectrum. Only contains characters 0x20-0x7E inclusive; all others will appear as blanks.

http://www.henningkarlsen.com/electronics/r_fonts.php

SPECCY_FONT

Another font based on the character set from the ZXSpectrum.

https://www.kreativekorp.com/software/fonts/index.shtml

TINY_FONT

Only contains characters 0x20-0x7E inclusive; all others will appear as blanks.

https://www.dafont.com/tiny.font

UKR_FONT

Cyrillic Ukrainian font

unascribed

luma.core.legacy.font.ATARI_FONT = [[0, 0, 0, 0, 0], [8, 28, 62, 28, 0], [0, 84, 170, 84, 0], [0, 31, 36, 255, 0], [31, 5, 249, 40, 0], [2, 5, 245, 80, 0], [15, 8, 248, 80, 0], [0, 30, 30, 30, 0], [0, 36, 46, 36, 0], [15, 2, 244, 143, 0], [7, 8, 23, 240, 0], [0, 8, 8, 15, 0], [0, 0, 0, 0, 0], [0, 248, 8, 0, 0], [0, 15, 8, 0, 0], [8, 8, 255, 8, 0], [0, 2, 2, 2, 0], [0, 4, 4, 4, 0], [0, 8, 8, 8, 0], [0, 16, 16, 16, 0], [0, 32, 32, 32, 0], [0, 255, 8, 0, 0], [0, 8, 8, 255, 0], [16, 16, 31, 16, 0], [16, 16, 240, 16, 0], [0, 0, 255, 0, 0], [0, 72, 84, 98, 0], [0, 98, 84, 72, 0], [2, 62, 2, 62, 0], [20, 52, 28, 22, 0], [36, 126, 21, 49, 0], [0, 0, 8, 0, 0], [0, 0, 0, 0, 0], [0, 0, 94, 0, 0], [0, 6, 0, 6, 0], [0, 126, 36, 126, 0], [0, 36, 203, 52, 0], [0, 98, 24, 70, 0], [0, 58, 101, 90, 0], [0, 0, 6, 0, 0], [0, 60, 66, 0, 0], [0, 66, 60, 0, 0], [0, 42, 28, 42, 0], [0, 8, 62, 8, 0], [0, 128, 96, 0, 0], [0, 8, 8, 8, 0], [0, 0, 96, 0, 0], [0, 96, 24, 6, 0], [0, 60, 74, 60, 0], [0, 68, 126, 64, 0], [0, 100, 82, 76, 0], [0, 34, 74, 54, 0], [0, 24, 20, 126, 0], [0, 46, 74, 50, 0], [0, 60, 74, 50, 0], [0, 2, 114, 14, 0], [0, 52, 74, 52, 0], [0, 76, 82, 60, 0], [0, 0, 36, 0, 0], [0, 64, 36, 0, 0], [0, 16, 40, 68, 0], [0, 20, 20, 20, 0], [0, 68, 40, 16, 0], [0, 4, 82, 12, 0], [0, 60, 66, 76, 0], [0, 124, 18, 124, 0], [0, 126, 74, 52, 0], [0, 60, 66, 36, 0], [0, 126, 66, 60, 0], [0, 126, 74, 74, 0], [0, 126, 10, 10, 0], [0, 60, 66, 52, 0], [0, 126, 8, 126, 0], [0, 66, 126, 66, 0], [0, 32, 64, 62, 0], [0, 126, 8, 118, 0], [0, 126, 64, 64, 0], [0, 126, 4, 126, 0], [0, 124, 24, 62, 0], [0, 60, 66, 60, 0], [0, 126, 18, 12, 0], [0, 60, 98, 92, 0], [0, 126, 18, 108, 0], [0, 36, 74, 52, 0], [0, 2, 126, 2, 0], [0, 126, 64, 126, 0], [0, 62, 64, 62, 0], [0, 126, 32, 126, 0], [0, 118, 8, 118, 0], [0, 6, 120, 6, 0], [0, 98, 90, 70, 0], [0, 126, 66, 0, 0], [0, 6, 24, 96, 0], [0, 66, 126, 0, 0], [0, 4, 2, 4, 0], [128, 128, 128, 128, 0], [0, 2, 4, 0, 0], [0, 36, 84, 120, 0], [0, 126, 72, 48, 0], [0, 56, 68, 68, 0], [0, 48, 72, 126, 0], [0, 56, 84, 88, 0], [0, 8, 124, 10, 0], [0, 152, 164, 124, 0], [0, 126, 8, 112, 0], [0, 72, 122, 64, 0], [0, 128, 136, 122, 0], [0, 126, 16, 104, 0], [0, 0, 126, 0, 0], [0, 124, 8, 124, 0], [0, 124, 4, 120, 0], [0, 56, 68, 56, 0], [0, 252, 36, 24, 0], [0, 24, 36, 252, 0], [0, 120, 4, 4, 0], [0, 72, 84, 36, 0], [0, 8, 126, 8, 0], [0, 124, 64, 124, 0], [0, 60, 64, 60, 0], [0, 124, 32, 124, 0], [0, 108, 16, 108, 0], [0, 156, 160, 124, 0], [0, 100, 84, 76, 0], [0, 8, 54, 65, 0], [0, 0, 119, 0, 0], [0, 65, 54, 8, 0], [0, 4, 12, 8, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0], [0, 0, 122, 0, 0], [0, 56, 198, 68, 0], [80, 124, 74, 34, 0], [0, 28, 20, 28, 0], [0, 42, 124, 42, 0], [0, 0, 119, 0, 0], [0, 74, 85, 41, 0], [0, 1, 0, 1, 0], [62, 73, 85, 62, 0], [0, 21, 19, 22, 0], [16, 40, 16, 40, 0], [0, 4, 4, 12, 0], [0, 8, 8, 8, 0], [62, 89, 69, 62, 0], [0, 1, 1, 1, 0], [0, 2, 5, 2, 0], [0, 36, 46, 36, 0], [0, 18, 26, 20, 0], [0, 18, 22, 14, 0], [0, 4, 2, 0, 0], [0, 124, 32, 28, 32], [76, 114, 126, 66, 0], [0, 0, 16, 0, 0], [0, 0, 192, 0, 0], [0, 20, 30, 16, 0], [0, 18, 21, 18, 0], [40, 16, 56, 16, 0], [0, 11, 20, 58, 0], [0, 11, 60, 58, 0], [0, 15, 23, 58, 0], [0, 48, 74, 32, 0], [0, 125, 18, 124, 0], [0, 124, 18, 125, 0], [0, 122, 21, 122, 0], [0, 126, 19, 125, 0], [0, 125, 18, 125, 0], [0, 122, 21, 122, 0], [124, 18, 126, 74, 0], [0, 60, 194, 52, 0], [0, 125, 86, 84, 0], [0, 124, 86, 85, 0], [0, 126, 85, 86, 0], [0, 125, 84, 85, 0], [0, 69, 126, 68, 0], [0, 68, 126, 69, 0], [0, 70, 125, 70, 0], [0, 69, 124, 69, 0], [16, 126, 74, 60, 0], [0, 125, 27, 62, 0], [0, 57, 70, 56, 0], [0, 56, 70, 57, 0], [0, 58, 69, 58, 0], [0, 57, 71, 58, 0], [0, 57, 68, 57, 0], [0, 40, 16, 40, 0], [0, 188, 90, 61, 0], [0, 125, 66, 124, 0], [0, 124, 66, 125, 0], [0, 122, 65, 122, 0], [0, 125, 64, 125, 0], [0, 12, 114, 13, 0], [68, 124, 40, 16, 0], [64, 126, 74, 116, 0], [0, 37, 86, 120, 0], [0, 36, 86, 121, 0], [0, 38, 85, 122, 0], [0, 37, 87, 122, 0], [0, 37, 84, 121, 0], [0, 38, 85, 122, 0], [32, 84, 104, 88, 0], [0, 56, 196, 68, 0], [0, 56, 85, 90, 0], [0, 58, 85, 88, 0], [0, 58, 85, 90, 0], [0, 57, 84, 89, 0], [0, 73, 122, 64, 0], [0, 72, 122, 65, 0], [0, 74, 121, 66, 0], [0, 74, 120, 66, 0], [0, 58, 71, 61, 0], [0, 125, 7, 122, 0], [0, 57, 70, 56, 0], [0, 56, 70, 57, 0], [0, 58, 69, 58, 0], [0, 57, 71, 58, 0], [0, 57, 68, 57, 0], [0, 8, 42, 8, 0], [0, 184, 84, 58, 0], [0, 122, 68, 120, 0], [0, 120, 68, 122, 0], [0, 122, 65, 122, 0], [0, 122, 64, 122, 0], [0, 156, 162, 125, 0], [66, 126, 36, 24, 0], [0, 0, 0, 0, 0]]

Bit patterns for ATARI_FONT Designed for a terminal emulator written for an Atari 800. It has only a one pixel descent to maximize pixels available to the main body of each character. Source: http://gnu.ethz.ch/linuks.mine.nu/atari/, transposed by Tiago F. Pimentel (antropoiese).

luma.core.legacy.font.SPECCY_FONT = [[0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 94, 0, 0, 0, 0], [0, 0, 6, 0, 0, 6, 0, 0], [0, 36, 126, 36, 36, 126, 36, 0], [0, 0, 92, 84, 254, 84, 116, 0], [0, 70, 38, 16, 8, 100, 98, 0], [0, 32, 84, 74, 84, 32, 80, 0], [0, 0, 0, 4, 2, 0, 0, 0], [0, 0, 0, 0, 60, 66, 0, 0], [0, 0, 66, 60, 0, 0, 0, 0], [0, 0, 16, 84, 56, 84, 16, 0], [0, 0, 16, 16, 124, 16, 16, 0], [0, 0, 0, 128, 96, 0, 0, 0], [0, 0, 16, 16, 16, 16, 16, 0], [0, 0, 0, 96, 96, 0, 0, 0], [0, 0, 64, 32, 16, 8, 4, 0], [0, 60, 98, 82, 74, 70, 60, 0], [0, 0, 68, 66, 126, 64, 64, 0], [0, 100, 82, 82, 82, 82, 76, 0], [0, 36, 66, 66, 74, 74, 52, 0], [0, 48, 40, 36, 126, 32, 32, 0], [0, 46, 74, 74, 74, 74, 50, 0], [0, 60, 74, 74, 74, 74, 48, 0], [0, 2, 2, 98, 18, 10, 6, 0], [0, 52, 74, 74, 74, 74, 52, 0], [0, 12, 82, 82, 82, 82, 60, 0], [0, 0, 0, 72, 0, 0, 0, 0], [0, 0, 128, 100, 0, 0, 0, 0], [0, 0, 0, 16, 40, 68, 0, 0], [0, 0, 40, 40, 40, 40, 40, 0], [0, 0, 0, 68, 40, 16, 0, 0], [0, 4, 2, 2, 82, 10, 4, 0], [0, 60, 66, 90, 86, 90, 28, 0], [0, 124, 18, 18, 18, 18, 124, 0], [0, 126, 74, 74, 74, 74, 52, 0], [0, 60, 66, 66, 66, 66, 36, 0], [0, 126, 66, 66, 66, 36, 24, 0], [0, 126, 74, 74, 74, 74, 66, 0], [0, 126, 10, 10, 10, 10, 2, 0], [0, 60, 66, 66, 82, 82, 52, 0], [0, 126, 8, 8, 8, 8, 126, 0], [0, 0, 66, 66, 126, 66, 66, 0], [0, 48, 64, 64, 64, 64, 62, 0], [0, 126, 8, 8, 20, 34, 64, 0], [0, 126, 64, 64, 64, 64, 64, 0], [0, 126, 4, 8, 8, 4, 126, 0], [0, 126, 4, 8, 16, 32, 126, 0], [0, 60, 66, 66, 66, 66, 60, 0], [0, 126, 18, 18, 18, 18, 12, 0], [0, 60, 66, 82, 98, 66, 60, 0], [0, 126, 18, 18, 18, 50, 76, 0], [0, 36, 74, 74, 74, 74, 48, 0], [2, 2, 2, 126, 2, 2, 2, 0], [0, 62, 64, 64, 64, 64, 62, 0], [0, 30, 32, 64, 64, 32, 30, 0], [0, 62, 64, 32, 32, 64, 62, 0], [0, 66, 36, 24, 24, 36, 66, 0], [2, 4, 8, 112, 8, 4, 2, 0], [0, 66, 98, 82, 74, 70, 66, 0], [0, 0, 0, 0, 126, 66, 66, 0], [0, 4, 8, 16, 32, 64, 0, 0], [0, 66, 66, 126, 0, 0, 0, 0], [0, 8, 4, 2, 4, 8, 0, 0], [128, 128, 128, 128, 128, 128, 128, 128], [0, 0, 0, 2, 4, 0, 0, 0], [0, 32, 84, 84, 84, 120, 0, 0], [0, 0, 126, 72, 72, 72, 48, 0], [0, 0, 56, 68, 68, 68, 0, 0], [0, 48, 72, 72, 72, 126, 0, 0], [0, 56, 84, 84, 84, 72, 0, 0], [0, 0, 0, 124, 10, 2, 0, 0], [0, 24, 164, 164, 164, 124, 0, 0], [0, 126, 8, 8, 8, 112, 0, 0], [0, 0, 72, 122, 64, 0, 0, 0], [0, 0, 64, 128, 128, 122, 0, 0], [0, 0, 126, 24, 36, 64, 0, 0], [0, 0, 0, 62, 64, 64, 0, 0], [0, 124, 4, 120, 4, 120, 0, 0], [0, 124, 4, 4, 4, 120, 0, 0], [0, 56, 68, 68, 68, 56, 0, 0], [0, 252, 36, 36, 36, 24, 0, 0], [0, 24, 36, 36, 36, 252, 128, 0], [0, 0, 120, 4, 4, 4, 0, 0], [0, 72, 84, 84, 84, 32, 0, 0], [0, 0, 4, 62, 68, 64, 0, 0], [0, 60, 64, 64, 64, 60, 0, 0], [0, 12, 48, 64, 48, 12, 0, 0], [0, 60, 64, 56, 64, 60, 0, 0], [0, 68, 40, 16, 40, 68, 0, 0], [0, 28, 160, 160, 160, 124, 0, 0], [0, 68, 100, 84, 76, 68, 0, 0], [0, 0, 8, 8, 118, 66, 66, 0], [0, 0, 0, 0, 126, 0, 0, 0], [0, 66, 66, 118, 8, 8, 0, 0], [0, 0, 4, 2, 4, 2, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 122, 0, 0, 0], [0, 0, 60, 36, 126, 36, 36, 0], [0, 72, 124, 74, 74, 66, 68, 0], [0, 0, 68, 56, 40, 56, 68, 0], [2, 20, 24, 112, 24, 20, 2, 0], [0, 0, 0, 0, 102, 0, 0, 0], [0, 0, 20, 170, 170, 80, 0, 0], [0, 1, 0, 0, 0, 1, 0, 0], [60, 66, 153, 165, 165, 129, 66, 60], [0, 0, 36, 43, 43, 46, 0, 0], [0, 16, 40, 68, 16, 40, 68, 0], [0, 0, 8, 8, 8, 8, 56, 0], [0, 0, 16, 16, 16, 16, 16, 0], [60, 66, 189, 149, 149, 169, 66, 60], [1, 1, 1, 1, 1, 1, 1, 1], [0, 0, 4, 10, 10, 4, 0, 0], [0, 0, 72, 72, 126, 72, 72, 0], [0, 0, 0, 9, 13, 10, 0, 0], [0, 0, 0, 9, 11, 6, 0, 0], [0, 0, 0, 4, 2, 0, 0, 0], [0, 252, 64, 64, 64, 60, 64, 0], [0, 12, 18, 18, 126, 18, 126, 0], [0, 0, 0, 24, 24, 0, 0, 0], [0, 0, 0, 128, 96, 0, 0, 0], [0, 0, 0, 10, 15, 8, 0, 0], [0, 0, 38, 41, 41, 38, 0, 0], [0, 68, 40, 16, 68, 40, 16, 0], [0, 78, 32, 16, 8, 52, 98, 0], [0, 78, 32, 16, 8, 84, 82, 0], [0, 74, 46, 16, 8, 52, 98, 0], [0, 48, 72, 69, 64, 64, 32, 0], [0, 120, 20, 21, 22, 20, 120, 0], [0, 120, 20, 22, 21, 20, 120, 0], [0, 120, 22, 21, 21, 22, 120, 0], [0, 120, 21, 21, 21, 21, 120, 0], [0, 120, 21, 20, 20, 21, 120, 0], [0, 120, 22, 21, 21, 22, 120, 0], [124, 18, 18, 126, 74, 74, 66, 0], [0, 60, 66, 194, 98, 66, 36, 0], [0, 124, 84, 85, 86, 84, 68, 0], [0, 124, 84, 86, 85, 84, 68, 0], [0, 124, 86, 85, 85, 86, 68, 0], [0, 124, 85, 84, 84, 85, 68, 0], [0, 0, 68, 69, 126, 68, 68, 0], [0, 0, 68, 68, 126, 69, 68, 0], [0, 0, 68, 70, 125, 70, 68, 0], [0, 0, 68, 69, 124, 69, 68, 0], [0, 8, 126, 74, 66, 36, 24, 0], [0, 124, 5, 9, 17, 33, 124, 0], [0, 56, 68, 69, 70, 68, 56, 0], [0, 56, 68, 70, 69, 68, 56, 0], [0, 56, 70, 69, 69, 70, 56, 0], [0, 56, 69, 69, 69, 69, 56, 0], [0, 56, 69, 68, 68, 69, 56, 0], [0, 0, 68, 40, 16, 40, 68, 0], [0, 124, 98, 82, 74, 70, 62, 0], [0, 60, 65, 66, 64, 60, 0, 0], [0, 60, 64, 66, 65, 60, 0, 0], [0, 60, 66, 65, 66, 60, 0, 0], [0, 61, 64, 64, 64, 61, 0, 0], [0, 4, 8, 114, 9, 4, 0, 0], [0, 126, 36, 36, 36, 36, 24, 0], [0, 0, 124, 2, 74, 74, 52, 0], [0, 32, 85, 86, 84, 120, 0, 0], [0, 32, 84, 86, 85, 120, 0, 0], [0, 32, 86, 85, 86, 120, 0, 0], [0, 32, 85, 85, 85, 120, 0, 0], [0, 32, 85, 84, 85, 120, 0, 0], [0, 32, 86, 85, 86, 120, 0, 0], [32, 84, 84, 120, 84, 84, 72, 0], [0, 56, 68, 196, 100, 68, 0, 0], [0, 56, 85, 86, 84, 72, 0, 0], [0, 56, 84, 86, 85, 72, 0, 0], [0, 56, 86, 85, 86, 72, 0, 0], [0, 56, 85, 84, 85, 72, 0, 0], [0, 0, 73, 122, 64, 0, 0, 0], [0, 0, 72, 122, 65, 0, 0, 0], [0, 0, 74, 121, 66, 0, 0, 0], [0, 0, 74, 120, 66, 0, 0, 0], [0, 48, 74, 74, 78, 60, 2, 0], [0, 124, 9, 5, 5, 120, 0, 0], [0, 48, 73, 74, 72, 48, 0, 0], [0, 48, 72, 74, 73, 48, 0, 0], [0, 48, 74, 73, 74, 48, 0, 0], [0, 56, 69, 69, 69, 56, 0, 0], [0, 57, 68, 68, 68, 57, 0, 0], [0, 0, 16, 16, 84, 16, 16, 0], [0, 120, 100, 84, 76, 60, 0, 0], [0, 56, 65, 66, 64, 56, 0, 0], [0, 56, 64, 66, 65, 56, 0, 0], [0, 56, 66, 65, 66, 56, 0, 0], [0, 58, 64, 64, 64, 58, 0, 0], [0, 24, 160, 162, 161, 120, 0, 0], [0, 254, 40, 40, 40, 16, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0]]

Bit patterns for SPECCY_FONT (another font based on the character set from the ZX Spectrum). Source: https://www.kreativekorp.com/software/fonts/index.shtml, transposed by Tiago F. Pimentel (antropoiese).

class luma.core.legacy.font.proportional(font)[source]

Bases: object

Wraps an existing font array, and on on indexing, trims any leading or trailing zero column definitions. This works especially well with scrolling messages, as interspace columns are squeezed to a single pixel.

class luma.core.legacy.font.tolerant(font, missing='_')[source]

Bases: object

Wraps an existing font array, and on indexing, if the supplied ascii_code does not exist, will return the column definitions for the given missing parameter.

New in version 0.9.4.