Solved

InDesign CC straight quotes

Posted on 2014-04-01
7
1,631 Views
Last Modified: 2014-04-08
I am working on some training materials for my students and am setting up the worksheet in Indesign. I have typographer quotes turned on in the preferences and use it for where I write directions.  For the code snippets however I want straight quotes.

I know I can go and turn off the typographer quotes and then type the code, but if I have typographer quotes turned on and copy paste code they all become curly. Interesting enough, if I start with curly quotes and then turn off typography quotes and then paste they stay curly.

Is there a way I can set up a style that will always use straight quotes so that if students copy past the code they don't end up getting errors from the curly quotes?

Thanks
0
Comment
Question by:lvmllc
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
7 Comments
 
LVL 22

Expert Comment

by:Sigurdur Armannsson
ID: 39969680
See if this works for you:

Select the text in question.
Go to Find & Change.
Select the GREP tab.

In Find: ~{(.+?)~}  
[This means: Any Double Left Quote – Any Character, one or more, non greedy – Protected. Any Right Double Quote Mark]

In Change to: ~"$1~"
[This means: Straight Quote. The protected content between the Parenthesis. Straight Quote.

Try first Find and if it works then Change all.

Copy and paste to the new source.

If this works, click the hard disk symbol at the top of the Find window to save this command for later use.
0
 
LVL 35

Expert Comment

by:Dan Craciun
ID: 39969861
I don't know how you can do it using styles, but you can use Ctrl+Alt+Shift+' to disable/enable typographer quotes.

So you can press Ctrl+Alt+Shift+', paste your code (preserving the straight quotes), then press Ctrl+Alt+Shift+' again to re-enable typographer's quotes.

HTH,
Dan
0
 

Author Comment

by:lvmllc
ID: 39970307
sigurarm,
I can sort of make your solution work, but two questions.

If I need to convert all curly single and double quotes to straight single or double can I do this in one search/replace?

Seems strange this can not be applied to a style.
0
Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

 
LVL 35

Expert Comment

by:Dan Craciun
ID: 39970340
As I see it, that preference triggers a script that applies to all styles so it would not make sense to be style dependent.
0
 
LVL 22

Expert Comment

by:Sigurdur Armannsson
ID: 39970781
Because quotation marks and straight quotes (inch) are individual characters you can not use changes in styles to work on it.

However, you could make a Paragraph style to use on the code text. Using it you could use my solution but add at the bottom of the Find window the name of the style. That way the changes would only happen in text that is marked by that paragraph style. See the picture find by format
0
 
LVL 22

Accepted Solution

by:
Sigurdur Armannsson earned 400 total points
ID: 39970787
oh, yes, you can do it in one find and change run. Simply Change All. And as I said, filter it by paragraph style

Please use this image. I made a small but vital mistake in the first one. It has to filter the Find Format – not Change to Format.
findchange.jpg
0
 
LVL 22

Expert Comment

by:Sigurdur Armannsson
ID: 39971024
I tested this over and over and it works amazingly well. Only does the text in the paragraph style of choice.
0

Featured Post

Enroll in June's Course of the Month

June's Course of the Month is now available! Every 10 seconds, a consumer gets hit with ransomware. Refresh your knowledge of ransomware best practices by enrolling in this month's complimentary course for Premium Members, Team Accounts, and Qualified Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever wanted to create graphical elements directly in inDesign? This tutorial will teach you how to have an image bound within text using the pathfinder tool in inDesign CS6. This technique will help decrease the amount of time spent opening…
You can download the files for this tutorial here (https://www.dropbox.com/s/hgztzt9b60kddc9/DPS%20Demo.zip?dl=0). The .indd file in the InDesign files folder is a finished version of the file; you can start from scratch and work toward this. Also, …
Learn how to automatically add page numbers in your next InDesign project. This can be very helpful in multi-page books and magazines that you are designing. Make sure your Pages window visible.:  In the document you wish to add page numbers to. Act…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question