-
1. Re: Preserving code formatting in PDF Export
Steve Werner May 22, 2012 11:51 AM (in response to pbear*)PDF is not designed for this. It's designed to preserve the appearance of the original file, including the embedded fonts. It wasn't designed to preserve code so that it could be copied accurately. How about creating links to a website, where the copying can be done?
-
2. Re: Preserving code formatting in PDF Export
pbear* May 22, 2012 12:11 PM (in response to Steve Werner)Hyperlinks I can do, though I think we want to keep it all in the book.
This might be more on the PDF/PostScript side of things, but it seems that it is technically possible. For example:
How to make listings code indentation remain unchanged when copied from pdf?
I'm wondering if anyone knows a way to do this kind of thing from within InDesign.
-
3. Re: Preserving code formatting in PDF Export
Dave Merchant May 22, 2012 12:22 PM (in response to pbear*)You can attach your code samples (as txt files) to the PDF, but there's no reliable way to implement a whitespace-preserved copy function from the page itself.
-
4. Re: Preserving code formatting in PDF Export
pbear* May 22, 2012 12:39 PM (in response to Dave Merchant)Dave,
"Attach" in a different sense from Steve, i.e. a hyperlink to an external file?
Thank you both for your replies.
-
5. Re: Preserving code formatting in PDF Export
Steve Werner May 22, 2012 4:38 PM (in response to pbear*)Dave's suggestion is a good one. You can attach files using the Attach File tool in the Comment pane of Acrobat X Pro, for example. You can read about it in Acrobat X Help.
-
6. Re: Preserving code formatting in PDF Export
pbear* May 22, 2012 5:36 PM (in response to Steve Werner)Ah, attachments in Acrobat X. I missed out as Acrobat versioning was out of sync with the rest of the Creative Suite. I'll have to read up on that. Guess I can pick it up when CS6 gets out.
Time to make a feature request for ID6.5 or 7 ...
Thanks again for your help.


