bastibe / annotate.el

Annotate.el
Other
384 stars 20 forks source link

Prevented calling 'annotate--remove-annotation-property' on a narrowed buffer #106

Closed cage2 closed 3 years ago

cage2 commented 3 years ago

Hi @bastibe !

From the commit message:

`For some reason (perhaps related to font-locking?) comment-region command was calling this function, the fact is that the command narrows the buffer before actually adding comments, so the call to point' inside the annotate--remove-annotation-property's body may fall outside of the buffer raising an error. This patch prevents calling this function on narrowed buffer.''

This patch should fix #103 and i feel #86 too.

Bye! C.

bastibe commented 3 years ago

Looks good to me!

The endless intricacies of Emacs continue to amaze. I wonder if anyone knows all the myriad ways in which Emacs can show the contents of a text file.

cage2 commented 3 years ago

Hi @bastibe !

The endless intricacies of Emacs continue to amaze.

I could not agree more! :) I still wonder if the patch proposed is the best solution to the issue reported as there are so many variable on the table! Fortunately Emacs seems to have all the functions in its standard library to fix things, at least so far! ;-D :D

I have updated the docs and the version number (1.2.1), i am going to merge this patch in the next hours!

Bye and thanks for checking the code! :) C.

cage2 commented 3 years ago

OK, merging! :)

bastibe commented 3 years ago

By the way, feel free to just write your name in the changelog. It'd be entirely justified!

cage2 commented 3 years ago

Hi!!

By the way, feel free to just write your name in the changelog. It'd be entirely justified!

I am actually happy to put both names: yours and mine in the changelog as you reviewed each single pull request i made (except the simpler ones, maybe) in more than a year, each review helped to shape the program as much as the code i wrote, in my opinion. In short i think you deserve the credits :)

Anyway if this makes you uncomfortable (for any reasons, or even no reasons :)) i would not add your name in the future, totally your choice and i will respect that! :)

Bye! C.