Closed ttytm closed 1 year ago
Currently, no filetype is set for a previewed filed. Setting the ft would enable syntax highlighting.
I didn't made any implementation test yet, so my theoretical assumptionion on how this could be solved: It might be possible to directly retrieve the filetype when opening the preview. If not, it might be worth the tradeoff to additionally save
ft = vim.bo.ft
on bookmark creation.Screenshot, manually setting the ft in a previewed file after opening the window.
Might be related to #13 (edit: didn't read through the issue properly. No relation afaik.)
In the setup options, preview_ext_enable
is used to configure whether to add a filetype suffix to the current buffer.
Awesome! Sorry for not checking better beforehand. Let me close this.
Currently, no filetype is set for a previewed filed. Setting the ft would enable syntax highlighting.
I didn't made any implementation test yet, so my theoretical assumptionion on how this could be solved: It might be possible to directly retrieve the filetype when opening the preview. If not, it might be worth the tradeoff to additionally save
ft = vim.bo.ft
on bookmark creation.Screenshot, manually setting the ft in a previewed file after opening the window.
Might be related to #13 (edit: didn't read through the issue properly. No relation afaik.)