Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Re: One-liner to fix LaTeX quotation marks

by CountZero (Bishop)
on Oct 15, 2012 at 07:50 UTC ( #999021=note: print w/ replies, xml ) Need Help??

in reply to One-liner to fix LaTeX quotation marks

Perhaps not directly applicable to your post, but nevertheless very useful if you use LaTeX a lot and have to transform non-LaTeX to properly formatted LaTeX: LaTeX::Encode. It has an "intelligent quotes - iquotes" option in its main latex_encode routine.

single or double quotes around words will be changed to LaTeX single or double quotes; double quotes around a phrase will be converted to "``" and "''" and single quotes to "`" and "'". This is sometimes called "intelligent quotes"
So once you have replaced your double quotes by single quotes where necessary, you can run your text through latex_encode to get proper opening and closing quotes.


A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

My blog: Imperial Deltronics
Comment on Re: One-liner to fix LaTeX quotation marks
Select or Download Code

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://999021]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (6)
As of 2016-05-03 06:34 GMT
Find Nodes?
    Voting Booth?