Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-07-20 Thread Ihor Radchenko
Nathaniel Nicandro writes: >> Let's drop the part with modifications/visibility changes. It should not >> be a job for fontification function, so let's not complicate things (as >> I mentioned above). I believe that 'org-ansi may no longer be needed >> once we drop this. >> > > You want me to rem

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-07-17 Thread Nathaniel Nicandro
Ihor Radchenko writes: >> Some comments about the patch, as it currently stands, follow. >> >> - I've introduced two text properties `org-ansi' and >> `org-ansi-context'. >> >> The first is placed on the regions that actually contain ANSI >> sequences and holds information about the sequenc

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-07-16 Thread Nathaniel Nicandro
Ihor Radchenko writes: > Thanks for the update! And for the resilience working on this difficult > patch :) It has been giving me some trouble :) > I believe that `font-lock-extend-region-functions' should be able to > tackle this situation. Is there any problem with it? I think I have been ab

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-07-06 Thread Ihor Radchenko
Nathaniel Nicandro writes: >> Nathaniel, may I know if you are still working on this? > > Hello Ihor, > > Yes I'm still working on this. Attached is an updated patch with some > tests this time. It's still a work in progress. Below are responses to > your previous comments about my last update

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-07-01 Thread Nathaniel Nicandro
Ihor Radchenko writes: > Ihor Radchenko writes: > >> Nathaniel Nicandro writes: >> >>> Feedback appreciated! >> >> Thanks for the update! >> ... >>> I've finally implemented a solution to what I've discussed previously, >> ... > > It has been a while since the last update in this thread. > Nat

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-06-29 Thread Ihor Radchenko
Ihor Radchenko writes: > Nathaniel Nicandro writes: > >> Feedback appreciated! > > Thanks for the update! > ... >> I've finally implemented a solution to what I've discussed previously, > ... It has been a while since the last update in this thread. Nathaniel, may I know if you are still workin

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-03-28 Thread Ihor Radchenko
Nathaniel Nicandro writes: > Feedback appreciated! Thanks for the update! > I've finally implemented a solution to what I've discussed previously, > inserting zero width spaces as boundary characters after an ANSI > sequence to act as a separator from the text after the sequence. This > would

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-03-26 Thread Nathaniel Nicandro
Ihor Radchenko writes: > Nathaniel Nicandro writes: Hello, I've finally implemented a solution to what I've discussed previously, inserting zero width spaces as boundary characters after an ANSI sequence to act as a separator from the text after the sequence. This would handle the scenario w

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-01-17 Thread Ihor Radchenko
Nathaniel Nicandro writes: > Hello, attached is another updated patch with the following changes: Thanks! > - To tackle the issue discussed previously about highlights spanning > multiple lines (or elements) being removed when a line is modified I > went ahead and used the font-lock-multili

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2024-01-16 Thread Nathaniel Nicandro
Ihor Radchenko writes: Hello, attached is another updated patch with the following changes: - Made it possible to add headlines or inline tasks to `org-ansi-highlightable-elements', these are added by default now. - To tackle the issue discussed previously about highlights spanning multipl

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-12-24 Thread Nathaniel Nicandro
Matt writes: > Thank you for bringing this to my attention and thank you Nathaniel for your > work on this. No problem, I'm glad to contribute to Org :) > Nathaniel, if you and I happen to cross paths in one of Ihor's "office > hours," I would enjoy learning more about what you're doing. Su

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-12-24 Thread Nathaniel Nicandro
Ihor Radchenko writes: > It runs fine on my side, although I am not sure if things are working as > expected for all the cases. For example, headlines never got fontified > on my side when I tried your patch on top of the latest main branch. Yes, the headlines are currently not fontified since

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-12-15 Thread Matt
On Thu, 14 Dec 2023 15:35:13 +0100 Ihor Radchenko wrote --- > Matthew, this thread might be of interest for you as the new feature is > largely aiming at the shell block output. > Feel free to jump in if you have comments on the design of the > ASCII fontification for complex shell

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-12-14 Thread Ihor Radchenko
Nathaniel Nicandro writes: > From 66baf6e1d435974fb4c51cc47eb5b3ace3feb22c Mon Sep 17 00:00:00 2001 > From: Nathaniel Nicandro > Date: Tue, 9 May 2023 19:58:11 -0500 > Subject: [PATCH] Highlight ANSI escape sequences Matthew, this thread might be of interest for you as the new feature is largel

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-12-14 Thread Ihor Radchenko
Nathaniel Nicandro writes: > Attached is the updated version of the patch. I've also attached an > updated file that I've been using for testing the feature. Sorry for the late reply, and thanks for the patch! It runs fine on my side, although I am not sure if things are working as expected for

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-11-17 Thread Nathaniel Nicandro
Ihor Radchenko writes: > I think that the most reasonable approach to fontify ANSI sequences will > be the following: > > 1. We will consider ANSI within (a) all greater elements and lesser >elements that have RESULTS affiliated keyword (indicating that they >are result of code block eva

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-11-10 Thread Ihor Radchenko
Nathaniel Nicandro writes: >> A few months have passed since the last activity in this thread. >> May I know if you are still interested in the idea? > > I apologize for being unresponsive all these months. Yes I'm still > interested in this idea, although I have not had time to work on it > rece

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-11-08 Thread Nathaniel Nicandro
Ihor Radchenko writes: > Hi, Hi Ihor, > A few months have passed since the last activity in this thread. > May I know if you are still interested in the idea? I apologize for being unresponsive all these months. Yes I'm still interested in this idea, although I have not had time to work on i

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-11-08 Thread Ihor Radchenko
Ihor Radchenko writes: > A few months have passed since the last activity in this thread. Canceled. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-08-08 Thread Ihor Radchenko
Hi, A few months have passed since the last activity in this thread. May I know if you are still interested in the idea? Should you need any help, feel free to ask. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development a

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-05-22 Thread Nathaniel Nicandro
Ihor Radchenko writes: > Nathaniel Nicandro writes: > >>> 1. Do not allow ANSI sequences to intersect markup boundaries of the >>>same AST depth: >>>*bold * plain text should not trigger fontification >>>*bold /italic/ * should trigger >>>plain text *bold* plain text also s

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-05-18 Thread Ihor Radchenko
Nathaniel Nicandro writes: >> 1. Do not allow ANSI sequences to intersect markup boundaries of the >>same AST depth: >>*bold * plain text should not trigger fontification >>*bold /italic/ * should trigger >>plain text *bold* plain text also should > > Just to make sure I'm get

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-05-18 Thread Nathaniel Nicandro
Ihor Radchenko writes: > Nathaniel Nicandro writes: > >> The attached patch now uses `org-element-at-point' and >> `org-element-context' to query for the bounds of elements. > > Thanks! > >> Note, I've also attached an updated example file which shows that the >> escape sequences in inline sou

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-05-10 Thread Ihor Radchenko
Nathaniel Nicandro writes: > The attached patch now uses `org-element-at-point' and > `org-element-context' to query for the bounds of elements. Thanks! > Note, I've also attached an updated example file which shows that the > escape sequences in inline source blocks are now handled similarly t

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-05-09 Thread Nathaniel Nicandro
Ihor Radchenko writes: > Nathaniel Nicandro writes: > >>> Ideally, fontifying ANSI sequences should be fully controlled by users: >>> 1. We may not want to touch src blocks by default, when >>>`org-src-fontify-natively' is set to t. Only, maybe, provide an >>>option. Or you may better p

Re: [PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-04-14 Thread Ihor Radchenko
Nathaniel Nicandro writes: >> Ideally, fontifying ANSI sequences should be fully controlled by users: >> 1. We may not want to touch src blocks by default, when >>`org-src-fontify-natively' is set to t. Only, maybe, provide an >>option. Or you may better publish a minor mode that does thi

[PATCH] Highlight ANSI sequences in the whole buffer (was [PATCH] ANSI color on example blocks and fixed width elements)

2023-04-13 Thread Nathaniel Nicandro
Ihor Radchenko writes: > Nathaniel Nicandro writes: > >> Attached is the patch. Without this patch, ANSI escape sequences >> generated by the output of a source block will be left in the buffer >> without any fontification. With this patch, the escaped text is nicely >> colored and escape seq