~ubuntu-branches/ubuntu/saucy/libwpd/saucy

« back to all changes in this revision

Viewing changes to src/lib/WP3ContentListener.h

  • Committer: Package Import Robot
  • Author(s): Rene Engelhard
  • Date: 2013-04-19 00:47:04 UTC
  • mfrom: (11.1.7 experimental)
  • Revision ID: package-import@ubuntu.com-20130419004704-j04jp8dan8plg630
Tags: 0.9.7-2
upload to unstable 

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
2
2
/* libwpd
 
3
 * Version: MPL 2.0 / LGPLv2.1+
 
4
 *
 
5
 * This Source Code Form is subject to the terms of the Mozilla Public
 
6
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 
7
 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
8
 *
 
9
 * Major Contributor(s):
3
10
 * Copyright (C) 2004 Marc Maurer (uwog@uwog.net)
4
11
 * Copyright (C) 2005-2006 Fridrich Strba (fridrich.strba@bluewin.ch)
5
12
 *
6
 
 * This library is free software; you can redistribute it and/or
7
 
 * modify it under the terms of the GNU Library General Public
8
 
 * License as published by the Free Software Foundation; either
9
 
 * version 2 of the License, or (at your option) any later version.
10
 
 *
11
 
 * This library is distributed in the hope that it will be useful,
12
 
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
 
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14
 
 * Library General Public License for more details.
15
 
 *
16
 
 * You should have received a copy of the GNU Library General Public
17
 
 * License along with this library; if not, write to the Free Software
18
 
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
 
13
 * For minor contributions see the git repository.
 
14
 *
 
15
 * Alternatively, the contents of this file may be used under the terms
 
16
 * of the GNU Lesser General Public License Version 2.1 or later
 
17
 * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
 
18
 * applicable instead of those above.
19
19
 *
20
20
 * For further information visit http://libwpd.sourceforge.net
21
21
 */
57
57
        void startDocument()
58
58
        {
59
59
                WPXContentListener::startDocument();
60
 
        };
 
60
        }
61
61
        void startSubDocument()
62
62
        {
63
63
                WPXContentListener::startSubDocument();
64
 
        };
 
64
        }
65
65
        void insertCharacter(uint32_t character);
66
66
        void insertTab();
67
67
        void insertTab(uint8_t tabType, double tabPosition);
68
68
        void insertBreak(uint8_t breakType)
69
69
        {
70
70
                WPXContentListener::insertBreak(breakType);
71
 
        };
 
71
        }
72
72
        void insertEOL();
73
73
        void attributeChange(bool isOn, uint8_t attribute);
74
74
        void lineSpacingChange(double lineSpacing)
75
75
        {
76
76
                WPXContentListener::lineSpacingChange(lineSpacing);
77
 
        };
78
 
        void pageMarginChange(uint8_t /* side */, uint16_t /* margin */) {};
79
 
        void pageFormChange(uint16_t /* length */, uint16_t /* width */, WPXFormOrientation /* orientation */) {};
 
77
        }
 
78
        void pageMarginChange(uint8_t /* side */, uint16_t /* margin */) {}
 
79
        void pageFormChange(uint16_t /* length */, uint16_t /* width */, WPXFormOrientation /* orientation */) {}
80
80
        void marginChange(uint8_t side, uint16_t margin);
81
 
        void indentFirstLineChange(int16_t offset);
 
81
        void indentFirstLineChange(double offset);
82
82
        void setTabs(bool isRelative, const std::vector<WPXTabStop> tabStops);
83
83
        void columnChange(WPXTextColumnType columnType, uint8_t numColumns, const std::vector<double> &columnWidth,
84
84
                          const std::vector<bool> &isFixedWidth);
85
85
        void endDocument()
86
86
        {
87
87
                WPXContentListener::endDocument();
88
 
        };
 
88
        }
89
89
        void endSubDocument()
90
90
        {
91
91
                WPXContentListener::endSubDocument();
92
 
        };
 
92
        }
93
93
 
94
94
        void defineTable(uint8_t position, uint16_t leftOffset);
95
95
        void addTableColumnDefinition(uint32_t width, uint32_t leftGutter, uint32_t rightGutter,
111
111
        void insertNoteReference(const WPXString &noteReference);
112
112
        void insertNote(WPXNoteType noteType, const WP3SubDocument *subDocument);
113
113
        void headerFooterGroup(uint8_t headerFooterType, uint8_t occurenceBits, WP3SubDocument *subDocument);
114
 
        void suppressPage(uint16_t /* suppressCode */) {};
 
114
        void suppressPage(uint16_t /* suppressCode */) {}
115
115
        void backTab();
116
116
        void leftIndent();
117
117
        void leftIndent(double offset);
125
125
                             uint16_t figureFlags, const WP3SubDocument *subDocument, const WP3SubDocument *caption);
126
126
 
127
127
protected:
128
 
        void _handleSubDocument(const WPXSubDocument *subDocument, WPXSubDocumentType subDocumentType, WPXTableList tableList, int nextTableIndice = 0);
 
128
        void _handleSubDocument(const WPXSubDocument *subDocument, WPXSubDocumentType subDocumentType, WPXTableList tableList, unsigned nextTableIndice = 0);
129
129
        void _openParagraph();
130
130
 
131
131
        void _flushText();
132
 
        void _changeList() {};
 
132
        void _changeList() {}
133
133
 
134
134
        void _handleFrameParameters( WPXPropertyList &propList, double height, double width, double verticalOffset, double horizontalOffset, uint8_t leftColumn, uint8_t rightColumn,
135
135
                                     uint16_t figureFlags );