WebODF Jos van den Oever Sponsored by:. Overview  How to use WebODF on your website  How WebODF came to be  ODF and how to put it in HTML  Writing.

Slides:



Advertisements
Similar presentations
JQUERY/AJAX ALIREZA KHATAMIAN DELARAM YAZDANSEPAS.
Advertisements

ASP Tutorial. What is ASP? ASP (Active Server Pages) is a Microsoft technology that enables you to make dynamic and interactive web pages. –ASP usually.
Alon Blich A.B.C.  Printer Languages (Escape Codes) ◦ PCL, PostScript, Canon etc.  ActiveX/OLE Automation Server  PDF Utilities ◦ PDFInclude, PDFlib.
Tutorial 11 Creating XML Document
Chapter 14 Introduction to HTML
WHAT IS PHP PHP is an HTML-embedded scripting language primarily used for dynamic Web applications.
XML on the Web: is it still relevant? O'Neil D. Delpratt.
Web Services & Widgets Godmar Back. Mash-Ups Applications that combine information from different sources in one web page Different architectural choices.
Overview of HTML. Three Different Approaches  Text editor like Notepad  HTML editor such as: –KompoZer –DreamWeaver –Microsoft Expression Web –iWeb.
Presented by…. Group 2 1. Programming language 2Introduction.
 Using Microsoft Expression Web you can: › Create Web pages and Web sites › Set what you site will look like as you design it › Add text, images, multimedia.
INTRODUCTION TO WEB DATABASE PROGRAMMING
Computer Concepts 2014 Chapter 7 The Web and .
M. Taimoor Khan * Java Server Pages (JSP) is a server-side programming technology that enables the creation of dynamic,
JavaScript & jQuery the missing manual Chapter 11
Philly.NET Hands-on Labs JAVASCRIPT SERIES. July 9: JavaScript Syntax Visual Studio ◦Projects ◦Editors ◦Debugging ◦Script blocks ◦Minification and bundling.
Mobile App Support Jacob Poirier Geri Hengesbach Andrea Menke Erin Rossell.
GIS technologies and Web Mapping Services
ASP.NET + Ajax Jesper Tørresø ITNET2 F08. Ajax Ajax (Asynchronous JavaScript and XML) A group of interrelated web development techniques used for creating.
Copyright© Jeffrey Jongko, Ateneo de Manila University Android.
CNIT 133 Interactive Web Pags – JavaScript and AJAX JavaScript Environment.
Overview of HTML/XHTML Two Different Approaches  Text editor like Notepad  HTML editor such as: –KompoZer –DreamWeaver –Microsoft Expression Web –iWeb.
NOTE: To change the image on this slide, select the picture and delete it. Then click the Pictures icon in the placeholder to insert your own image. WEB.
به نام خدا تنظیم کننده : فرانه حدادی استاد : مهندس زمانیان تابستان 92.
CHAPTER TWO INTRODUCTION TO VISUAL BASIC © Prepared By: Razif Razali 1.
Session: 1. © Aptech Ltd. 2Introduction to the Web / Session 1  Explain the evolution of HTML  Explain the page structure used by HTML  List the drawbacks.
INTRODUCTION TO CSS. TOPICS TO BE DISCUSSED……….  Introduction Introduction  Features of CSS Features of CSS  Creating Style Sheet Creating Style Sheet.
PERFORMANCE ENHANCEMENT IN ASP.NET By Hassan Tariq Session #1.
ASP. ASP is a powerful tool for making dynamic and interactive Web pages An ASP file can contain text, HTML tags and scripts. Scripts in an ASP file are.
| Basel Building real Business Apps with Office365/Azure Gilbert Nicolet – BPA Solutions SA.
Introduction to JavaScript MIS 3502, Spring 2016 Jeremy Shafer Department of MIS Fox School of Business Temple University 2/2/2016.
Leveraging Web Content Management in SharePoint 2013 Christina Wheeler.
丁建文 國立高雄應用科大資管系副教授 兼任計網中心軟體發展組組長 跨平台行動應用軟體開發技術 : HTML5 & Mobile JavaScript Framework 暨南大學.
1 Using jQuery JavaScript & jQuery the missing manual (Second Edition)
CSCI 3100 Tutorial 5 JavaScript & Ajax Jichuan Zeng Department of Computer Science and Engineering The Chinese University of Hong.
WebODF online and offline office Jos van den Oever Sponsored by:
Improving ODF applications by sharing ODF tests Svante Schubert Software Engineer Sun Microsystems Inc.
WebODF Jos van den Oever WebODF online and offline office.
WebODF Jos van den Oever WebODF online and offline office.
Mapping ODF to HTML WebODF online and offline office.
ODFKit and WebODF Getting up to speed ● ODF ● ODFKit ● WebODF Discussion and brainstorming ● How would you use it? ● Office use-cases in 2010 and beyond.

WebODF online and offline office Jos van den Oever Sponsored by:
Introducing the Microsoft® .NET Framework
JQuery Fundamentals Introduction Tutorial Videos
Web Technologies Computing Science Thompson Rivers University
Top 8 Best Programming Languages To Learn
Node.Js Server Side Javascript
ODFAutoTests Jos van den Oever.
Suggestions for the next ODF version WebODF
ODF Community Site Jos van den Oever Logius
Collaborative Editing on ODF Documents
Process of Converting “PSD to HTML”
Application with Cross-Platform GUI
Users: Suite of Office and Graphics applications
Node.Js Server Side Javascript
Programming vs. Packaged
JQuery with ASP.NET.
Modern web applications
MIS JavaScript and API Workshop (Part 3)
Introduction to AJAX and JSON
Eagle: Maturation and Evolution
Web Development 101 Workshop
Web Technologies Computing Science Thompson Rivers University
Introduction to AJAX and JSON
Ajax and JSON Jeremy Shafer Department of MIS Fox School of Business
CNIT 133 Interactive Web Pags – JavaScript and AJAX
Ajax and JSON Jeremy Shafer Department of MIS Fox School of Business
Running C# in the browser
How to debug a website using IE F12 tools
Presentation transcript:

WebODF Jos van den Oever Sponsored by:

Overview  How to use WebODF on your website  How WebODF came to be  ODF and how to put it in HTML  Writing JavaScript for WebODF  How to use WebODF in your program

The goal of WebODF A JavaScript/HTML5 library that makes it easy to:  Add ODF support to your (mobile) application  Add ODF support to your website on your server

How to use WebODF

Requirements for WebODF Check out the git repository:   Comes with an HTTP server for Node.JS

WebODF on your website Take your own HTTP server or use httpserver.js ● odf.html ● defaultodfstyle.css ● odf.js ● lib/runtime.js ● lib/core/... ● lib/odf/Style2CSS.js ● lib/odf/OdfContainer.js

Put the ODF files on the same server /odf.html /docs/myreport.odt /docs/incometax.ods /docs/fosdem.odp Go to the url:

How WebODF came to be

WebKit  KHTML starts life as browser in the KDE community  Apple forks KHTML to make Safari  Apple starts the WebKit project  WebKit gains more 'ports' that lead to Chrome, GtkWebKit, QtWebKit and more  Nearly every computer has WebKit ➛➛

WebKit ports

ODFKit  Most FOSS Office Software is written in C++  But libraries used are different (LibreOffice/..., Calligra/Qt, Abiword/Gtk)  ODFKit: use the WebKit port approach to get office suites to use the same codebase  Initial scope: server side handling of ODF documents Side-effect of writing JavaScript unit tests: observation that browsers could handle most of ODF

ODF and how to put it in HTML

What is nice about ODF - Reuses many technologies: XML, ZIP, URL, XSL-FO, RDF, SVG, XQuery, … - It is an active open standard with people from many implementations in the Technical Committee - There are quite a few implementations Calligra

How does WebODF work?  Start with an HTML file  Load the binary ZIP file from the server  Load content.xml, settings.xml etc into the HTML DOM  Use CSS with namespaces to hide and show important bits  Convert the ODF styles to CSS  Load images

Putting the ZIP into the DOM  Most ODF files are ZIP files containing XML files and pictures  HTML has one DOM, which is implied to be one XML file  ODF has a different 'serialization' which is a single XML file  No program really uses the XML only, form, but it is useful for mapping the ZIP to the DOM

The ZIP contains: content.xml, styles.xml, settings.xml, meta.xml

Converting ODF styles to CSS  ODF uses its own styling derived from XSL-FO  CSS is what you need in HTML  Two issues: ● ODF uses style names but CSS uses selectors ● ODF has different styling properties than CSS

Style names versus CSS selectors styles.xml: odf.html: text|p[text|style-name=”mybold”] { font-weight: bold; }

WebODF: no conversion, just ODF.

Writing JavaScript for WebODF

JavaScript practices  Use the good parts of JavaScript  Use JSLint  Runtime abstraction  Use callbacks  'Compile' JavaScript with Closure Compiler  Use unit tests and code coverage

JavaScript: The Good Parts  Book by Douglas Crockford, inventor of JSON  Thin but powerful book  JavaScript is a language you have to learn.  It contains many features you should avoid, but also many nice ones  Lots of good advice Use JSLint!

Runtime  WebODF will run in different JavaScript environments  Only common thing is the presence of JavaScript with optional DOM  Runtime is thin abstraction that provides class loading, access to file system, logging, timers, 'window' object  There are base runtimes for the browser, Node.JS and Rhino

Use callbacks  IO is often the bottleneck in application speed  Instead of waiting for an event that might be slow, pass a callback function

JavaScript unit testing Write tests that work in multiple runtimes: - all targeted browsers - Node.JS - Rhino 'Instrument' the JavaScript with JSCoverage - see how often each line of code was run during testing -

Node.JS  When developing, it is nice to run unit tests from the command line  JavaScript runtime that uses V8 engine from Chrome  Like WebODF, uses callbacks extensively, to avoid waiting for IO

Rhino  JavaScript engine that does not use callbacks a lot IO  Nice contrast compared to Node.JS: catch more edge cases where problems might occur QtWebKit  Used in small unit test executable  WebKit on the command-line  Unit test with DOM

Closure Compiler  Combine all JavaScript files into one file  Syntax checking  Type checking (JavaScript has loose typing)  Optimization

How to use WebODF in your program

WebODF on Android Override some functions in the runtime.

Current activities  Improving the rendering  Making an API for controlling the ODF canvas  Write support with limited editing What you can do:  Become creative!

WebODF Open Document Format is great The community for ODF active WebODF can bring ODF to websites and devices WebODF keeps your ODF intact WebODF makes ODF easy and fun

Thank you!

Document compatibility Some file formats:  Text files  s  HTML  Microsoft Office (Binary and OOXML)  ODF

Office documents  Used to closed binary files Only really works well within one version of Microsoft Office  ODF came along and OOXML followed There are many ODF editors and Plugfests are held to improve interoperability

HTML ODF

OdfContainer  JavaScript class that combines the XML files  WebODF parses the ZIP file and puts all XML in one DOM  Non-XML objects are called Parts and are seen as blobs.