Commit Graph

218 Commits

Author SHA1 Message Date
0db3691954 WaE: passing OString by value, rather pass by reference
Change-Id: I41a318b8376ae3e68701ffe6ebc745bdbec62dc8
2014-04-06 23:39:50 +03:00
58f8e286e9 Add HtmlWriterHelper to svtools.
Change-Id: I4d96402cc0fa86d83fe0ade314b84bff86d7db97
2014-04-06 22:02:12 +02:00
2480ded80e HtmlWriter: add prettyPrint option, instance variables
Change-Id: I6a29e91cc2f328ccbd01b617b39dc9275332d1f0
2014-04-06 22:02:11 +02:00
ee0b9f8df6 svtools: make HTMLOutFuncs::Out_AsciiTag clearer.
Change-Id: I89d72383a50707aa8cb958eaea916e8070cfcd82
2014-04-06 22:02:10 +02:00
96c548a7c6 svtools: HtmlWriter - for writing HTML structure to a stream
HtmlWriter is used to write the structure of a HTML document to
a stream. The goal is to abstract the messy construction of
strings when writing attributes of a html element and other
HTML specifics needed when structuring a HTML document.

Change-Id: Ibdf42914e43ef02f16a43e4230575ed7340e68d8
2014-04-06 22:02:10 +02:00
9a0e6204bb coverity#735505 Logically dead code
Change-Id: I7e7abf9192ee34c9f1c2080268751503aae90e55
2014-04-01 13:46:47 +01:00
a4dc5ea2f7 svtools: sal_Bool->bool
Change-Id: I288a5c8b86d21a1b91f464aaf162aed9aca35a42
2014-03-24 08:12:10 +02:00
7a679ee19c svtools: sal_Bool->bool
Change-Id: I35c9c1514c67860e61b6e2457ab4548d04a4d159
2014-03-24 08:12:10 +02:00
dcc977b339 switch: ungroup two case which perform different operations
Change-Id: I099501a596ebeb2820192d08de80eae342191bb7
2014-03-08 10:13:25 +01:00
bee1cc83ec Remove visual noise from svtools
Change-Id: I7c2b74a449fb20aae5bc643e24a22cf6f732136d
Reviewed-on: https://gerrit.libreoffice.org/8320
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-25 21:14:09 +00:00
8a467da032 html: Make GetColor() working in lower case.
To be consistent with the rest that works in lower case now.

Change-Id: I6fe40e71393230bbde8e283b1f98479bf644c610
2014-02-21 12:04:27 +01:00
0f1b3df7a3 html: Lowercase the html colors, and make the comparison more robust.
Change-Id: I5fb3b1c8ea3692864707489ff9a82b78c5647d4a
2014-02-21 12:04:26 +01:00
456b92609c fdo#74584: complete revert various previous changes to upcase HTML tags
f1f8b3bfdc3406ea79b662a2fda3d0c1cb87bb10 says it reverts

        commit 3c84fa61570113d1dfb2523ab88f268eeeb46c3c.
        commit 96a1f60aeb2a7954533da9b4aa4947efb7a65e70.
        commit 1f74a3ce201bad68f160584900285e2c087ab2c0.
        commit 3d481254a07fe82d11953f9825a2f8fc6eeabc0b.

but only reverted 3d481254a07fe82d11953f9825a2f8fc6eeabc0b

Change-Id: I0530bd0b176b1f1e9bbf8eee78376991c664a850
2014-02-21 10:12:22 +00:00
a18a1a4545 Remove vcl/settings.hxx from vcl/svapp.hxx and vcl/outdev.hxx
Added vcl/settings.hxx to all cxx files which require it.
This helps to speed up compilation after changes to the settings.

Conflicts:
	sc/source/ui/dbgui/pvlaydlg.cxx

Change-Id: I211a0735c47f72d6879f6f15339355abfe0e3cf4
Reviewed-on: https://gerrit.libreoffice.org/7933
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-20 16:22:17 +00:00
3c84fa6157 fdo#74584: Revert "fix html tests"
This reverts commit 277922e7a0a4ae8076c10936c4b12df6dcc5ddac.

...since 73e3aafa990168aa532fa7b81fc4de8f455b10e1 was reverted and
sw_htmlexport test fails.

Change-Id: I32a390a3058e43bc3314b678e27c74036b90f200
2014-02-20 00:52:22 +01:00
96a1f60aeb fdo#74584: Revert "html: Options need to be lowercase, too"
This reverts commit 700883b34ebcdb77f398b4423f358bdf4648a853.

...since 73e3aafa990168aa532fa7b81fc4de8f455b10e1 was reverted and
sw_htmlexport test fails.

Change-Id: Ia83705279e792a0c2375619b6a209e46a319fea7
2014-02-20 00:52:22 +01:00
1f74a3ce20 fdo#74584: Upcase the tag name before searching.
Else HTML import or detection code would fail.

Change-Id: Id79e8eac87d8001527f068f8fd49636353dc38d5
2014-02-19 16:36:49 -05:00
85f48b1b47 coverity#738865 Uninitialized scalar field
Change-Id: Ie6473e4a8c4b311b6862019046fb4ae9cf05e1fb
2014-02-19 13:06:15 +00:00
de476d0146 cid#1103689 missing break in switch
Change-Id: I28338145fdd71ec25b9c6d291e445d35636e43a9
2014-02-12 15:10:47 +02:00
b16f90f331 remove code in dead HTML_BEHAVIOUR #define
git grep found nowhere in the codebase that this define is being
set.

Change-Id: I63e18e8f47b5e58ff96b075ddb4bc9a36e1dc80e
Reviewed-on: https://gerrit.libreoffice.org/8002
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-12 11:13:25 +00:00
d803483f6a convert more SvStream::operator<< calls
.. to more explicit SvStream::Write* calls
This was done using another run of the clang rewriter, and then
a lot of hand tweaking to fix all the places where the rewriter
did not play nice with various macros.

Change-Id: I7bcab93851c8dfb59cde6bc76290c6484d88fb18
Reviewed-on: https://gerrit.libreoffice.org/7494
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2014-01-22 22:00:39 +00:00
e576b083c8 longparas: drop STRING_MAXLEN use now
Change-Id: Iaaca13e732c234e9051be0ab66a7625f9c106eea
2014-01-14 10:53:29 +00:00
e7a86f2d68 Use bool
Change-Id: I2f1c543b106e24ff49f876dbb3d8e94f4ebf03ba
2014-01-10 17:11:53 +01:00
ee536e482b Translated German comments
Reviewed on:
	https://gerrit.libreoffice.org/7303

Change-Id: I6c5f4571ad691d19ca93c39550000114f263da8b
2014-01-09 19:11:03 +01:00
82625bb98e remove unnecessary sal_Unicode casts in OUStringBuffer::append calls
Convert code like:
    buf.append( static_cast<sal_Unicode>('!') );
to:
    buf.append( '!' );

Change-Id: Iacb03a61de65a895540940953b49620677b3d051
2014-01-07 09:43:37 +02:00
a39d07e134 Unwind occurrences of deprecated sal_sChar, sal_uChar
Change-Id: I76be464200d486efef9c8a7e957c310c9adae3b8
2013-11-27 12:52:32 +01:00
73342dbb82 remove unnecessary RTL_CONSTASCII_STRINGPARAM
A final pass through the code, converting code to use the new
OUString and OString methods that can detect string literals.

Change-Id: Ifa6382335e5650a1c67e52006b26354e0692c710
2013-11-22 08:07:19 +02:00
1730df0127 remove unnecessary RTL_CONSTASCII_STRINGPARAM in OString::append
Convert code like:
   aOStringBuf.append( RTL_CONSTASCII_STRINGPARAM( " is missing )") );
to:
   aOStringBuf.append( " is missing )" );
which compiles down to the same code.

Change-Id: I3d8ed0cbf96a881686524a167412d5f303c06b71
2013-11-20 10:07:32 +02:00
2d2e1267be xub_StrLen->sal_Int32
Change-Id: Ia17762919b57bc6febed5cc49e8931165870c117
2013-11-13 13:50:37 +00:00
296329a926 convert xub_StrLen to sal_Int32
convert for loops using xub_StrLen to use sal_Int32

Change-Id: I5f635ca078966fefe938dbc7e8dea7c8d0d0b554
2013-11-06 08:51:22 +02:00
7a06928bcf convert code to use OUString::endsWith
Convert places that call
   aStr[aStr.getLength()-1] == 'x'
to use the shorter form
   aStr.endsWith("x")

Change-Id: I1b3a19c0e89b8989cdbeed440f95fc76f9a4b6b6
2013-10-23 08:29:15 +02:00
a7724966ab Bin comments that claim to say why some header is included
They are practically always useless, often misleading or obsolete.

Change-Id: I2d32182a31349c9fb3b982498fd22d93e84c0c0c
2013-10-22 16:56:28 +03:00
a979956012 html: remove unused options
Change-Id: If8a6d5136e9e397f5f9b2b49bd9aaf4a7e6bfc17
2013-10-14 11:53:44 +02:00
6954aad4e5 Reduce copypasta: Introduce SAL_NEWLINE_STRING and use it
Contains the platform-dependent on-disk line separator ("\r\n" for Windows,
"\n" otherwise, and yes, I assume an ASCII-based world).

Use it instead of static constant char array fields, with ifdeffed
initialisations, in various classes here and there.

Change-Id: Ibea1f2cc1acfb8cc067c3892a41f73bf44f2c78a
2013-10-13 13:49:24 +03:00
b11f257d9b Test _WIN32 instead of UNX as it's Win32 that is the special case here
Change-Id: Ic729eab62109d854122fa5c6b7b4dc163088dd04
2013-10-12 20:34:54 +03:00
700883b34e html: Options need to be lowercase, too
Because the lookup table (include/svtools/htmlkywd.hxx) is now lowercase.

Change-Id: Ica0606eb1546f74d2b651a70adee8117c956d4e2
Reviewed-on: https://gerrit.libreoffice.org/6193
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
2013-10-10 17:58:56 +00:00
8e37c7ae28 html: <li> is on/off - arrange list correctly
despite the fact, that <li> tags are currently not closed...

Change-Id: If77d99b8dfcb00e60d918e5ce5030e6e44a6e64a
2013-10-07 14:33:25 +02:00
07ba28f6bb html: remove unused and unsupported tags
Change-Id: Ibd44d716e70034ffe7d31e3f5dc2c547a822b0e1
2013-10-07 14:33:24 +02:00
277922e7a0 fix html tests
after 73e3aafa990168aa532fa7b81fc4de8f455b10e1 we need to lowercase all
html tags.

Change-Id: Ied686e153666f79c2a866473eeb393ec4e5bb961
2013-10-06 20:09:52 +02:00
c6413fec71 html: remove duplicates
OOO_STRING_SVTOOLS_HTML_C_LT is the same as OOO_STRING_SVTOOLS_HTML_C_lt
and so on...

Change-Id: I7cc94a662e83176c2c2c441cbce27b4f2774e4a4
2013-10-06 16:51:23 +02:00
b1404ef4e5 drop tools/string.hxx from a bunch of places
Change-Id: Id6d22b71f2b552ea7872e8a3da6afe207e856561
2013-09-12 13:09:03 +01:00
ed0f0fa730 XubString->OUString
Change-Id: I5424a148c7173409e6e56f9483fcc769696707bc
2013-09-02 12:22:34 +01:00
7776178974 convert svtools/source/svhtml/* from String to OUString
Change-Id: Ie9f0cdd14ce7987c3bf3037c2ed89a3b20df1c37
2013-08-22 10:49:31 +02:00
784db67fb5 convert include/svtools/htmlout.hxx from String to OUString
Change-Id: I2fcc3335945202672a5f8ab36ae6bdb395e83476
2013-08-22 10:49:28 +02:00
ef0960383f convert include/svtools/htmltokn.h from String to OUString
Change-Id: Idf7401e67fda69655860e7eb3d5c740d77d9e086
2013-08-22 10:49:27 +02:00
5166f28e79 original code inserted sSaveToken at the start of aToken
prior to 33eeb70011b34a3b04a74b2237d1d6fdde030c35

Change-Id: I61070c0d04152e544ff329fc3428cb4f5a06e791
2013-08-15 09:50:40 +01:00
76c615c177 single arg Erase erased to eol
prior to 33eeb70011b34a3b04a74b2237d1d6fdde030c35

Change-Id: I4c30e6746a62e4035cf019b3186003498f7bdde3
2013-08-15 09:50:39 +01:00
67ad3dc892 convert include/svtools/imap*.hxx from String to OUString
Change-Id: Iacfb93a4cf9a7b7ac0ae27b9fa6f765e74604dc2
2013-08-15 09:11:37 +02:00
55f2f0864e convert include/svtools/parhtml.hxx from String to OUString
Change-Id: I20adfc9148b8afa7a59245349f233604bd9a1d2e
2013-08-15 09:11:35 +02:00
33eeb70011 convert include/svtools/svparser.hxx from String to OUString
Change-Id: I4d6196a9a96ad1dd236f8622a523b4702e92d76f
2013-08-15 09:11:33 +02:00