Skip to content

Commit d12b2fc

Browse files
committed
update documentation
1 parent 1e8bdc4 commit d12b2fc

File tree

5 files changed

+3
-55
lines changed

5 files changed

+3
-55
lines changed

coffee/docxgen.coffee

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -67,12 +67,6 @@ module.exports=class DocxGen
6767
imgManager:imgManager
6868
fileName:fileName
6969
})
70-
###
71-
imgManager=new ImgManager()
72-
setImage: (path,data,options={}) ->
73-
if !options.binary? then options.binary=true
74-
@imgManager.setImage(path,data,options)
75-
###
7670
@setData(fileName,currentFile.applyTags().content)
7771
@filesProcessed++
7872
#When all files have been processed, check if the document is ready

docs/source/configuration.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ https://github.com/Automattic/node-canvas/wiki
111111
Angular Parser
112112
--------------
113113

114-
The name of this option `parser` (function).
114+
The name of this option is `parser` (function).
115115

116116
You can set the angular parser with the following code:
117117

@@ -157,7 +157,7 @@ To use the angular-parser, do the following:
157157
Intelligent LoopTagging
158158
-----------------------
159159

160-
The name of this option `intelligentTagging` (boolean).
160+
The name of this option is `intelligentTagging` (boolean).
161161

162162
When looping over an element, docxtemplater needs to know over which
163163
element you want to loop. By default, it tries to do that intelligently

docs/source/full_doc.rst

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -137,26 +137,6 @@ Docxgen methods
137137
138138
This requires to include Downloadify.js, that needs flash version 10. Have a look at the *output* function if you don't want to depend on it. This function has the advantage that it works regardless of the file size
139139
140-
getImageList()
141-
142-
this gets all images that have one of the following extension: 'gif','jpeg','jpg','emf','png'
143-
Return format: Array of Object:
144-
[{path:string,files:ZipFile Object}]
145-
146-
You should'nt call this method before calling **applyTags()**, because applyTags can modify the images or their path when replacing images with other (particularly when qrCode is set to true, which is not the default case). You can call this method after **applyTags()** without any problems
147-
148-
setImage(path,imgData)
149-
150-
path
151-
Type:"String"
152-
Path of the image, given by getImageList()
153-
imgData
154-
Type:"String"
155-
imgData in txt/plain
156-
157-
This sets the image given by a path and an imgData in txt/plain.
158-
You should'nt call this method before calling **applyTags()**, because applyTags can modify the images or their path when replacing images with other (particularly when qrCode is set to true, which is not the default case). You can call this method after **applyTags()** without any problems
159-
160140
getFullText:([path])
161141
162142
path

docs/source/installation.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ I recommend you to use browserify.
3535
npm install -g gulp jasmine-node uglify-js
3636
npm install
3737
gulp allCoffee
38+
mkdir build -p
3839
browserify -r './js/docxgen.js' > build/docxgen.js
3940
uglifyjs build/docxgen.js > build/docxgen.min.js
4041

docs/source/platform_support.rst

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -17,36 +17,9 @@ Internet explorer is not supported -even IE10- (basically because xhr Requests c
1717

1818
You can test if everything works fine on your browser by using the test runner: http://javascript-ninja.fr/docxgenjs/test/SpecRunner.html
1919

20-
Firefox has an other implementation of the xml parser, that's why all tests don't pass now.
21-
However, all of the functionality works on Firefox too.
22-
The output files are not exactly the same byte wise but the generated XML is correct.
23-
2420
Dependencies
2521
============
2622

2723
1. **docxgen.js** uses [jszip.js](http://stuk.github.io/jszip/) to zip and unzip the docx files
2824

2925
2. Optionally, if you want to be able to name the output files, you can use **Downloadify.js**, which is required to use method download. Be informed that it uses flash, this is why the method is not recommended. This method is howewer useful because a lot of browsers are limited for the download size with the Data-URI method. **Update**: I will probably implement in the future a way to use the FileSaver API, with [FileSaverJS](http://eligrey.com/demos/FileSaver.js/)
30-
31-
3. Optionnaly, if you want to replace images by images situated at a particular URL, you can use QR codes. For example If you store an image at http://website.com/image.png , you should encode the URL in QR-Code format. ![Qr Code Sample](http://qrfree.kaywa.com/?l=1&s=8&d=http%3A%2F%2Fwebsite.com%2Fimage.png "Qrcode Sample to http://website.com/image.png"). You can even use bracket tags in images. http://website.com/image.png?color={color} will take the *Tags[color]* variable to make a dynamic URL. For this too work, you will need [jsqrcode](http://github.com/edi9999/jsqrcode "jsqrcode repositoty forked") and include the following files, in this order (only for browser support, node support already comes out of the box):
32-
33-
34-
.. code-block:: javascript
35-
36-
<script type="text/javascript" src="grid.js"></script>
37-
<script type="text/javascript" src="version.js"></script>
38-
<script type="text/javascript" src="detector.js"></script>
39-
<script type="text/javascript" src="formatinf.js"></script>
40-
<script type="text/javascript" src="errorlevel.js"></script>
41-
<script type="text/javascript" src="bitmat.js"></script>
42-
<script type="text/javascript" src="datablock.js"></script>
43-
<script type="text/javascript" src="bmparser.js"></script>
44-
<script type="text/javascript" src="datamask.js"></script>
45-
<script type="text/javascript" src="rsdecoder.js"></script>
46-
<script type="text/javascript" src="gf256poly.js"></script>
47-
<script type="text/javascript" src="gf256.js"></script>
48-
<script type="text/javascript" src="decoder.js"></script>
49-
<script type="text/javascript" src="qrcode.js"></script>
50-
<script type="text/javascript" src="findpat.js"></script>
51-
<script type="text/javascript" src="alignpat.js"></script>
52-
<script type="text/javascript" src="databr.js"></script>

0 commit comments

Comments
 (0)