Building on top of the MergeView script this proof-of-concept script does:
- Show the outline of a group hierarchy in DT (MVO) and the merged view (MVR) of the contents of each group for md/rtf/rtfd/pdf files.
- All functions of the MergeView script are retained (so the details of MVR will be skipped in this post)
- Both MVO and MVR can be refreshed to show the latest change in the groups/source files.
- Allow user to change the depth of the outline view and perform very basic outline-liked feature such as add or rename group, add a comment to a group, and add notes within the groups directly in the MVO/MVR.
- MVO is portable. If an MVO is moved from one database to another, the user can still refresh/access/edit the group hierarchy and group’s content from within the MVO.
Demo:
- Select a top-level group and invoke the script.
- Only one top group is allowed.
- The interface is almost identical to the Mergeview script.
- A new MVO file is created.
- A and E: The name of the top group and the maximum depth of the outline(group) hierarchy.
- C: link to the group and D: link to the merged view file (MVR) of each group
- B: display the content of each file that is directly under the top group.
Note
- The default location of a newly created MVO is in a group named “MergeView” at current database’s root. The group will be created automatically at the first-time creation of MVO.
- Same as the MergeView script, all groups/notes can be accessed/edited directly[almost].
- Any changes within the main group ( e.g. The user adds new group/smart groups or replicates other groups/files into the main group while working in DT’s viewer window) will be updated and shown in the MVO and its MVRs after a refresh.
- When the MVOutline script is invoked within an MVO/MVR window:
- User can choose the level of the outline. The user wants to reduce the level of the outline to 1 in this example.
- A: refresh the MVO. B: choose other actions.
- The level of outline is reduced to one.
-
If “Other Actions” button is clicked, a list of other actions is shown.
-
A: Select the target group of the action and choose what action to perform. B: for content’s entry. C: Choose the level of the outline to be shown. In this example, the user wants to add a new group with a comment for “Section 1.4” under the group “Chapter 1…”.
Note:
- Obviously, it is more straight forward to add/change the group structure in DT directly. These features are for convenience if only minor group operation is needed.
- Remember to click “Execute Action and Refresh” instead of “Refresh Only” to execute the action.
-
A: “Section 1.4” is created and shown in the MVO. B: now if we click on the link “MV” that is next to “Chapter 1…”
-
A: “MV” is linked to an MVR file (each group will have one MVR hidden from the user). B: is the merged view of files from under “Chapter 1” and all of its sub-groups.
Note:
- the MVR will be an empty file when it is opened for the first time. The user needs to run the script to refresh its content.
- the MVR files are located under a resource group (created at the MVO’s creation) under the “MergeView” group.
- The refresh of MVR file is a bit different. User can choose to refresh the MVR in merged view (MV) or outline format.
Performance consideration: the speed of the script is a function of the number of sub-groups under the main group, the number of files under the groups, and the computer’s configuration. For my computer (pretty well-configured), it takes 10-20 secs to refresh a group with approx. 50 sub-folders and 500 files. However there is no need to wait for the refresh, user can continue to work on other DT’s task and there is a progress bar showing the status of the refresh.
DEMO 2: creating a new project. I’ll let the pictures to speak for themselves:
The script
To run the script:
- You need to download “Dialog Toolkit Plus.scptd” and save it under “/Library/Script Libraries” The download link here Dialog Toolkit Plus .
- I spent a good amount of time in tuning the script’s performance, but there is a limitation in my knowledge and in AppleScript (for now).
Cheers
Script v1b15 updated 2020.05.21
MVGOutlinerV1b15.scpt.zip (319.5 KB)