VideosIntroducing the Apply All Default Quick Fix Proposals Tool

Overview

Duration: 06:59

This video demonstrates various ways that you can use the "Apply All Default Quick Fix Proposals" tool to apply quick fix proposals for all reported validation errors detected in a single document or to apply them to a batch of multiple documents (for example, all files within a project or a DITA map).

Transcript

00:00:05this video demonstrates various ways to
00:00:07access and use the apply all default
00:00:09Quick Fix proposals tool it can be used
00:00:12to apply Quick Fix proposals for all
00:00:14reported validation errors in a single
00:00:16document or a batch of multiple
00:00:18documents when one or more quick fix
00:00:20proposals are detected for the reported
00:00:22validation errors and you can even
00:00:24preview the proposed modifications prior
00:00:26to processing them for the purposes of
00:00:29this video we're using a sample data
00:00:31project that contains various topics
00:00:33with information about the functionality
00:00:35of a technical product this project is
00:00:38configured so that in addition to the
00:00:39documents being validated using the
00:00:41default validation engines for daa it
00:00:44also factors in some additional rules
00:00:46that are implemented in a custom
00:00:47schematron document that you see here
00:00:50throughout the video you'll see many of
00:00:52the rules that are imposed by this
00:00:53schematron
00:00:54document I'll scroll down and focus on
00:00:57one example of a rule defined here that
00:00:59tests the protocol for links to ensure
00:01:01that https is used instead of
00:01:05HTTP and I'll select the next line in
00:01:08the outline view to highlight the Quick
00:01:09Fix definition for this rule it replaces
00:01:12any HTTP instance with
00:01:16https now I'll expand the topics folder
00:01:19and open one of the documents to start
00:01:21demonstrating the
00:01:22feature this is one of several documents
00:01:25that have been contributed to the
00:01:26project by various collaborators and you
00:01:28can see that it has some valid ation
00:01:30problems fortunately oxidon provides a
00:01:33quick fix mechanism for automatically
00:01:35correcting the problems based on Quick
00:01:37Fix proposals associated with
00:01:39them I place the cursor in the title
00:01:42where I see the first validation problem
00:01:45then I'll click the light bulb icon that
00:01:47appears in the left stripe there's two
00:01:49quick fix proposals for this location in
00:01:51the document the first one proposes
00:01:54adding a prologue to the topic and the
00:01:57second one will change the topic ID to
00:01:59match the file
00:02:00name in addition to those two issues the
00:02:03document has other problems and as long
00:02:05as a quick fix is available for them I
00:02:07can apply the fix for all reported
00:02:09errors within the document by using the
00:02:11apply all default Quick Fix proposals
00:02:13action it opens a preview dialog box
00:02:16that shows a comparison between the
00:02:18current document and a version with the
00:02:20proposed changes that would result from
00:02:22applying the Quick Fix
00:02:24proposals you can see that there are
00:02:26four quick fixes that were
00:02:28applied I can click on the colored
00:02:30marker in the right vertical stripe to
00:02:32navigate to a proposed change the first
00:02:35one will replace the topic ID to match
00:02:38the file name I can also use the next
00:02:40change button to navigate to the next
00:02:43issue this one adds the
00:02:45prologue and I can continue so that I
00:02:48review each proposal to make sure I
00:02:51agree this third one adds a missing
00:02:53output class attribute to a code block
00:03:03and if I look at the fourth one it is
00:03:05proposing to add an alternate text to an
00:03:08image and I agree with the proposal so
00:03:10I'll click the apply
00:03:13button and you can see that the fixes
00:03:15have been successfully applied and the
00:03:17validation of the document is now
00:03:19successful now I'm going to undo the
00:03:21changes to continue the demonstration
00:03:24I'm going to switch to text mode and
00:03:26click the light bulb icon for the first
00:03:27issue to show that the same quick fix
00:03:29functionality is also available in text
00:03:33mode now I'll switch back to author mode
00:03:36to show you other ways to access the
00:03:38tool instead of clicking the light bulb
00:03:40icon I can just rightclick within the
00:03:42problem and the apply all default Quick
00:03:45Fix proposals action is there in the
00:03:47contextual
00:03:48menu it is also accessible from the
00:03:51tools
00:03:52menu in this case the resulting dialogue
00:03:55box includes a scope section where I can
00:03:57choose which resources the quick fixes
00:03:59will be applied to I could choose to
00:04:01apply them over the whole project or
00:04:03selected project resources all opened
00:04:06files and more for my purposes the
00:04:09current file would be appropriate
00:04:12there's also an include files option in
00:04:14the filters section where you can use
00:04:15patterns to tweak the selection of
00:04:17resources for example to limit it to
00:04:20certain file
00:04:22types now we'll exemplify it on a batch
00:04:24of multiple
00:04:26documents in the project view I'll
00:04:28rightclick the topics fold folder and
00:04:31I'm going to process a validation to see
00:04:33if there are any errors in any of the
00:04:34topics that were contributed by
00:04:36collaborators you can see that there are
00:04:39a total of nine problems and three files
00:04:41that contain the
00:04:43problems I'm going to rightclick the
00:04:45first problem and there's an apply all
00:04:47default Quick Fix proposals in all files
00:04:49action in this
00:04:51case it opens the preview comparison
00:04:54dialogue box that we're familiar with
00:04:56since this is for multiple files all the
00:04:58files are listed in the top box I can
00:05:01select one of them there to shift the
00:05:03focus to that
00:05:04file again I can navigate through and
00:05:06review each proposal once I reach the
00:05:09end of that document it asks if I want
00:05:11to continue to the next
00:05:14file so it's very easy to navigate
00:05:17through all the proposals one by one if
00:05:19you want
00:05:21to I'll cancel that and continue
00:05:30back in the project view I'll rightclick
00:05:32the topics folder again this time I'll
00:05:34go to
00:05:35refactoring and you see that the action
00:05:38is also available there in this case it
00:05:41automatically chose selected project
00:05:43resources for the
00:05:44scope I'll cancel this and
00:05:49continue now I'll open the Project's
00:05:51datam map in the datam maps
00:05:54manager I'll rightclick the root map and
00:05:57go to refactoring
00:05:59and I'll select the apply all default
00:06:01Quick Fix proposals action from there
00:06:04notice that in this case it
00:06:06automatically chose current data map
00:06:08hierarchy for the scope I'll click
00:06:13preview and I'll go ahead and
00:06:16apply and you can see that the current
00:06:18data topic was automatically updated and
00:06:20is now valid that should also be the
00:06:23case for the other two documents that
00:06:25had reported problems to test that we
00:06:27can run a validate and check for complet
00:06:29operation on the DAT
00:06:31map notice that I've specified my custom
00:06:34rules document in the additional
00:06:36schematron checks filled so it will
00:06:38check for those rules in addition to the
00:06:41others and the validation was successful
00:06:44so applying all the quickfix proposal
00:06:46solved all the issues and all of the
00:06:48documents and the data map is now
00:06:51valid that concludes the demonstration
00:06:54thank you for watching

Use Oxygen Feedback to ask us anything about this video.