galkahana / hummusrenderrer

NodeJS module for rendering PDF, using a document object/declarative method, using HummusJS
Apache License 2.0
16 stars 5 forks source link

top instead of bottom vertical positioning does not work #4

Closed rsamec closed 9 years ago

rsamec commented 9 years ago

First off I really like your project.

It should be possible to use top instead of bottom when defining a box vertical positioning. I tried it changed at default example at http://pdfrendering.herokuapp.com/, but the text is appeared at the bottom instead of at the top.

{
                    "top": 40,
                    "left": 10,
                    "text": {
                        "text": "hello world",
                        "options": {
                            "fontPath": "./resources/fonts/arial.ttf",
                            "size": 40,
                            "color": "pink"
                        }
                    }
                },
```js
rsamec commented 9 years ago

Sorry, i re-read the documentation and now i see. I can determine the bottom position using bottom= pageHeight - top.