GithubHelp home page GithubHelp logo

androiddocxtohtml's Introduction

Convert sample.docx to HTML on Android, using docx4j.

When you run it, the app should come up with 2 tabs, one displaying the web page, the other the HTML source.

The docx which is converted is the one in res/raw directory.

If you look at AndroidDocxToHtmlActivity.java you'll see that you can choose to have HTML images saved as files on the device, or based64 encoded as a data URI.  The latter makes the HTML source harder to read, but avoids issues writing to the device (cleanup etc), see  http://dataurl.net/#about 

To run this Eclipse project, you'll probably need to increase your heap space in eclipse.ini (symptom is 'you get Unable to execute dex: Java heap space').  

I used: 
-Xms256m
-Xmx4096m

In Eclipse, Windows > Preferences > General > Show Heap Status gives you an entry on the bottom row which is useful.

Because Android does not support JAXB out of the box, this project contains jars which came from:

    - https://github.com/plutext/jaxb-2_2_5_1/tree/android2
    - https://github.com/plutext/ae-xmlgraphics-commons
    - https://github.com/plutext/ae-awt
    
Note: The set of jars here is the minimal set required for HTML output.  Certain other docx4j features will require additional jars, which are not present in this project.    

androiddocxtohtml's People

Contributors

plutext avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.