Commit graph

2331 commits

Author SHA1 Message Date
Luboš Luňák
7be8bac42a make the linear xml processing API more generic
I'm pretty sure I'll love to use it in writerfilter instead of the normal
API whenever I get the chance.
2011-12-07 14:47:11 +01:00
Luboš Luňák
cc39235d47 process element in endFastElement(), not in dtor
Otherwise with malformed xml the dtor is called in a place where
the processing of the formula apparently corrupts the internal
representation somehow and it is impossible to write the document
back as docx. As a bonus, all UI elements related to saving get
disabled, so the document then cannot be saved at all. Although
this is only with malformed xml, which hopefully should never
happen, it's still better to avoid this. Moreover it seems to be
the proper way of coding the handlers anyway.
2011-12-07 14:47:11 +01:00
Luboš Luňák
a8f46cdc8e remove needless TODO 2011-12-07 14:47:10 +01:00
Caolán McNamara
c8ef924060 normalize Red Hat, Inc. spellings, and bump to latest template 2011-12-06 21:24:37 +00:00
Cédric Bosdonnat
83560ad42b RTF import: fixed the handling of frame properties n#417818
Change the RTF tokenizer to send the same tokens than the docx tokenizer
for the <w:framePr> element.
2011-12-05 18:09:44 +01:00
Cédric Bosdonnat
88bd22cad0 sw, fixed some missing include in dbglevel>1 2011-12-05 18:09:44 +01:00
Cédric Bosdonnat
91ae8f6c06 docx: actually import the last frame of a section.
When there is no paragraph outside the frame before the section end, the
paragraphs weren't transformed to a frame.
2011-12-05 18:09:43 +01:00
Luboš Luňák
0f7fb68680 read m:oMathPara
I'm unsure on what the difference to o:Math actually is, so just make
sure the element and its contents are not ignored and each contained
m:oMath will be read in separately.
2011-11-30 16:11:45 +01:00
Bjoern Michaelsen
b1d20f6847 set gb_PARTIALBUILD in CustomTargets 2011-11-29 18:11:51 +01:00
Bjoern Michaelsen
d73e574d8a move reconfigure into gbuild 2011-11-29 17:25:14 +01:00
Luboš Luňák
9bccb2c69a I hate sal_Int*. Fix ambiguous overload on windows. 2011-11-29 16:05:39 +01:00
Luboš Luňák
eca8fc7069 EMBEDDED_OBJECT UNO property now works, remove hack 2011-11-29 13:27:44 +01:00
Luboš Luňák
34a98b79da set properly initial size of starmath component when importing docx 2011-11-29 13:27:43 +01:00
Luboš Luňák
93be239c95 the bit hackish addFormula() shortcut is no longer necessary 2011-11-29 13:27:43 +01:00
Luboš Luňák
86eccc72c5 clean up and format code 2011-11-29 13:27:43 +01:00
Miklos Vajna
61edefc8c8 remove debug printf 2011-11-29 00:54:28 +01:00
Miklos Vajna
4f6d80fbb8 RTF: Avoid importing unicode characters one by one
This imprives speed of importing unicode text further. Results of a
sample of chinese text of 5 pages:

- before: 6.692s
- after: 1.388s
2011-11-29 00:52:11 +01:00
Miklos Vajna
9ef6890543 mark these as const 2011-11-29 00:52:11 +01:00
August Sodora
13673b71bc Remove uses of OUString::setCharAt 2011-11-28 14:56:40 +01:00
Miklos Vajna
75112a0544 RTFDocumentImpl::resolveChars: don't send empty text tokens to dmapper
This speeds up importing unicode text a lot. Results of a sample of
chinese text of 5 pages:

- before: 18.351s
- after: 6.692s
2011-11-28 00:59:57 +01:00
Miklos Vajna
53170743c4 RTFSprm: remove unneeded includes 2011-11-27 23:12:16 +01:00
Miklos Vajna
34eea8f1f1 RTFReferenceProperties: remove unneeded includes 2011-11-27 23:12:16 +01:00
Miklos Vajna
10e0c7d1c4 RTFValue: remove unneeded includes 2011-11-27 23:12:16 +01:00
Bjoern Michaelsen
f2f0dbd273 make gbuild makefiles run independant of pwd again 2011-11-25 12:04:40 +01:00
Cédric Bosdonnat
52e6bfeb32 RTF import: fixed the missing paragraph breaks from fdo#43206.
"\\\n" is used as an equivalent to \par even though I couldn't find it
in the specs.
2011-11-25 10:04:41 +01:00
Luboš Luňák
a685e8fb72 remove debug output 2011-11-24 18:44:00 +01:00
Luboš Luňák
f8f1ccbaf9 rename and move mathml oox support classes in oox to better places 2011-11-24 18:43:58 +01:00
Luboš Luňák
e443c83aa3 remove debug output 2011-11-24 18:43:57 +01:00
Luboš Luňák
e9462ed2d9 ooxml mathml import - first very basic implementation
still needs a number of cleanups (and handling more of course)
2011-11-24 18:43:57 +01:00
Luboš Luňák
1acdbe4dfe initial (very hacky) work on mathml ooxml import
This commit needs to be generally reworked for upstream, but it
more or less works.
2011-11-24 18:43:56 +01:00
Cédric Bosdonnat
f4f4a899f0 RTF import: partly fixed the WMF images scaling. 2011-11-24 16:08:46 +01:00
Cédric Bosdonnat
e846db6448 RTF: OLE object import with graphic result fixed, the file can now be opened 2011-11-23 11:24:06 +01:00
Cédric Bosdonnat
a45c82f930 Show some exception message when getting one in RtfFilter 2011-11-23 11:24:06 +01:00
Miklos Vajna
543d3bf035 writerfilter: add a README explaining subdirs 2011-11-22 20:54:00 +01:00
Cédric Bosdonnat
98f32b2b8e RTF import: better implement \trrh to import fixed height rows 2011-11-22 15:17:05 +01:00
Cédric Bosdonnat
b03fbe13f3 writerfilter: Fixed crasher when importing docx files with dbglevel>1 2011-11-22 15:17:05 +01:00
Cédric Bosdonnat
07b5fe3b8c n#417818: empty paragraphs in tables weren't considered in the table.
The paragraph properties weren't propagated to the empty paragraphs in
the tables. Called checkNeedPap() to do that job when finding \par.
2011-11-22 15:17:04 +01:00
Miklos Vajna
fcae5e4103 Related: i#86517 avoid crash on invalid LEVELTEXT 2011-11-21 01:24:23 +01:00
Miklos Vajna
8731f25549 Related: i#83069 fix crash in DomainMapper_Impl::FindOrCreateFieldMaster
The next line would deference a NULL pointer otherwise, so use UNO_QUERY_THROW.
2011-11-21 00:16:42 +01:00
Miklos Vajna
9b78fe9621 Related: i#60831 fix RTF import of DOCPROPERTY fields 2011-11-21 00:16:41 +01:00
Miklos Vajna
3ece03f3d4 Related: i#93039 fix RTF import of MACROBUTTON fields 2011-11-21 00:16:41 +01:00
Miklos Vajna
51a4292c99 RTFSdrImport: unneeded include 2011-11-19 12:55:31 +01:00
Miklos Vajna
59a0064c2a RTFDocumentImpl: remove 15 unused includes 2011-11-18 23:44:24 +01:00
Miklos Vajna
cde0485eae Related: i#2593 fix RTF import of REF fields 2011-11-18 11:17:43 +01:00
Miklos Vajna
a8cae44d7c Related: i#56948 fix crash during RTF import of FILLIN field 2011-11-18 10:59:59 +01:00
Miklos Vajna
3aec127f4d Related i#44806: Fix crash in dmapper when importing FILENAME fields 2011-11-17 17:19:57 +01:00
Caolán McNamara
94a5174e59 get this to build on ppc64 linux 2011-11-16 15:35:58 +00:00
Norbert Thiebaud
0ea8c014ef tweak gbuild standart Makefile to allow partial build in unsourced env
This allow to run make in a module wihtout the need to source
Env.Host.sh.
2011-11-16 06:18:54 -06:00
Miklos Vajna
c2439ecdd4 Related: i#113308 null pointer check for the unit test 2011-11-16 12:00:01 +01:00
Miklos Vajna
bec1bff6af Related i#113308: fix import of RTF table rows having no cells 2011-11-16 11:09:00 +01:00
Caolán McNamara
1987a5c777 callcatcher: remove unused code 2011-11-14 07:35:58 +00:00
Caolán McNamara
f535855d7b tagLogger dtor never called 2011-11-14 07:35:56 +00:00
Miklos Vajna
3f170f2232 Related: i#110745 fix crash on invalid RTF tables 2011-11-13 04:14:19 +01:00
Miklos Vajna
3510a6f639 RTFDocumentImpl: cleanup
checkFirstRun() should not do what checkNeedPap() already does
2011-11-13 04:14:19 +01:00
Miklos Vajna
2cbb64ca30 Related: i#108154 null pointer check for the unit test 2011-11-12 15:36:03 +01:00
Cédric Bosdonnat
8a232f0074 RTF import: Fixed unicode characters import, fdo#42109
Actually implemented the \uc to skip the ANSI representation after the
unicode value.
2011-11-12 14:25:11 +01:00
Cédric Bosdonnat
74b6759ee8 n#707157: Word doesn't break the numberings and prefers hiding them
Added a compatibility option to reproduce Word's behavior when importing
Doc, docx and RTF files. The default behavior isn't changed.
2011-11-12 14:25:11 +01:00
Miklos Vajna
843494285d Related: fdo#38966 null pointer check for the unit test 2011-11-12 00:09:31 +01:00
Miklos Vajna
ac8782bd51 Related: fdo#37716 null pointer check for the unit test 2011-11-12 00:03:56 +01:00
Miklos Vajna
444d04b60b Related: fdo#37498 don't try to read after the last closing brace 2011-11-12 00:03:55 +01:00
Miklos Vajna
5a212d501e Related: fdo#33012 null pointer check for the unit test to pass 2011-11-12 00:03:55 +01:00
Stephan Bergmann
c1758889cb Heavily simplified utl::ConfigManager. 2011-11-11 22:49:21 +01:00
Stephan Bergmann
f66ac29343 Make .component files directly usable within UNO_SERVICES.
* solenv/bin/createcomponent.xslt simply surrounds it output by <components>.
* solenv/gbuild/CppunitTest.mk got new functions
gb_CppunitTest_add[_old]_component[s] (like their gb_RdbTarget_ predecessors).
* This obsoleted current uses of solenv/gbuild/RdbTarget.mk, which also does not
work currently, as it catenates the input component files instead of passing
them through packcomponents.xslt (which now takes care about the surrounding
<components> in the input).  In the future, it will likely be combined with the
recently added solenv/gbuild/ComponentsTarget.mk.
2011-11-11 10:53:23 +01:00
Noel Power
02c6f5c74b fix rtf image import ( causing wrong image sometimes displayed ) fdo#42640 2011-11-09 14:37:40 +00:00
Cédric Bosdonnat
0e26bd2097 writerfilter import, fixed the shapes import
In some cases like an OLE object inside a textbox, the imported document
was empty. This was due to unremoved text context in dmapper.
2011-11-08 17:05:19 +01:00
Cédric Bosdonnat
b32bcaf10a sw, writerfilter: fixed debug builds and output dmapper table messages 2011-11-08 17:05:19 +01:00
Luboš Luňák
247ac3b109 fix incorrect OSL_FAIL message because of copy&paste 2011-11-08 15:37:54 +01:00
Miklos Vajna
a23ee867ea RTFDocumentImpl: rename m_bIsInShape to m_bIsInFrame
The "in shape" term was confusing since it was false for non-text-frame
shapes all the time.
2011-11-08 15:03:09 +01:00
Miklos Vajna
dc060230a1 RTFDocumentImpl: use boost::shared_ptr for m_pInStream and m_pGraphicHelper 2011-11-06 14:01:22 +01:00
Miklos Vajna
e4323bd5f5 RTF import: close file descriptor once import finished 2011-11-06 13:55:30 +01:00
Miklos Vajna
009c572b2f RTF import: delete graphic helper once it's not used (fdo#42640) 2011-11-06 13:45:28 +01:00
Miklos Vajna
11e227371a Related: i#95668 Fix encoding of non-continuous font indexes
The non-continuous font index first has to be converted before the
encoding can be looked up.
2011-11-02 02:30:47 +01:00
Miklos Vajna
2a5e99cb83 RTF_FFRES should be parsed for list fields only
See spec v1.9.1, page 198.
2011-10-29 01:06:33 +02:00
Miklos Vajna
d6df2cdd2e Fix crash of text frames inside RTF tables (fdo#39856) 2011-10-29 00:58:08 +02:00
Miklos Vajna
43d5a03d02 Related: fdo#39856 fix RTF import of some special accented chars in tables 2011-10-29 00:26:02 +02:00
Matúš Kukan
c77a9254dd no need for SRCDIR parameter here 2011-10-23 13:20:29 +02:00
Michael Stahl
521001049d writerfilter: add some bling to customtarget 2011-10-21 20:17:19 +02:00
Tor Lillqvist
62f4128d74 char can be unsigned, use sal_Int8 2011-10-20 08:41:36 +03:00
Caolán McNamara
db5a5ffa82 split bootstrapfixture and move test-filters class for sot test
sot is below vcl, but is a filters test, we can split bootstrapfixture
into a vcl needing bit and and non-vcl bit and filters test api
can be standalone and combined with whichever bit in order to form
pre and post vcl filters test
2011-10-15 12:18:44 +01:00
Miklos Vajna
ee2e2a1f52 fdo#41080: fix crash while importing footnotes in RTF tables 2011-10-14 14:53:06 +02:00
Caolán McNamara
0123fc6d03 these can go behind DEBUG_CONTEXT_HANDLER 2011-10-10 22:36:55 +01:00
Tor Lillqvist
ebcb781ab0 WaE: class has virtual functions, but destructor is not virtual 2011-10-07 16:10:01 +03:00
Tor Lillqvist
86cbc1dd99 WaE: switch statement contains 'default' but no 'case' labels 2011-10-07 15:56:03 +03:00
Tor Lillqvist
d0aaada282 WaE: unreferenced local variable 2011-10-07 15:56:01 +03:00
Tor Lillqvist
11b64d662d WaE: assignment within conditional expression
A whole bunch of them.
2011-10-07 15:55:59 +03:00
Tor Lillqvist
e76df814a5 WaE: type name first seen using 'struct' now seen using 'class' 2011-10-07 15:55:57 +03:00
Tor Lillqvist
535cd4acc2 WaE: unreferenced local variable 2011-10-07 15:55:54 +03:00
Caolán McNamara
eddc7f6846 WaE: unused variables 2011-10-05 16:30:08 +01:00
Michael Meeks
8a0d0457a7 test fix: use setUp and tearDown not constructors to init LibreOffice
It turns out the constructors are all run back-to-back one per filter,
and we need to init and de-init in a sensible order to make multiple
tests that otherwise share the ContentBroker work properly.
2011-10-05 16:02:28 +01:00
Bjoern Michaelsen
e94a19f3e0 simplfy dmake to gbuild bridgefile 2011-10-05 00:31:50 +02:00
Bjoern Michaelsen
73000ee8c2 adapt writerfilter unittests to separate RdbTarget makefile requirement 2011-10-04 18:34:23 +02:00
Caolán McNamara
e898bcc1c2 silence tedious malware checkers, arcfour, key 0x435645 2011-09-30 17:02:37 +01:00
Caolán McNamara
4a5745503c merge filters-test code 2011-09-30 12:39:35 +01:00
Caolán McNamara
1f5c696c37 add mode-lines to .m files and last round of merged files, etc. 2011-09-30 09:09:25 +01:00
Stephan Bergmann
6671fa81db Removed uses of rtl::O[U]String[Buffer]::operator sal_{char|Unicode} const *(). 2011-09-27 20:22:03 +02:00
Caolán McNamara
871426533f just silence the auto_ptr deprecations in isolation 2011-09-22 15:01:05 +01:00
Stephan Bergmann
7d1bb036e1 Simplified setting headless mode for smoke-/subsequenttetss.
Both C++ and Java OfficeConnection code now always pass --headless, so no
need for SAL_USE_VCLPLUGIN=svp etc. any more.  Only some C++ unit tests that
link against vcl still need an explicit --headless.
2011-09-16 10:38:06 +02:00
Stephan Bergmann
d996328cd5 sb140: #i113503# mixing system CppUnit and OOo STLport does not work, backed out a6913c9677c2
For LibO, that just means replacing sal/cppunit.h with sal/precppunit.hxx.
2011-09-12 22:47:50 +02:00
Caolán McNamara
b2043b3585 map CTL_LANGUAGE<->RTF_ALANG the same as CTL_FONTSIZE<->RTF_AFS 2011-09-09 14:00:49 +01:00
Julien Nabet
ec9f19db98 Fix duplicateBreak 2011-09-08 21:45:17 +02:00