view nodejs/README @ 657:32d0eef1ee46

Force type-casting for member variables. For some member that need a casting for the type is that what we want. For example, casting a void * type to a struct pointer type. This force will skip type checking, but it works for the variables with a generic type and we want to specialize its type.
author Thinker K.F. Li <thinker@branda.to>
date Sat, 31 Jul 2010 14:37:19 +0800
parents d45c928f6523
children 8f49e0235097
line wrap: on
line source

svg.js: 
===============

The sample code to load an SVG file. It requires the libxml, which is available at http://github.com/polotek/libxmljs/tree/refactor.
Please copy the libxmljs.node to the objs/default if you want to test the libxml+mbfly without installing them into the system. The
path can be defined by the NODE_PATH environment variable.

(1) Compile MadButterfly with nodejs support
 ~user/MadButterfly$ ./configure --enable-nodejs; make

(2) Compile libxml
 ~user/MadButterfly/nodejs$ git clone http://github.com/polotek/libxmljs.git
 ~user/MadButterfly/nodejs$ cd libxml; make

(3) Copy the libxml.node to the nodejs build directory
 ~user/MadButterfly/nodejs$ cp libxml/libxml.node objs/default
(4) Set the path
 ~user/MadButterfly/nodejs$ export NODE_PATH=objs/default

(5) Execute svg.js
 ~user/MadButterfly/nodejs$ node svg.js