texmacs-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Texmacs-dev] Overwriting selections


From: Joris van der Hoeven
Subject: Re: [Texmacs-dev] Overwriting selections
Date: Tue, 2 Nov 2010 18:43:51 +0100
User-agent: Mutt/1.5.18 (2008-05-17)

Dear Norbert,

Thanks for reminding this issue to me; I put it on my TODO list.
It may require some non trivial modifications, because we should
be able to restore the state of the pointer and selections after 'undo',
as pointed out in the subsequent posts to this message.
This would actually be good anyway and useful for many other things.
Also, insert_tree seems a bit dangerous as a place to do the cut,
so I will need to refactor some code.

Best wishes, --Joris


On Thu, Oct 28, 2010 at 12:19:17PM +0200, Norbert Nemec wrote:
> Hi there,
> 
> just updated to the latest SVN version for the first time in months. I am 
> impressed by the progress. Great work!
> 
> Since the Look&Feel is currently being worked on, I would like to bring up a 
> small issue that has been open for some time: In KDE and probably most other 
> environments, an active selection should be automatically replaced as soon as 
> any other content is entered. This behavior can be achieved by adding one 
> single line:
> 
> --------------------------------------
> --- a/src/src/Edit/Modify/edit_text.cpp
> +++ b/src/src/Edit/Modify/edit_text.cpp
> @@ -197,6 +197,7 @@ edit_text_rep::prepare_for_insert () {
>  
>  void
>  edit_text_rep::insert_tree (tree t, path p_in_t) {
> +  selection_cut("none");
>    if (is_atomic (t) && (p_in_t == end (t)) &&
>        is_atomic (subtree (et, path_up (tp))))
>      insert (tp, t);
> --------------------------------------
> 
> I have had this patch in my working repository for quite some time and have 
> not found any unintentional side-effects. Only issue might be to make it 
> depend properly on the L&F environment.
> 
> Greetings,
> Norbert
> -- 
> GRATIS! Movie-FLAT mit über 300 Videos. 
> Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome
> 
> _______________________________________________
> Texmacs-dev mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/texmacs-dev



reply via email to

[Prev in Thread] Current Thread [Next in Thread]