[sword-devel] The poor man's interlinear

David Haslam dfhmch at googlemail.com
Fri Sep 7 00:34:56 MST 2012


/One my friends recently asked:/

Do you know of any program that will load two text files (plain text or Word
files) and display them interlinearly?

/Here's my reply:/

Not off hand, but here's an easy workaround using Excel.

First create a double-space copy of each text file. i.e. Replace all EOLs by
two EOLs.
e.g. Using Notepad++ replace \r\n by \r\n\r\n for a Windows styled text
file.

For the second file, insert an extra blank line at the top of the second
file, so this file has its text on even numbered lines.

Paste the contents for each double-spaced text file into a separate Excel
worksheet.

In another worksheet, use a formula in cell A1 to select accordingly. The
formula is

=IF(ISODD(ROW()),Sheet1!A1,Sheet2!A1)

where I've not renamed the worksheets.

Copy cell A1 to as many rows as you need.

Simples!

The whole operation could be achieved by a more complex formula without the
prior need to convert the files to double-space.
I considered this at first, but came to the conclusion that simplicity is
preferable.

The method I described could be extended to cope with three (or more) files,
using the MOD function instead of the ISODD function. 
i.e. By first making a triple-spaced copy of each file.

David

PS. I'd resist doing it for Word files, unless they are first converted to
Unicode text files.



--
View this message in context: http://sword-dev.350566.n4.nabble.com/The-poor-man-s-interlinear-tp4650950.html
Sent from the SWORD Dev mailing list archive at Nabble.com.



More information about the sword-devel mailing list