Replace Double Line-Breaks with Paragraph Break

My imported text has double line breaks between paragraphs instead of a single paragraph break:

  1. Is that going to cause problems down the road (formatting for Kindle)?

  2. If so, is there any way to search and replace those in Scrivener?

Thanks,

Al

Someone will hopefully have a shorter/simpler/better answer than mine, but here goes…

Appears this is currently supported in the Mac version but not the Windows version. (Windows version will presumably be updated to v2 or approximate parity with Mac version sometime this year.)

See Gwen Hernandez’s (Scrivener for Dummies) workaround, which may prove relevant…
gwenhernandez.com/2013/03/12/tec … scrivener/

If you are still at a point where is practical to do this before importing into Scrivener, options may include:

  • Saving/exporting original material in different format via originating software material was created in… and/or…
  • Using a robust text editor to find/replace those double breaks with single breaks.

Some such editors (and word processors) support the use of plain text equivalents for various code… /r, /n, … or ^p, etc… which is perhaps a bit easier… but may not be able to handle all invisible characters.
Some support the use of hexadecimal codes, which means being able to deal with any arbitrary characters.

Such robust text editors might include:

  • NotePad++. Free. Has this general capability, assuming the break characters are standard ones it is set up to handle. Haven’t used it enough to be familiar with how to do it.
    notepad-plus-plus.org/

  • Ultraedit. Free time limited eval available. Definitely has this general capability, regardless of what the characters are. (It can probably even do this against a group of selected files at once… but don’t know that would be safe to do this against all text .RFT files in a Scrivener project. Could always spin off a copy of a Scrivener project, so could experiment on it (and possibly crash and burn) without risking the original project.)
    ultraedit.com/
    Proof of concept steps in UltraEdit:

  • File > Open file needing this change

  • Edit > HEX Functions > Hex Edit
    This will show the file in a two column format, hexadecimal representation to the left, text and invisible character indicators to the right.

  • Select the string of line/paragraph break characters that are to be replaced (in either left/hex or right/regular text side)

  • Make a note as to what the hex codes for the characters are.
    Ex: 0D 0A 0D 0A
    (for some reason, doesn’t support copy/pasting the hex characters into following find or search)

  • To verify this will work, Search > Find and enter those hex characters and click Find Next

  • Assuming that works, Search > Replace,
    verify that the “Find what:” field contains those search characters,
    supply replacement hex characters (ex: 0D 0A) in “Replace with:” field,
    click Replace or Replace All
    Note: The Search > Replace In Files presumably can do the same against an entire set of selected files. Useful, but caution is in order.

There are probably other useful tools/filters, out there for dealing with this…

Hope something in the above is of assistance.

Thanks, Springfield, that’s the info I was looking for.

I would indeed lose too much work if I reimported from the original rtf file.

At this point I have my project divided up in to over 40 chapters, so compiling, fixing, and then reimporting and fixing up all the chapter titles, etc, would be a big deal.

I might consider exporting a chapter at a time, fixing and reimporting.

But an important question, then, is: Can I live with the double linebreaks? Will I experience any problems further down the road?

As far as problems further down the road… I don’t know, but would guess quite possible (paragraph spacing issues). Preliminary way to find out would be to go ahead and do some preliminary compiles, perhaps of just a single chapter, to various formats, view each format in its appropriate reader/viewer and see. It is worth getting familiar with how to do limited proof-of-concept tests/experiments like this on a routine basis. Saves a lot of grief in terms of not getting too far down the road before discovering serious issues.

As I mentioned, could certainly try doing this to one or all the rtf files in the project via UltraEdit… but be sure to make a copy of the project under a different name and test against the copy, not the original, to be safe.

If you have done anything beyond bold, italics, or underlining, then editing the RTF files located within the .scriv folders can really screw you up. Footnotes, for instance, can relocate to some other part of your text. Avoid that at all costs.

I would really recommend that you do a compile, fix (a quick search and replace can do the fix in a matter of seconds in Word or other editors), and then import that text. Move the imported text to somwhere separate from what you’re working on, then split it according to your current divisions (chapters, scenes, sections, etc…).

You can then take your time replacing each of the original binder documents with the fixed text. You should be able to snapshot the original (just in case), and then copy & paste the fixed version of the same document, which will preserve all the other metadata (synopsis, document notes, keywords, and so forth).