Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Niklas Nebel Sun Microsystems NEW FEATURES IN CALC 3.0 1.

Similar presentations


Presentation on theme: "1 Niklas Nebel Sun Microsystems NEW FEATURES IN CALC 3.0 1."— Presentation transcript:

1 1 Niklas Nebel Sun Microsystems NEW FEATURES IN CALC 3.0 1

2 2 Agenda Implementation notes > Implementation of the ODF Formula specification > Excel 2007 import > Collaboration through shared files > Optimization solver > Usability improvements Demonstration

3 3 OpenDocument Formula

4 4 ODFF: Specification Subcommittee of OpenDocument TC Specification in draft state Formula syntax > File format syntax, not user's view > of:=SUM([.A1:.A3]) Processing model > Cell ranges, arrays, … Function descriptions

5 5 ODFF: Changes Different function names in file format > WEEKNUM → ISOWEEKNUM > User-visible name still the same Changes in function parameters > ADDRESS( row; column; ABS; A1; sheet ) New XML namespace for formulas > Abbreviated “of:” instead of “oooc:”

6 6 ODFF: Compatibility OOo 3.0 reads both variants > Parsing behavior depends on namespace 2.0.1 and above handle unknown namespaces > Parse as oooc → only compatible functions handled New option to save in ODF 1.0/1.1 > Load/Save – General – ODF format version

7 7 Excel 2007 Import

8 8 Excel 2007: Common Infrastructure “oox” module contains Excel and PowerPoint filters Shared code between filters: Package handling Parser wrapper with new interface > com.sun.star.xml.sax.FastParser Meta data Drawing objects

9 9 Excel 2007: Implementation Not part of “sc” module, not linked against it > Uses UNO API calls > API had to be extended Chart import separate Extensible > Plan: Merge with xls import

10 10 Excel 2007: Formulas Formulas stored as text in Excel 2007 files com.sun.star.sheet.FormulaParser UNO service > Parse string into sequence of formula tokens > Mapping of names to OpCodes configurable Import-specific processing of token array > Parameter handling Interface XFormulaTokens: set cell's formula New APIs not “published” yet

11 11 Collaboration

12 12 Collaboration: Introduction Several users want to modify the same file > Not wait until nobody else is editing Issue 8811 has 144 votes Lightweight solution without special server

13 13 Collaboration: Change Tracking Existing feature since first OOo version > Edit – Changes – Record Only cell content (not attributes / drawing layer) Recorded changes can be merged > Changes from another file are added to the end > Changes are adjusted for inserted rows, etc. > “Offline collaboration”

14 14 Collaboration: Implementation Use of tracked changes Non-tracked changes: Overwrite > Disable drawing layer changes Consistent order of tracked changes needed > Append own changes at end when saving > But: Local copy already has own changes To use existing merge functionality: > Undo own changes > Merge others' changes > Merge own changes

15 15 Optimization Solver

16 16 Solver: Introduction Find a set of input values to optimize a result Front-end to optimization problems > Important sub-class: Linear optimization Solver seen as a core feature > Expected to be part of a spreadsheet application Should be extensible > Allow choice of implementation for different problems

17 17 Solver: Dialog & Framework One dialog, part of “sc” module > Seamless integration of cell reference input > Input of constraints without use of sub-dialog Solver implementation called through UNO service > com.sun.star.sheet.Solver Selection of implementation in options dialog

18 18 Solver: Linear Implementation Component written in C++ Uses lp_solve C library Linear coefficients determined once at the start No call-backs needed Total: 700 lines

19 19 Solver: Future Implementations Example: Nelder-Mead (Apache Commons Math) > Cost function (call-back) below private class SolverCostFunction implements CostFunction { public double cost(double[] x) throws CostException { int dimensions = m_variables.length; for (int i=0; i<dimensions; ++i) m_varCells[i].setValue( x[i] ); if (m_objCell.getError() != 0) throw new CostException(new RuntimeException()); return m_objCell.getValue() * ( m_maximize ? -1.0 : 1.0 ); }

20 20 Usability Improvements

21 21 New Selection Look Use of drawing layer overlays in Calc > First used in OOo 2.2 > Disabled again for performance reasons > Improved version in OOo 2.3 > Same look as before New look in 3.0 > Now seeing benefits of overlays

22 22 Page Margins in Preview In page preview, direct manipulation of > Page margins > Header / footer size > Column widths Result of cooperation with RedFlag 2000

23 23 1024 Columns Column count was always smaller than row count > Fixed-size array of column objects Moderate increase to avoid performance problems Some optimization was needed > Mostly selection handling 2.x was always supposed to deal with such files > Some problems came up (85334, 87128, 93298)

24 24 Demonstration

25 25 57% 20% 15% Q & A Meet the Sun experts here in Beijing. Visit our Sun booth!

26 26 NEW FEATURES IN CALC 3.0 Niklas Nebel niklas.nebel@sun.com 26


Download ppt "1 Niklas Nebel Sun Microsystems NEW FEATURES IN CALC 3.0 1."

Similar presentations


Ads by Google