d0c-s4vage / lookatme

An interactive, terminal-based markdown presenter
https://lookatme.readthedocs.io/en/latest/
MIT License
2.06k stars 59 forks source link

fix attribute error related to pygments #225

Open felixscherz opened 3 months ago

felixscherz commented 3 months ago

Hi, this fixes the issue discussed in https://github.com/d0c-s4vage/lookatme/issues/224 related to https://github.com/d0c-s4vage/lookatme/blob/c05abe1804d93254e9139039937eed43fb6b49ab/lookatme/render/pygments.py#L72. The background attribute in the urwid.AttrSpec class is now a property. To modify it we need to create a copy of the object with urwid.AttrSpec.copy_modified.

carbon-steel commented 3 months ago

I added this into my local version of lookatme and it now runs! Thanks so much for sharing this fix :)