Dear all This is a bit farfetched, but maybe it is possible. At the moment one may use custom font, font colour and background colour in the embedded VTE.
However, can the VTE be flexible enough to allow certain lines to have a different formatting? I am interested in selections 'sent to terminal': would it be feasible to have an option that would ensure, for example, that any 'selection sent to terminal' would be formatted in red colour in the VTE?
In case you were wondering I am still rambling on R usage. Some R editors provide custom formatting for inputs and outputs (usually red and blue, respectively) since it eases the recognition and scrolling of results. In Geany I'm using a bare bones console (which is great by me!) and I'm often missing at least some basic formatting. To give you a visual hint of what I'm seeking, I attach a shot from JGR, another from Rcmdr, and a third from Geany.
Thank you Liviu
On 12/18/2010 02:51 AM, Liviu Andronic wrote:
However, can the VTE be flexible enough to allow certain lines to have a different formatting? I am interested in selections 'sent to terminal': would it be feasible to have an option that would ensure, for example, that any 'selection sent to terminal' would be formatted in red colour in the VTE?
One way that might work would be to "encode" the text before it's sent with color escape sequences that the terminal already recognizes[1]. I'm not sure if this could be done from a plugin, but it could probably be done in Geany's source code, although considering how esoteric an option it is, it seems unlikely to be a desired feature for most. I could be wrong.
What you could do if you wanted a really customized VTE is to write your own VTE[2] plugin and add in menu items like "Send to My Custom Terminal in Red" or whatever.
[1] http://www.tldp.org/HOWTO/Bash-Prompt-HOWTO/x329.html [2] http://library.gnome.org/devel/vte/0.26/
My two cents.
Cheers, Matthew Brush (codebrainz)
On Sat, 18 Dec 2010 07:46:37 -0800 Matthew Brush matthewbrush@gmail.com wrote:
On 12/18/2010 02:51 AM, Liviu Andronic wrote:
However, can the VTE be flexible enough to allow certain lines to have a different formatting? I am interested in selections 'sent to terminal': would it be feasible to have an option that would ensure, for example, that any 'selection sent to terminal' would be formatted in red colour in the VTE?
One way that might work would be to "encode" the text before it's sent with color escape sequences that the terminal already recognizes[1]. I'm not sure if this could be done from a plugin, but it could probably be done in Geany's source code, although considering how esoteric an option it is, it seems unlikely to be a desired feature for most. I could be wrong.
I'm not sure something like that is fitting into core, but also not sure at the moment whether it can be done as a plugin.
Cheers, Frank
On Mon, Dec 27, 2010 at 12:11 AM, Frank Lanitz frank@frank.uvena.de wrote:
On Sat, 18 Dec 2010 07:46:37 -0800 Matthew Brush matthewbrush@gmail.com wrote:
On 12/18/2010 02:51 AM, Liviu Andronic wrote:
However, can the VTE be flexible enough to allow certain lines to have a different formatting? I am interested in selections 'sent to terminal': would it be feasible to have an option that would ensure, for example, that any 'selection sent to terminal' would be formatted in red colour in the VTE?
One way that might work would be to "encode" the text before it's sent with color escape sequences that the terminal already recognizes[1].
I looked into this, but in my understanding when working with R we no longer deal with a "traditional" terminal that would recognize such escape sequences: the selection, including potential wrap-up sequences, are sent to the R interpreter, which is a whole different beast. From my investigations I don't think that the R terminal can easily handle such sequences, or anything similar. There are some R packages/functions that can apply custom formatting to supplied inputs, but not in the way I'm looking for.
I'm not sure if this could be done from a plugin, but it could probably be done in Geany's source code, although considering how esoteric an option it is, it seems unlikely to be a desired feature for most. I could be wrong.
I'm not sure something like that is fitting into core, but also not sure at the moment whether it can be done as a plugin.
I had some hope in Pygments [1], a generic syntax highlighter that can be used as a command-line tool and as a library, but I'm not sure whether such integration with the VTE is possible. And I'm even less convinced that this has much to do with Geany; it seems more like a job for an R package to provide integration with Pygments.
Regards Liviu
Cheers, Frank -- Frank Lanitz frank@frank.uvena.de
Geany-devel mailing list Geany-devel@uvena.de http://lists.uvena.de/cgi-bin/mailman/listinfo/geany-devel