" -> \(lq ... " -> \(rq

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

" -> \(lq ... " -> \(rq

tuxic
Hi,

The troff has infected me! :)

Troff distinquishes between the "opening"
double-quote and the "closing" double
quote by using \(lq nad \(rq instead.

I could think of a non-100% safe regex
to detect opening and closing ", but
this would miss in one or the other
case.

Is their a function or anything else,
which would allow me to write someting
which get closer to 100% error free
detection of opening and closing "
in vim?

...or may be, my regex fu isn't that
bright?

Cheers!
mcc


--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/20210304223607.coipp5tjkxkzob4j%40solfire.
Reply | Threaded
Open this post in threaded view
|

Re: " -> \(lq ... " -> \(rq

Stan Brown

On 2021-03-04 14:36, [hidden email] wrote:
> Troff distinquishes between the "opening"
> double-quote and the "closing" double
> quote by using \(lq nad \(rq instead.
>
> Is their a function or anything else,
> which would allow me to write someting
> which get closer to 100% error free
> detection of opening and closing "
> in vim?

If you want the actual characters, this will take you to the next
occurrence:

/[“”]/

In other words, put the two quote marks within square brackets.

If you want the troff sequences, use

/\\([lr]q/

The help text is at

:h /[]

--
Stan Brown
Tehachapi, CA, USA
https://BrownMath.com
https://OakRoadSystems.com

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/cda161d8-3ee0-2ed7-9ca2-3879dc3dab75%40fastmail.fm.
Reply | Threaded
Open this post in threaded view
|

Re: " -> \(lq ... " -> \(rq

tuxic

Hi Stan,

thanks a lot! :) Helps me a lot!

Cheers!
mcc


On 03/04 03:10, Stan Brown wrote:

>
> On 2021-03-04 14:36, [hidden email] wrote:
> > Troff distinquishes between the "opening"
> > double-quote and the "closing" double
> > quote by using \(lq nad \(rq instead.
> >
> > Is their a function or anything else,
> > which would allow me to write someting
> > which get closer to 100% error free
> > detection of opening and closing "
> > in vim?
>
> If you want the actual characters, this will take you to the next
> occurrence:
>
> /[“”]/
>
> In other words, put the two quote marks within square brackets.
>
> If you want the troff sequences, use
>
> /\\([lr]q/
>
> The help text is at
>
> :h /[]
>
> --
> Stan Brown
> Tehachapi, CA, USA
> https://BrownMath.com
> https://OakRoadSystems.com
>
> --
> --
> You received this message from the "vim_use" maillist.
> Do not top-post! Type your reply below the text you are replying to.
> For more information, visit http://www.vim.org/maillist.php
>
> ---
> You received this message because you are subscribed to the Google Groups "vim_use" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
> To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/cda161d8-3ee0-2ed7-9ca2-3879dc3dab75%40fastmail.fm.
>

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/20210305141256.kixjb6swsvmgm4hj%40solfire.