summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-07-21Eliminate DateTime::operator+=() and -=() with POD typesEike Rathke
And make some tools::Time conversion ctors explicit to catch more oddities like automatic conversion from sal_Int64 that might be unintentional. Change-Id: If275297d86d6657544c056a712b862523e310e44 Reviewed-on: https://gerrit.libreoffice.org/40275 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
2017-07-21loplugin:constparams in soltools and variousNoel Grandin
Change-Id: I5e8e4a9a31aa7c3ff54cc7ce137d08770ea297e1 Reviewed-on: https://gerrit.libreoffice.org/40279 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-21fix python2 assumptionCaolán McNamara
Change-Id: I2113f64bac9f1e7421416266d20004b35ddbc54b
2017-07-21loplugin:subtlezeroinitTor Lillqvist
Change-Id: I52780b012a1e5a382e2245fb1d857e64322bee4a
2017-07-21update credits - with aliases fixedChristian Lohmaier
Change-Id: I486428da5459e758d23dd58b189b539896886c4c
2017-07-21Fix typosAndrea Gelmini
Change-Id: I43f38b4dda6b1999d84d9f9760d0fae4c0358394 Reviewed-on: https://gerrit.libreoffice.org/40277 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2017-07-21further bodge bad translations with mismatching starting newlinesCaolán McNamara
Change-Id: I91d559596dcfbca603613bc4e9db7fe3348984c6
2017-07-21fix up some mismatching msgstr vs msgid trailing newlinesCaolán McNamara
these are broken (from msgfmt's perspective anyway) already in our translations and pootle warns about them Change-Id: I9ce7c651273e334ecb92a592397886e2b95907da
2017-07-21add msgctxt to new stringsCaolán McNamara
Change-Id: I3a0a7620c9ed0aec438d149bee80c6979b0a3bd7
2017-07-21give formula .uis their translation domainCaolán McNamara
Change-Id: I9fe10986270117495628817b56ddf31f9f315454
2017-07-21update creditsChristian Lohmaier
Change-Id: I3d2a7bd97c085c68dc5036b6cb3731c24ed63aa2
2017-07-21call to non-constexpre functionCaolán McNamara
Change-Id: I31f5a23e0f328273b8a165e58863b771853f3d3c
2017-07-21loplugin: literaltoboolconversionCaolán McNamara
Change-Id: I675a29185c0401a8462ece17f70db82d188a53c5
2017-07-21update lo-xlate-lang for "kurdish"/kurmanji, amharic and guaraniRene Engelhard
Change-Id: Ie433614e074da0034ed532ed4569ef3648e48267
2017-07-21use old translations for interim periodCaolán McNamara
Change-Id: I81af71041d8d9d0074c9585ced510d7daab07c20
2017-07-21replace localestr with a script for the supported translation targetsCaolán McNamara
Change-Id: Ia0c00f6f978428d68b3c53051e26e1913b207dbe
2017-07-21loplugin:oncevarTor Lillqvist
Change-Id: I6b9492b3abb25bc546d672626d438cbd407c8c0f
2017-07-21despite the comment and missing translation, REDLINE undo comment gets usedCaolán McNamara
during CppunitTest_sw_tiledrendering at least Change-Id: I0de400443858926d7e2041934bbab61ade214c71
2017-07-21Eliminate Date::operator+=() and -=() and replace with Date::AddDays()Eike Rathke
Clarifies code and gets rid of explicitly casting the operand to sal_Int32. Also in preparation of removing DateTime::operator+=(sal_Int32) that is confusingly similar to DateTime::operator+=(double) and just depends on type. Change-Id: I83422e2940fbb017978db9b5734b4966228af3de Reviewed-on: https://gerrit.libreoffice.org/40248 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com>
2017-07-21tdf#108867 sw: fix dangling text box frame format pointers in UndoMichael Stahl
If the text box is removed, the SwFrameFormat of the drawing shape still retains a pointer to the frame SwFrameFormat, and the latter is owned by the SwUndoFlyBase. This is pretty bad, so try to clear & reset the connection between them in SwUndoFlyBase::InsFly() and DelFly(). Hopefully nothing will actually delete the drawing shape SwFrameFormat while the Undo object is alive. Note that when the SwUndoInsLayFormat is created when the text box is added, the GetOtherTextBoxFormat() returns null as it's set later, that's why the constructor can't do anything. Change-Id: Iae562b6f8f272e47b2b5cf8ee80778db15d29ce0
2017-07-21xmloff: don't warn on future LO versions, SAL_INFO is enoughMichael Stahl
Change-Id: I43d28a0957556900102cf87f024174d5c451a01d
2017-07-21fix strings that started with %PRODUCTNAME turning into PRODUCTNAMECaolán McNamara
Change-Id: I9ee596c7cde3d885f401447d6c10e7e30b958af7
2017-07-21loplugin:constparams in sfx2Noel Grandin
Change-Id: Id982c8fb5654433e9db10e2da6a86a6c8d90b9b4 Reviewed-on: https://gerrit.libreoffice.org/40261 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-21temporarily survive missing translationsCaolán McNamara
Change-Id: I19c27e524d2ad1e57fa3ca41b1bfaed17215bd76
2017-07-21make sure the strings for each undo matchCaolán McNamara
Change-Id: I6d380dde0214b41535e99798c24b19fe21e30772
2017-07-21can use the "real" type for RES_SRCTYPES nowCaolán McNamara
Change-Id: Ied1f7a8c4135d3fd6a4581ea5e92f89b2e6b3067
2017-07-21oox: fix inconsistent param naming in interface/implementationMiklos Vajna
Make sure they match. Change-Id: Ib3ce948a29472281705e361792c924893ad97b32 Reviewed-on: https://gerrit.libreoffice.org/40259 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2017-07-21don't build localestr when cross-compilingCaolán McNamara
Change-Id: Ia776d159aecc3082f46efe5bdd46477b45576b31
2017-07-21loplugin:unusedfields in sdNoel Grandin
Change-Id: I7f89e038f3d9bd0da658c7d3b8faec23d8a593db Reviewed-on: https://gerrit.libreoffice.org/40257 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-21loplugin:unusedfields in sfx2Noel Grandin
Change-Id: Id6666065bf3b27388d87aa2605229e83f1aed79a Reviewed-on: https://gerrit.libreoffice.org/40255 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-21de-hrc various thingsCaolán McNamara
e.g. helpid[s].hrc -> helpids.h and insert include guards where missing move "ordinary" defines into .hxx files remove .hrc entries that are used as arguments to dialog factory when a dedicated method can be added instead Change-Id: I792fb8eb0adfaa63cf354e6e57401fc943e9196e
2017-07-21migrate to boost::gettextCaolán McNamara
* all .ui files go from <interface> to <interface domain="MODULE"> e.g. vcl * all .src files go away and the english source strings folded into the .hrc as NC_("context", "source string") * ResMgr is dropped in favour of std::locale imbued by boost::locale::generator pointed at matching MODULE .mo files * UIConfig translations are folded into the module .mo, so e.g. UIConfig_cui goes from l10n target to normal one, so the res/lang.zips of UI files go away * translation via Translation::get(hrc-define-key, imbued-std::locale) * python can now be translated with its inbuilt gettext support (we keep the name strings.hrc there to keep finding the .hrc file uniform) so magic numbers can go away there * java and starbasic components can be translated via the pre-existing css.resource.StringResourceWithLocation mechanism * en-US res files go away, their strings are now the .hrc keys in the source code * remaining .res files are replaced by .mo files * in .res/.ui-lang-zip files, the old scheme missing translations of strings results in inserting the english original so something can be found, now the standard fallback of using the english original from the source key is used, so partial translations shrink dramatically in size * extract .hrc strings with hrcex which backs onto xgettext -C --add-comments --keyword=NC_:1c,2 --from-code=UTF-8 --no-wrap * extract .ui strings with uiex which backs onto xgettext --add-comments --no-wrap * qtz for gettext translations is generated at runtime as ascii-ified crc32 of content + "|" + msgid * [API CHANGE] remove deprecated binary .res resouce loader related uno apis com::sun::star::resource::OfficeResourceLoader com::sun::star::resource::XResourceBundleLoader com::sun::star::resource::XResourceBundle when translating strings via uno apis com.sun.star.resource.StringResourceWithLocation can continue to be used Change-Id: Ia2594a2672b7301d9c3421fdf31b6cfe7f3f8d0a
2017-07-21osl: Unix pipe converted from OSL_ASSERT to assert/SAL_WARNsChris Sherlock
Explanation for each conversion: - osl_acceptPipe() - don't worry about an invalid oslPipe sent as function parameter an error gets flagged in Unix normally, so it might not be a programming error - definitely assert on an empty name, that's a definite programming error and should never, ever occur - createPipeImpl() allocates and initializes memory for the oslPipeImpl structure, if it can't do this then something has been done wrongly - osl_receivePipe() - invalid oslPipe sent as function parameter might not be a programming error, give a warning but don't assert - osl_sendPipe() - invalid oslPipe sent as function parameter might not be a programming error, give a warning but don't assert - osl_writePipe() - really just a thin wrapper around osl_sendPipe(), which detects and handles invalid pipes - osl_readPipe() - really just a thin wrapper around osl_receivePipe(), which detects and handles invalid pipes Change-Id: I4923265b4c648852743c406b682d43ffb9ac6537 Reviewed-on: https://gerrit.libreoffice.org/40003 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2017-07-21osl: fix Pipe noacquire/acquire testsChris Sherlock
There is an incomplete test of ::osl::Pipe::Pipe(oslPipe, __sal_NoAcquire), but the comments show that the tester wasn't able to figure out a way to test the noacquire variant of this constructor. However, they seem to have not just given up but copied and pasted the acquire and no acquire tests - the error codes for the acquire test talk about non-acquisition and don't actually see if the handle is the same or not. I have fixed this test. To test if the noacquire is working or not then you merely have to: 1. create a new Pipe instance 2. create a new Pipe non-acquired instance copy of the first instance 3. delete the non-acquired instance copy 4. try to send a single character to the original Pipe instance, which should return an error (negative return result) because at this point there is no valid pipe to operate on as the pipe should have been destroyed when you deleted the copy. If the send() succeeds, then this is a test failure. For the acquire test, it didn't actually test if the handles are the same - I have corrected this now. Change-Id: If868746233d3a222cc6f9e7cd0d453e70ef6c7cc Reviewed-on: https://gerrit.libreoffice.org/40102 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2017-07-21loplugin:unusedfields in svtoolsNoel Grandin
Change-Id: I5484fe5ee449e72919591bd374366aa60f792e28 Reviewed-on: https://gerrit.libreoffice.org/40254 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-21loplugin:unusedfields in svxNoel Grandin
Change-Id: I7fc5bf55b01d464815771220914f21d8e85b5a36 Reviewed-on: https://gerrit.libreoffice.org/40253 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-21loplugin:constparams in svgioNoel Grandin
Change-Id: I35dd8b1373ce3c46a10b1da1ddc6dc3722ffa760 Reviewed-on: https://gerrit.libreoffice.org/40245 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-21Remove unused function code special charactersAkshay Deep
Change-Id: I6610a986795c3169077b9c1a8e65a86f5488243d Reviewed-on: https://gerrit.libreoffice.org/40230 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Akshay Deep <akshaydeepiitr@gmail.com>
2017-07-21tdf#43157 - Clean up OSL_ENSURE and OSL_FAIL in sc/filter/lotusAlbert Thuswaldner
Change-Id: I88e794752dff1bd46faac71234322d603c10bed9 Reviewed-on: https://gerrit.libreoffice.org/40075 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-07-21Moving legacy contexts to FastContexts:Mohammed Abdul Azeem
ScXMLTableShapesContext ScXMLTableSourceContext ScXMLTableColContext ScXMLTableColsContext ScXMLConditionalFormatsContext ScXMLTableProtectionContext Change-Id: I36704c7f51cd5d13b3c0ebf9bc07b172c1576f3e Reviewed-on: https://gerrit.libreoffice.org/40246 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org>
2017-07-20Added Test to check TableAutoFormat Style after Save/LoadVarun Dhall
Change-Id: I466d5c5536d4c4310356f38569f7a91e0f36ba1d Reviewed-on: https://gerrit.libreoffice.org/40104 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2017-07-20tdf#46852 fix spellcheck continue at beginningLuke Deller
When a spellcheck reaches the end of the document, it is supposed to be able to continue from the beginning of the document to the point at which the spellcheck was started. This was not working in the case where the word at the starting position was replaced due to a spelling correction, which causes the starting position to be lost. Fix this situation by recording the position immediately *before* the spellcheck starting position, so that it will not be affected by a spelling correction *at* the starting position. Change-Id: I9483fd5937dc1e235f6f9639d4856fe15e3d47a6 Reviewed-on: https://gerrit.libreoffice.org/40123 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2017-07-20change some Date += long to Date += sal_Int32Jochen Nitschke
found by adding Date& operator+=(long) = delete; to Date class Change-Id: I0e6b59a2e789f2bdf2f271b99d10c6acbae8bf55 Reviewed-on: https://gerrit.libreoffice.org/40241 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-20tdf#109197 crash when deleting user field variables in swNoel Grandin
regression from: commit a706bb06d5326e7a997dd1d71f3f947bd0ad28e6 "new loplugin: useuniqueptr: sw part 1" Change-Id: I57f9c9e6d7eeccc033b71d7182c960f3d79df73c Reviewed-on: https://gerrit.libreoffice.org/40240 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Jenkins <ci@libreoffice.org>
2017-07-20tdf#107166 improve AA mode selection, retry, more checksTomaž Vajngerl
Major problem when setting the render mode and the text antialias mode is that when you set the render mode to something that isn't compatible with the text antialias mode, then every next call will cause an error (invalid parameters). So we need to be sure that we never set incompatible modes. Additionally we just need to set it one time when we create the surface and not every time we draw. If we get the D2DERR_RECREATE_TARGET we can create a new render target and retry the whole call. Somethimes this is not possible so we try 3 times and the give up. We need to add more checks where we exit early or not continue with some calls as any additional calls could taint the draw state and some things wouldn't be drawn. For example if we calculate the sizes of 0 glyphs we shouldn't continue with binding the hDC with an "empty" rectangle. This will fail and cause some text that is called afterwards to not draw. Change-Id: Iabbdbd7956e90ea84aea96824c0d985ca9020c59 Reviewed-on: https://gerrit.libreoffice.org/40211 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2017-07-20tdf#109123 WIN Run instant timerout with low priorityJan-Marek Glogowski
This busy-lock happens, because user messages have a higher priority then some system messages. What happens: 1. The main system loop picks up the LO scheduler 2. The idle worker (IW) is started 3. IW checks using AnyInput( VCL_INPUT_ANY ) for system events 4. A system event is found 5. The LO scheduler gets posted again 6. The main system loop picks up the LO scheduler instead of the system message => goto 2 Normally it's suggested to use WM_TIMER in this case, as these messages are supposed to have the lowest priority. But this doesn't work, if you use PostMessage to generate them and SetTimer doesn't accept a 0ms timeout. At least PeakMessage also picks up the WM_TIMER message before the system message, probably because PostMessage is somehow related to the threads queue - who knows. In the end this implements a manual, low priority event, which is checked at the end of the ImplSalYield function. It just runs, if there is nothing else to do. We still have to emit the timer callback event, as ImplSalYield may wait in GetMessage, but wParam now indicates, if it's a wakeup and can be ignored. We use the same event, so it's easier to filter. Thanks to Mike Kaganski for the missing information and ideas for the final implementation. Change-Id: Ib8e4f214ab8d3731d5594d68f38f46982c2eb36d Reviewed-on: https://gerrit.libreoffice.org/40190 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2017-07-20Change url for Help onlineOlivier Hallot
When the localhelp is not installed, the help is currently served by wikihelp http://help.libreoffice.org This patch makes the help pages to be served by http://helponline.libreoffice.org/index.html? + params index.html parses the params and opens the right help page. Params passed are - module (swriter,scalc,...) detected just after /text/ - HelpID is converted to valid url by bookmark2file.js - valid url is rebuild then and new contents opens on _self. Notes: * once in the website, navigation does not come back to index.html * index.html also redirect if visitor comes from elswhere Change-Id: Iab0797f64024900f906c8127d275de706ba35942 Reviewed-on: https://gerrit.libreoffice.org/39264 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2017-07-20tdf#87914 Add small caps command to Format menuYousuf Philips
Change-Id: I6c1faa610d41918501e7111cd447050329b9d8e7 Reviewed-on: https://gerrit.libreoffice.org/39421 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2017-07-20Move namespace declaration to header fileSamuel Mehrbrodt
Change-Id: I5388d649ff3c8da0ff055f4aed6036647a123939 Reviewed-on: https://gerrit.libreoffice.org/40130 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2017-07-20tdf#109228: FILESAVE: ODT: Anchor changed to 'to character' after RTTamás Zolnai
Ignore frames without names, becuase the code does not handle them well. It does not affect those use case for which the deduplication code was added. Change-Id: I08ad062b8b11cc06323467329d8c4e97bc4932dd Reviewed-on: https://gerrit.libreoffice.org/40222 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>