You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@corinthia.apache.org by pm...@apache.org on 2015/08/07 20:23:06 UTC

incubator-corinthia git commit: Update dfconvert instructions

Repository: incubator-corinthia
Updated Branches:
  refs/heads/Release_0.1 3afe8f659 -> 6c4ed492e


Update dfconvert instructions


Project: http://git-wip-us.apache.org/repos/asf/incubator-corinthia/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-corinthia/commit/6c4ed492
Tree: http://git-wip-us.apache.org/repos/asf/incubator-corinthia/tree/6c4ed492
Diff: http://git-wip-us.apache.org/repos/asf/incubator-corinthia/diff/6c4ed492

Branch: refs/heads/Release_0.1
Commit: 6c4ed492e78589019cd9ff53fcef3023106c592c
Parents: 3afe8f6
Author: Peter Kelly <pe...@uxproductivity.com>
Authored: Sat Aug 8 01:22:56 2015 +0700
Committer: Peter Kelly <pe...@uxproductivity.com>
Committed: Sat Aug 8 01:22:56 2015 +0700

----------------------------------------------------------------------
 README.md | 33 ++++++++++++++++++++-------------
 1 file changed, 20 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-corinthia/blob/6c4ed492/README.md
----------------------------------------------------------------------
diff --git a/README.md b/README.md
index 15ea706..85022f7 100644
--- a/README.md
+++ b/README.md
@@ -67,19 +67,26 @@ There are three major components, in their respective directories:
 * `dfconvert` - driver program for performing conversions
 * `dftest` - test harness
 
-Run dfutil without any command-line arguments to see a list of operations.
-Here is an example of converting a .docx file to HTML, modifying it, and then
-updating the original .docx. Note that it is important, due to how internal
-mapping works, that the .docx file being written is the same file as the
-original; using a new file won't work.
-
-    dfutil filename.docx filename.html
-    vi filename.html # Make some changes
-    dfutil filename.html filename.docx
-
-If you examine the convertFile function in `dfutil/Commands.c`, you will see
-the main entry points to perform these conversions, which you can call from
-your own program.
+Run dfconvert without any command-line arguments to see a list of possible
+operations. The following is an example of converting a .docx file to HTML,
+modifying it, and then updating the original .docx file based on the modified
+HTML file. Any content or formatting information that could not be converted to
+HTML (e.g.  embedded spreadsheets) will be left untouched.
+
+    dfconvert get report.docx report.html
+    vi report.html # Make some changes
+    dfconvert put report.docx report.html
+
+Note that when executing a put operation to update the document, the .docx file
+must be identical to that from which the HTML file was originally generated.
+This is because of assumptions the update process relies on about the
+relationship between elements in the HTML file and their counterparts in the
+.docx file. If you have modified the .docx file between get and put, or execute
+a put on the same file twice, this will be automatically detected and an error
+will be reported.
+
+Look at `consumers/dfconvert/src/main.c` to see how to use the API. The public
+API headers are in the `DocFormats/api/headers/DocFormats` directory.
 
 # Platforms and dependencies