~ubuntu-branches/ubuntu/precise/koffice/precise

« back to all changes in this revision

Viewing changes to filters/kword/msword-odf/wv2/src/handlers.h

  • Committer: Bazaar Package Importer
  • Author(s): Alessandro Ghersi
  • Date: 2010-10-27 17:52:57 UTC
  • mfrom: (0.12.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20101027175257-s04zqqk5bs8ckm9o
Tags: 1:2.2.83-0ubuntu1
* Merge with Debian git remaining changes:
 - Add build-deps on librcps-dev, opengtl-dev, libqtgtl-dev, freetds-dev,
   create-resources, libspnav-dev
 - Remove needless build-dep on libwv2-dev
 - koffice-libs recommends create-resources
 - krita recommends pstoedit
 - Keep our patches
* New upstream release 2.3 beta 3
  - Remove debian/patches fixed by upstream
  - Update install files

Show diffs side-by-side

added added

removed removed

Lines of Context:
149
149
         * The end of the current header or footer.
150
150
         */
151
151
        virtual void headerEnd();
 
152
        /**
 
153
         * This method sends a binary mask providing the information of
 
154
         * empty/nonempty header and footer stories for each section.  Size of
 
155
         * the list equals the number of sections present in the document.
 
156
         */
 
157
        virtual void headersMask(QList<bool> mask);
152
158
 
153
159
    };
154
160
 
201
207
     * callbacks. All the image data is passed to the consumer via this
202
208
     * interface.
203
209
     */
 
210
    //NOTE: OBSOLETE, graphics are handled by the GraphicsHandler and we are
 
211
    //using msoscheme to parse Office Drawing Binary File Format structures.
204
212
    class WV2_EXPORT PictureHandler
205
213
    {
206
214
    public:
238
246
        /**
239
247
         * This method is called when the image is escher data.
240
248
         */
241
 
        virtual void escherData( OLEImageReader& reader, SharedPtr<const Word97::PICF> picf, int type, U32 pib);
242
 
        virtual void escherData( std::vector<U8> data, SharedPtr<const Word97::PICF> picf, int type, U32 pib);
 
249
        virtual void escherData( OLEImageReader& reader, SharedPtr<const Word97::PICF> picf, int type, const U8* rgbUid);
 
250
        virtual void escherData( std::vector<U8> data, SharedPtr<const Word97::PICF> picf, int type, const U8* rgbUid);
243
251
        /**
244
252
         * This method is called when you invoke a PictureFunctor and the embedded
245
253
         * image is a .wmf file. The data can be accessed using the OLEImageReader.
258
266
        virtual void officeArt(wvWare::OfficeArtProperties *artProperties);
259
267
    };
260
268
 
261
 
    class WV2_EXPORT DrawingHandler
 
269
    /**
 
270
     * The GraphicsHandler class is the interface for MS-ODRAW objects related
 
271
     * callbacks.  Office Drawing Binary File Format structures are parsed by
 
272
     * msoscheme.
 
273
     */
 
274
    class WV2_EXPORT GraphicsHandler
262
275
    {
263
276
    public:
264
277
 
265
 
        virtual ~DrawingHandler();
 
278
        virtual ~GraphicsHandler();
266
279
 
267
280
        /**
268
 
         *This method is called when picture should be drawn. Function gets cp of drawing
269
 
         *and and draws the date belonging to it.
 
281
         * This method gets called when a floating object is found.
 
282
         * @param globalCP (character position)
270
283
         */
271
 
        virtual void drawingData(unsigned int globalCP);
 
284
        virtual void handleFloatingObject(unsigned int globalCP);
 
285
 
 
286
        /**
 
287
         * This method gets called when an inline object is found.  @param data
 
288
         * the picture properties and offset into data stream.
 
289
         */
 
290
        virtual void handleInlineObject(const PictureData& data);
272
291
    };
273
292
 
274
293
 
385
404
        virtual void footnoteFound( FootnoteData::Type type, UString characters,
386
405
                                    SharedPtr<const Word97::CHP> chp, const FootnoteFunctor& parseFootnote);
387
406
 
388
 
 
389
407
        /**
390
408
         * The parser found an annotation. The passed functor will trigger the parsing of this
391
409
         * annotation, the default implementation just emits the passed character with
435
453
        virtual void tableRowFound( const TableRowFunctor& tableRow, SharedPtr<const Word97::TAP> tap );
436
454
 
437
455
        /**
438
 
         * This method is called every time we find a picture. The default
439
 
         * implementation invokes the functor, which triggers the parsing
440
 
         * process for the given picture.
441
 
         * @param picf the picture properties. Those are the same as the
442
 
         * ones you'll get when invoking the functor, but by having them here,
443
 
         * you can do some preprocessing.
444
 
         */
445
 
        virtual void pictureFound( const PictureFunctor& picture, SharedPtr<const Word97::PICF> picf,
446
 
                                   SharedPtr<const Word97::CHP> chp );
447
 
 
448
 
        /**
449
 
         * This method is called every time we find a drawing.
450
 
         */
451
 
        virtual void drawingFound( unsigned int globalCP );
 
456
         * This method is called every time we find an inline object.
 
457
         * @param data the picture data as defined by functordata.
 
458
         */
 
459
        virtual void inlineObjectFound(const PictureData& data);
 
460
 
 
461
        /**
 
462
         * This method is called every time we find a floating object.
 
463
         * @param cp of a drawing
 
464
         */
 
465
        virtual void floatingObjectFound( unsigned int globalCP );
 
466
 
 
467
        /**
 
468
         * Denotes the start of a bookmark.
 
469
         */
 
470
        virtual void bookmarkStart( const BookmarkData& data );
 
471
        virtual void bookmarkEnd( const BookmarkData& data );
452
472
    };
453
473
 
454
474
} // namespace wvWare