Feature request: Eliding ranges
Hello, we sometimes have diagnostics where notes are scattered across various functions in big files (we do interprocedural analysis).
Grace ends up showing half the file, instead of eliding the big ranges that do not have any piece of the diagnostic. It would be good if one could specify the maximum number of lines around diagnostics that one wants to show. Does that make sense?
This shouldn't be too difficult, the addition of 'contextual lines' is handled here: https://github.com/johnyob/grace/blob/c8aa9abfd69250b5610f8d7d1e1e914f1d748b9d/lib/ansi_renderer/snippet.ml#L339
By default we add +- 1 lines for contextual lines around multi-line labels. We can easily make this configurable.