Submitted by jimspoon on 2019/07/03 02:26
It's useful to be able to view the contents of plain text files in the document pane.  I *think* the following is accurate - would appreciate corrections - 
 
If you use File > Import From > Text File(s), the path to the plain text file will be stored in the FilePath and FileName fields; the name of the file will be stored in the Item field.  A copy of the file contents will be stored in the ItemHTML field (for embedded storage), or the file referenced in the ItemHTMLFile field.  You can edit the original external plain text file in an external editor by double-clicking on the Item.   You can edit IQ's copy of the content in the document pane.  The resulting content of the copy will be HTML, not plain text.  In this case you've just got to be aware that you're working with two separate versions of the same content, and changing one will not change the other.
 
If you drag and drop the text file to IQ, and select the "No Hyperlink" and "Doc Pane" options, the path to the plain text file will be stored in the ItemHTMLFile field.  The text of the external plain text file will appear in the document pane.  I thought that if I edited the plain text file in the document pane, that it would be converted to an HTML document, i.e. HTML tags etc would be inserted.  But I have discovered that this does not happen!  Text can be added or deleted, the file can be saved, the changes are there, and it remains plain text.  If I try to insert some formatting, like making some text bold, and try to save the changes by pressing Ctrl+S, or clicking the Save button, that change is simply lost.  But the good news is that we can display external plain text files in the document pane, and edit it them there, without concern that they might be accidentally converted to HTML files.
 

Comments

I was just thinking about this and happened upon my earlier question about IQ's support for plain text as a supported file type in the Document Pane.  Did I have it right?  If so, it seems that plain text files are indeed a supported file type for the Document Pane.  I also see that if I use File > New in the Document Pane menu, I can replace the plain text file in the document pane with an HTML file, with the plain text file content copied into the new HTML file.  But it doesn't seem that an HTML file in the doc pane could be swapped for a plain text version, as there is no File > New > New Text File option in the Doc Pane File menu.

Hi Jim,

You're correct that if the Doc pane is showing an external file, the save command will look at the file extension and if it looks like a plain text file, it will save the text version, not the marked up version.

This is most likely not documented... :-(

There really isn't much missing to add full plain text format support