mmontone / emacs-inspector

Inspection tool for Emacs Lisp objects.
GNU General Public License v3.0
107 stars 9 forks source link

Fontification issue #5

Closed joostkremers closed 2 years ago

joostkremers commented 2 years ago

This looks like a package that could be very useful in certain situations. Thanks for working on this!

I noticed an issue with fontification in the inspector buffer: if a string is truncated, its fontification "leaks" into the next object:

image

mmontone commented 2 years ago

Thanks for reporting. I'll try to fix ..

mmontone commented 2 years ago

Mmm.. I think I've seen this bug before, but now I'm not able to reproduce ..

Do you have an snippet with elisp data that I can use with the inspector to reproduce this bug?

mmontone commented 2 years ago

Ok. I'm able to reproduce if I inspect this: (make-button 0 10) and go deep with the inspector ..

mmontone commented 2 years ago

I've made inspector-mode inherit from fundamental-mode instead of emacs-lisp-mode, and that seems to fix the fontification issues.

How does it work for you?

joostkremers commented 2 years ago

How does it work for you?

I must admit I have mixed feelings. It's better in the sense that the issue no longer occurs, but I did prefer the previous font effects. This is how it looks now:

image

Of course this depends on the theme I'm using, so I'd completely understand if you'd decide not to pursue it further.

mmontone commented 2 years ago

I think that theme fontifies in a specially ugly way.

This is how it looks around here:

imagen

But I'll try to fontify using elisp faces and see what happens ...

mmontone commented 2 years ago

I've made another change. Using font-lock standard faces for some of the objects. How does it look for you now?

joostkremers commented 2 years ago

I've made another change. Using font-lock standard faces for some of the objects. How does it look for you now?

It's much better now. :+1: