Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Substitution of metacharacters
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  4 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Christian Brabandt  
View profile  
 More options May 24 2012, 4:14 pm
From: Christian Brabandt <cbli...@256bit.org>
Date: Thu, 24 May 2012 22:14:35 +0200
Local: Thurs, May 24 2012 4:14 pm
Subject: Re: Substitution of metacharacters

Hi Bob!

On Do, 24 Mai 2012, Bob von Knobloch wrote:

> Hi, I've searched all over but can't find an answer. How can one perform
> commands like ':%s/\n/\r\r/g' (replacing newlines or tabs etc.) in the
> gui's 'find and replace' dialogue?

Not possible, the replace text is escaped:

,----[ gui.c ]-
|5276  ga_concat(&ga, (char_u *)"/");
|5277                                         /* escape / and \ */
|5278  p = vim_strsave_escaped(repl_text, (char_u *)"/\\");
`----

Here is an experimental patch against the gtk gui, that adds an extra
flag, and allows to replace with special chars ,e.g. \t for Tab

Looking at the dialog, it could possibly also get some more
possibilities, e.g. a confirm/undo button, perhaps even more.

regards,
Christian

  promptrepl_extra.diff
4K Download

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ben Fritz  
View profile   Translate to Translated (View Original)
 More options May 25 2012, 10:01 am
From: Ben Fritz <fritzophre...@gmail.com>
Date: Fri, 25 May 2012 07:01:03 -0700 (PDT)
Local: Fri, May 25 2012 10:01 am
Subject: Re: Substitution of metacharacters

On Thursday, May 24, 2012 3:14:35 PM UTC-5, Christian Brabandt wrote:

> Looking at the dialog, it could possibly also get some more
> possibilities, e.g. a confirm/undo button, perhaps even more.

Well, there's this in todo.txt:

7   More features in the find/replace dialog:
    - regexp on/off
    - search in selection/buffer/all buffers/directory
       when all buffers/directory is used:
        - filter for file name
       when directory is used:
        - subdirectory on/off
        - top directory browser


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Christian Brabandt  
View profile  
 More options May 26 2012, 8:30 am
From: Christian Brabandt <cbli...@256bit.org>
Date: Sat, 26 May 2012 14:30:59 +0200
Local: Sat, May 26 2012 8:30 am
Subject: Re: Substitution of metacharacters

On Do, 24 Mai 2012, Christian Brabandt wrote:

Here is an even improved version of the patch, which adds the buttons
Undo and Redo to the gtk and motif version and which adds an extra
parameter whether to search/replace literally.

regards,
Christian

  promptrepl_undo_redo.diff
11K Download

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Christian Brabandt  
View profile  
 More options Jun 2 2012, 9:03 am
From: Christian Brabandt <cbli...@256bit.org>
Date: Sat, 2 Jun 2012 15:03:27 +0200
Local: Sat, Jun 2 2012 9:03 am
Subject: Re: Substitution of metacharacters

On Sa, 26 Mai 2012, Christian Brabandt wrote:

One more update:
     - Replace should work better now (and works like in the current
       version of Gvim).
     - When using REPLACE, the cursor is positioned at the next match,
       but it doesn't take into account, that it could match at the
       current cursor position (so adding the flag SEARCH_START to the
       do_search function) (simple example, search for \. in the gui and
       replace it by A, you'll notice, it will only replace every other
       character).

regards,
Christian
--

  prompt_repl.diff
11K Download

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »