firetext
firetext copied to clipboard
.docx support
I found this my microsoft for support on their formats, just download the documentation and you might find something useful. Or decompile and .apk of an android app (i.e. Quickoffice) and look at the java code if it helps. http://msdn.microsoft.com/en-us/library/cc313118%28v=office.1.2%29.aspx
I'm going to create a parser for this for v2
Ok, when we have a significant amount implemented, we can change the milestone.
Note: You probably already know this, but commits for this go to the doc branch (will be merged into the appropriate release branch. Also, files go in resources/doc/.
Thanks!
Ok, here we have a js parser that we can use: https://github.com/stephen-hardy/DOCX.js
Ya, I saw it yesterday, looks perfect :)
Moving this to 0.2
I am working on dropbox right now, anyone want to finish this for me?
Thanks in advance!
Well, this is the last bug. I think we shouldn't delay the release of Firetext anymore, and we already have quite the changelog for 0.2, so if nobody wants to take this I'll move it to 0.3.
Docx files are hard because they are zips, and I have no experience with jszip.
@Logi0 Can you please finish this?
Can you @jackd1 finish this please?
Sure.
:cool:
I've been working on Implementing this, but I can't seem to get it to work, first I had to fix some programming errors in the docx.js code, and then I finally got it to output something, but the docx file wasn't valid.
use another docx file, I uploaded a docx in dp in /Firetext
Ok, that seemed to work, now I have to figure out how to do the opposite and convert html to docx.
There is a default setting or structure that you should use (have it in resources/docx) that you duplicate everytime a user wants to save and currently only support bold, italic, underline and some other basic types that you would insert into the user docx file encoded into Open XML syntax.
Maybe this could help: http://msdn.microsoft.com/en-us/library/office/aa338205(v=office.12).aspx#office2007aboutnewfileformat_developingsolutionsusingtheoffice http://msdn.microsoft.com/en-us/library/cc313153(v=office.12).aspx http://msdn.microsoft.com/en-us/library/gg278327(v=office.14).aspx http://msdn.microsoft.com/en-us/library/cc850833(v=office.14).aspx
@jackd1 how is it going? By when will you finish this?
Actually, I've just implemented fairly simple reading of docx documents, I'll push that right now.
Editing shouldn't be much harder to implement
No, it won't be very hard, I should be able to do that tomorrow, as well as add some more rich text features.
:+1:
:+1: How did you do this, it stumped me!
I wrote a custom class to interpret the document per the iso/iec 29500 spec (downloadable at http://standards.iso.org/ittf/PubliclyAvailableStandards/index.html). The load method loads a document from an ArrayBuffer (calling the constructor with an ArrayBuffer does the same thing). The HTMLout method produces html which can be edited and passed back to the HTMLin method (not yet implemented) which updates the document with the new html. Finally, when finished editing, the generate method generates the docx document. I imagine it was hard to read, it was pretty hard to read the spec :smile:
Nice :)
I finally implemented writing to docx, took a little longer than I thought.
Awesome
We'll enhance this in the future
Ok, I still need to add a default template for creating new documents, also it only supports text right now.
Okay, just add a header, a horizontal line and then a paragraph or user can use blank template
Oh, does this work with Dropbox?