Timed to coincide with MadWorld Dublin, MadCap released in October 2019 an update to Flare called 2019r2. Although it is not a full new version, this release includes a surprising number of interesting changes and new features, including the ability to import Confluence pages, and a new way of making content responsive by including or excluding conditions based on media type. For me, however, one of most useful new additions is support for dragging and dropping (or copying or pasting) files from Windows into the Flare UI, and this is the feature on which I will be focusing in this article.
What is drag-and-drop?
In case you've just arrived from a different planet, drag-and-drop is a term used universally within IT applications for the action of dragging an item (by touch or by using a mouse) from one part of the screen to another in order to complete an operation such as moving a file into a different folder. Support for drag-and-drop often makes applications quicker and more intuitive to use.
Pre-existing drag-and-drop in Flare
Even prior to the 2019r2 release, it has been possible to do a wide range of useful tasks within Flare using drag-and-drop. Examples of some of my favourite drag-and-drop actions in Flare are:
- Drag a topic from the Content Explorer into the TOC Editor to create a new TOC item with an automatically updating label (which uses the LinkedTitle system variable)
- Drag a topic from the Content Explorer or TOC Editor into the XML (Topic Editor) to insert a cross-reference to that topic
- Drag an image or snippet from the Content Explorer into the XML (Topic Editor) to insert that item
- Within the two-pane (Show Files) view of the Content Explorer, drag a group of topics (selected using Ctrl+click or Shift+click) to a new folder location
- Drag a topic from the "Not in selected TOC" report into the TOC Editor to create a new TOC item linked to that topic (note that the resulting TOC item label contains static text)
New drag-and-drop in Flare 2019r2
You can now drag files from Windows File Explorer into an appropriate location within the Flare interface. For example: you can drag document files (htm, docx, pdf, etc), images, and snippets into any folder within the Content Explorer. You can also drag Flare project files such as skins, page layouts, and targets into the corresponding folders within the Project Organizer. Flare will not allow you to drag-and-drop a file to an invalid locationfor example, you could not drag and drop a skin file into the Content Explorer, or indeed into any folder within the Project Organizer except the Skins folder.
When you drag in content files (such as topics or page layouts) that contain references to other files, you run the risk of these references being broken. Fortunately, as you'll see in the next section, there is a way to get around this issue if you import topics from folders in other projects by drag-and-drop.
Importing documents by drag-and-drop
There are certain types of document that can be imported into Flare. During the import process, Flare converts the content from the original document format into valid Flare topics (in XHTML format). Document types that you can import in this way include Microsoft Word documents, FrameMaker books or chapters, and HTML pages.
If you drag-and-drop any of these document types into Flare, you are now offered the choice of either importing or copying the document.
Choosing the second of these options results in the document being copied into the project in its original format. Choosing the first option results in the import process starting, with a new Import file of the corresponding type being created. On completion of the import process, a new set of topics (using the content of the original document) is added to the project.
If are dragging in topic files from a folder in another project, choosing the Import option avoids the issue of broken references that was described in the last section. This is because the import process includes the option to import dependant resources such as images or style sheets (see screenshot below).
In my opinion, this new support for drag-and-drop is particularly welcome as it provides a more intuitive and easier way of starting the process of importing Word documents. Incidentally, the interface for selecting the various import options during the Word Import process has changed quite significantly in Flare 2019r2, and Flare now does a better job of converting multi-level lists. I will cover the improved Word Import in detail in a future article.
Training and Consulting in MadCap Flare