Commit Graph
1855 Commits
Author SHA1 Message Date
Aditya Bhatt b54a00a869 * Rename parseFontSize to parseLength
* Use that for the line height
2013-06-20 11:46:45 +02:00
Aditya Bhatt 06e29d3ff4 Shadow content needs the same text-align: left rule as
office|presentation
2013-06-20 11:46:45 +02:00
Aditya Bhatt 14af210392 Handle null values of line-height 2013-06-20 11:46:45 +02:00
Aditya Bhatt 4e8e109d7c % line-height values in CSS are unreliable. Use a multiplier (1.x) type
% of value in stead of %ages.
2013-06-20 11:46:45 +02:00
Tobias Hintze 9f97589f66 add missing assert to OdfCanvas ctor (missing element) 2013-06-20 10:06:55 +02:00
Jos van den Oever ab71bc130d Fix loading of ODF documents where the first child of <office:body> is not an element. 2013-06-19 22:08:22 +02:00
Jos van den Oever f4aedc8402 Compile fixes. 2013-06-19 18:39:00 +02:00
Philip Peitsch 945c0fbfbf Added support for range deletion using the delete key
Implemented support for range selection in edit mode

Works similarly to the existing cursor. A node is
placed in for the start and end positions of a cursor.

The window selection is updated based on cursor moved events.
The selection sync logic really belongs in SessionView. However,
as only a single selection is supported in the current
implementation, this has been temporarily put into SessionController.

A new function OdtDocument.getCursorSelection has been added
to make it trivial to support range-selection operations.

Fixed lost-in-translation
2013-06-20 02:26:35 +10:00
Philip Peitsch 17bfeef382 Added support for range deletion using the backspace key 2013-06-20 02:26:35 +10:00
Philip Peitsch 135c8affc9 Support range selection in edit mode
Works similarly to the existing cursor. A node is
placed in for the start and end positions of a cursor.

The window selection is updated based on cursor moved events.
The selection sync logic really belongs in SessionView. However,
as only a single selection is supported in the current
implementation, this has been temporarily put into SessionController.

A new function OdtDocument.getCursorSelection has been added
to make it trivial to support range-selection operations.

* Move responsibility for setting the memberId into Cursor to
  allow proper hiding of anchor node
2013-06-20 02:26:29 +10:00
Aditya Bhatt 6541e1343f Add an OdfUtils.parseFontSize function for better font size handling 2013-06-19 17:26:09 +02:00
Aditya Bhatt a66df8774b Implement support for % font sizes. 2013-06-19 17:25:13 +02:00
Jos van den Oever 3634d63e3b Compile fix. 2013-06-19 17:08:52 +02:00
Philip Peitsch ea8c135546 PositionIterator.setUnfilteredPosition automatically advances to the next valid position
This makes the result of next & previous always a node that will pass
the filter. Previous implementations could return entirely unexpected
nodes

* Corrected module load order for tests
2013-06-19 16:58:13 +02:00
Jos van den Oever eecfa4d201 Remove trailing spaces and tabs. 2013-06-19 16:47:52 +02:00
Friedrich W. H. Kossebau a395556e79 Change the spec of OpMoveCursor to contain the absolute target position, not a relative one 2013-06-19 14:36:52 +02:00
Aditya Bhatt fcbc668a50 Add stroke-width and border/padding mapping 2013-06-19 14:24:22 +02:00
Philip Peitsch 415ec18ec3 Removed obselete SelectionManager class 2013-06-19 13:43:46 +02:00
Philip Peitsch 0209521db4 Removed unnecessary position adaptions 2013-06-19 13:43:46 +02:00
Philip Peitsch 4ab30523c0 Modified cursor movement to remove the need to adapt position iterators 2013-06-19 13:43:46 +02:00
Philip Peitsch 7db8ddcfd6 Each function now ensures the positionIterator is set to the cursor position 2013-06-19 13:43:46 +02:00
Aditya Bhatt 563a0e69fb * jsdoc
* handle case when bgcolor might be null
2013-06-19 13:08:49 +02:00
Aditya Bhatt 99895c6eee Move the acquisition of the master page to a separate function 2013-06-19 13:08:49 +02:00
Aditya Bhatt b4b2f08f29 There are more than one master page styles, style pages accordingly
Documentation++
2013-06-19 13:08:49 +02:00
Aditya Bhatt 558a9bbe9b Undo bad width/height hack and now decide the page style to use by
checking the master style name
2013-06-19 13:08:49 +02:00
Aditya Bhatt c3b6ada5d1 Implement page numbers for slides 2013-06-19 13:08:49 +02:00
Aditya Bhatt 92dbaacc1d Respect the presentation:background-visible rule 2013-06-19 13:08:49 +02:00
Aditya Bhatt ca605f69de Also run setFramePosition over shadowContent frames 2013-06-19 13:08:49 +02:00
Aditya Bhatt 9c963f2317 Use a 'none' background if no solid/hatch fill is specified 2013-06-19 13:08:49 +02:00
Aditya Bhatt 8f11dc87b5 Smarter handling of background fill-color, along with alpha channel. 2013-06-19 13:08:49 +02:00
Aditya Bhatt ba3f8a59e6 * Let drawing-page family things also be styled like a graphic.
* Frame opacity is here! (without affecting text)
2013-06-19 13:08:49 +02:00
Aditya Bhatt 6b309ae2a7 Hide elements like presentation|footer-decl and
presentation|date-time-decl, and use draw|page:nth-of-type instead of
nth-child to select the page to be displayed. Now the slideshow only
shows actual slides, not other objects
2013-06-19 13:08:48 +02:00
Aditya Bhatt df5f02ca45 Add support for using per-page master slides 2013-06-19 13:08:48 +02:00
Aditya Bhatt dbc41150d9 Preliminary support for master-pages using a 'shadowContent' node,
outside the main ODF dom.
2013-06-19 13:08:48 +02:00
Aditya Bhatt 29f45f5b54 Stop hardcoding dimensions for presentation pages in webodf.css, and get
these dimensions from the page style.
A new API call has been added to know the type of document
(text/presentation/spreadsheet), and this is used to decide what sort of
CSS rule to generate for page layouts.
As a little temporary hack, for slideshows, the last page style where the
height is lesser than the width is used for layouting, because for the
vast majority of presentations this holds true. This will change once we
adequately implement support for master styles.
2013-06-19 13:08:48 +02:00
Philip Peitsch 266a9d9a8f Make WebODF version discovery able to cope with non-version tags in a branch 2013-06-19 11:03:13 +10:00
Jos van den Oever 4829e31dda Add some @const statements that would speed up webodf if we compiled it in advanced compilation mode. 2013-06-17 17:24:58 +02:00
Philip Peitsch c285bed7c8 Preserve non-odf elements when merging a span into it's parent node
Edit information and other non-odf elements will be moved
to the parent node when the child element contains no further
text content to be removed.
2013-06-17 15:16:35 +02:00
Philip Peitsch 2f63269ae7 Correctly determine whether a span or space element is empty
Only remove span or space elements if the text content is empty
AND there are no character-related children within the text span

* Added more tests to ensure movement around tabs is correct
2013-06-17 15:16:35 +02:00
Jos van den Oever 2d4a256cce Avoid the "v" in the version number. 2013-06-17 14:30:28 +02:00
Jos van den Oever f3da300fa7 Add version number to php code. 2013-06-17 14:25:46 +02:00
Philip Peitsch c8b374a3dc Corrected function doclet optional parameter syntax 2013-06-17 22:09:32 +10:00
Philip Peitsch db36633b53 Formatting.getStyleElement now supports lookup of list styles 2013-06-17 14:03:41 +02:00
Philip Peitsch f66d7477c0 Formatting lookup functions now automatically know which style trees to search (where possible)
* Remove unused function
2013-06-17 14:03:41 +02:00
Philip Peitsch ad3b792a38 Add convenience method to easily calculate the style applied at the cursor 2013-06-17 13:59:51 +02:00
Friedrich W. H. Kossebau 55fc7ab9c6 Switch code to use Node.${XXX}_NODE instead of magic values 2013-06-17 13:49:07 +02:00
Jos van den Oever a4582ea3d8 Aquire version number from the source directory or the git tree. 2013-06-17 13:03:42 +02:00
Philip Peitsch e11ebab6ac Clarified error message when unavailable module is loaded
Previously, attempting to load a module with no manifest.js defined
for the directory the script is executed in would result in node throwing
an "Error: ENOENT, no such file or directory".

With these changes, node will report "Cannot load manifest for …" instead,
allowing it to then fail with the specific module being searched for. This makes
hunting down ordering problems in the compilation a little easier.
2013-06-17 12:22:54 +02:00
Philip Peitsch f76257c81a Avoid issues with lists in fodt files
Extra whitespace nodes throw off any logic depending
on the node's firstChild being a non-whitespace element
2013-06-17 13:08:47 +10:00
Friedrich W. H. Kossebau fb0a21c9de In OperationTests also read attributes named "length" and "number" as integer 2013-06-14 19:21:48 +02:00