dylan-lang / dylan-emacs-support

Emacs mode for indenting and highlighting Dylan code
GNU General Public License v2.0
27 stars 8 forks source link

Changes to LID mode (2nd attempt) #25

Closed pedro-w closed 5 years ago

pedro-w commented 6 years ago

This allows clickable links to be added to .lid files without those files being marked as changed. Also cleaned up a warning from emacs byte-compiler. This version continues to use text properties rather than change to using overlays.

pedro-w commented 6 years ago

Actually this still isn't right because, as far as I can see, it starts a new idle timer every time it loads a .lid file and never stops any of them. How to deal with this (maybe kill-buffer-hook)? @ecraven what would you recommend?

pedro-w commented 6 years ago

I think the latest commits have stopped the problem of multiple timers being created.

I should have explained this more clearly; the current code has two main problems which this PR fixes

  1. If you have a read-only buffer open dylanlid-mode may try and change it (giving messages like "Error running timer ‘dylanlid-make-files-clickable’: (buffer-read-only #<buffer Packages>) ")
  2. If you open a lid file for your project, dylanlid-mode will mark it as changed and emacs will ask you if you want to save it, even if it has no changes.