summaryrefslogtreecommitdiff
path: root/starmath
AgeCommit message (Collapse)Author
2016-06-10Pass it by const refTakeshi Abe
Change-Id: I0c2b48a503e2501210af690f02858dade994a733 Reviewed-on: https://gerrit.libreoffice.org/26048 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-06-09tdf#94698 cleanup Makefiles. Get rid of udkapi and offapiGleb Mishchenko
This patch changes occurences in makefiles from $(eval $(call gb_CppunitTest_use_api,comphelper_test_config, \ udkapi \ offapi \ )) to $(eval $(call gb_CppunitTest_use_sdk_api,comphelper_test_config)) (corrected instead of abandon, jani) Change-Id: Ic96ec65d82d7452e288f05a8b6d576ef543b068e Reviewed-on: https://gerrit.libreoffice.org/23426 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org> Tested-by: jan iversen <jani@documentfoundation.org>
2016-06-08remove "object is disposed" warning in OBroadcastHelperVar::removeListenerNoel Grandin
doesn't add anything of value. Change-Id: Ie2dea7c43570640284771c992d0072ab61de425e Reviewed-on: https://gerrit.libreoffice.org/25871 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-08starmath: The formula tree must be of type SmTableNodeTakeshi Abe
This also omits the last push & pop on m_aNodeStack at the end of parsing. Change-Id: Iefff8fa801ea7cb9015d6cba0d5a972dee675cb7 Reviewed-on: https://gerrit.libreoffice.org/26003 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-06-07starmath: Make ctors explicitTakeshi Abe
Change-Id: Ic1b7ce74f73bd41824e0af78675b4e18af32b1f5 Reviewed-on: https://gerrit.libreoffice.org/25960 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-06-06tools: rename SvStream::Read/Write to ReadBytes/WriteBytesMichael Stahl
Change-Id: Ib788a30d413436aa03f813aa2fddcbc4d6cd2f9a Reviewed-on: https://gerrit.libreoffice.org/25972 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-06-06Revert "Revert "Simplify sfx2 removing SfxModuleArr_Impl and dummy SfxModule ↵Noel Grandin
flag"" This reverts commit abde31a2bc68302e1afafe1fcc3f5d85369010f8. Since my analysis was completely incorrect, and the bug was elsewhere.
2016-06-06Revert "Simplify sfx2 removing SfxModuleArr_Impl and dummy SfxModule flag"Noel Grandin
This reverts commit e319ef1171dab61fff2201f5c1470ca09894c395. Apparently, at some point, someone added a 'bool bDummy' param to SfxModule, but only updated 2 of the 5 callsites. Since we're passing in pointers here, at the other call sites, the bDummy param evaluated to 'true'.
2016-06-06Simplify sfx2 removing SfxModuleArr_Impl and dummy SfxModule flagMark Page
The SfxModuleArr_Impl is a static container of SfxModule, since this is private to the SfxModule class it does not require wrapping. The bDummy flag is unused, and complicates the class Change-Id: Ib03b215543a0c37d4edf20b2d0fc141a783e115e Reviewed-on: https://gerrit.libreoffice.org/25859 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-06remove unused constants in HRC filesNoel Grandin
Change-Id: Ia034fb16ce75caeb69fd746d4a602cd5fcfef6d1 Reviewed-on: https://gerrit.libreoffice.org/25817 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-03Convert ComplexTextLayoutMode to scoped enumNoel Grandin
Change-Id: I257f8e15fec92f0701235a6fe4b6a2272498c4f1 Reviewed-on: https://gerrit.libreoffice.org/25667 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-03Null pointer dereferences must not happenTakeshi Abe
This is a follow-up of 09981cd6383ecb99e4b6c83b98b03af5cf3ff59b. Inspired by coverity#1362478 etc. Change-Id: If5507c52552393cccbb255cbf4b7e9f4b80db917 Reviewed-on: https://gerrit.libreoffice.org/25840 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-06-02coverity#1362478 Explicit null dereferencedCaolán McNamara
and coverity#1362479, coverity#1362480, coverity#1362481, coverity#1362482, coverity#1362483, coverity#1362485 Change-Id: Ia3a32b69bcbe5ac3e7cc50dacfa02e8bf1aab787
2016-06-02STREAM_STD_READ already includes StreamMode::NOCREATETakeshi Abe
Change-Id: Ib8c81056619a383cedc828b945c1802ff1ce42ca Reviewed-on: https://gerrit.libreoffice.org/25802 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2016-06-02Passing its const ref is sufficientTakeshi Abe
Change-Id: I85db4fcc3698d02ac6a7660042152092e6eeb99e Reviewed-on: https://gerrit.libreoffice.org/25752 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mark Page <aptitude@btconnect.com> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-31Use std::vector for SmCaretPosGraphTakeshi Abe
instead of employing ad hoc linked list and its iterator. Change-Id: Ibc4709a2e67aa805cf54117303c47d9a8a5eede9 Reviewed-on: https://gerrit.libreoffice.org/25699 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-05-31Prefix SmDocShell's membersTakeshi Abe
as well as remaning aInterpreter to maParser. Change-Id: I5f86737ffe05be981477e9dc65d433de0e1d5378 Reviewed-on: https://gerrit.libreoffice.org/25650 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-30starmath: Drop redundant IsFormulaArranged() checkTakeshi Abe
as ArrangeFormula() itself checks bIsFormulaArranged, and does nothing if it's on. Change-Id: Icc76208f6881d4de99e88feae5f19d7e8890e4e9 Reviewed-on: https://gerrit.libreoffice.org/25570 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-28starmath: Make some functions of SmDocShell publicTakeshi Abe
so that SmModel is no longer required to be a friend of SmDocShell. Change-Id: I7153a9ef13ae829710acf580ff0a9c30705aeb25 Reviewed-on: https://gerrit.libreoffice.org/25528 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-27starmath: Prefix members of SmSetSelectionVisitorTakeshi Abe
Change-Id: I3a5d195d65fe3a9b7b7859e3ad4c1d051628f44d Reviewed-on: https://gerrit.libreoffice.org/25491 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-26starmath: nodes in the clipboard are owened by SmClipboardTakeshi Abe
This also omits the bIsOnlyIfSelected parameter for former CloneLineToList(), which was true at its sole call site. Change-Id: Idb71323f68f13ecc90d430ec8e18e0eef766ae4b Reviewed-on: https://gerrit.libreoffice.org/25444 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-25(nearly) nothing uses GetUniqueId anymore, so remove it.Caolán McNamara
The odd one out is the usage in Formula, which attempts to restore focus to a particular window identified by an unique id. In this case restore focus by keeping a VclPtr to the desired window. Change-Id: I1dc335325c109d75745c6bba2e12662e6ae50638
2016-05-24starmath: Fix missing call of AnnotationSelection() for SmCursor::CopyTakeshi Abe
... with unit tests of Copy/Cut/Paste. Change-Id: I74dd6f235b52ef2c1388ea0d15d32af0fb30b2c8 Reviewed-on: https://gerrit.libreoffice.org/25362 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-23tdf#99984 render inferred mrow as group {}Regina Henschel
In case an element has no content, but has got an SmXMLRowContext, an empty group {} is inserted. The result is, that empty table cells are rendered without error, so that files, which use a mtable element to arrange things, no longer break on import. Change-Id: Iae158226e6478f2f9f397b8485044860ee8767c2 Reviewed-on: https://gerrit.libreoffice.org/25273 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org>
2016-05-23starmath: This should be an assert()Takeshi Abe
Change-Id: Ia8dd75512168fd0775a8019fc514627a7353b056 Reviewed-on: https://gerrit.libreoffice.org/25231 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-21starmath: These functions are used in local onlyTakeshi Abe
Change-Id: I603be0a0890844019700f402ae79203ddc86c952 Reviewed-on: https://gerrit.libreoffice.org/25186 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-19starmath: Assign the proper token to SmTableNodeTakeshi Abe
... for a similar motivation with b43b79648f4fbcd815092268d1b7a5af9e278f52. Change-Id: I9fc42fc8e34958295eeec5759c072c8259fc38b6 Reviewed-on: https://gerrit.libreoffice.org/25122 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2016-05-19loplugin:unusedmethods in slideshow to svtoolsNoel Grandin
Change-Id: Icf0056e13c88d7d347e668adaeddd4ed72af85cf Reviewed-on: https://gerrit.libreoffice.org/25141 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-18starmath: Remove obsolete TG::DiscardedTakeshi Abe
which was originally TGDISCARDED until cc1a0ba927ad6f85103059aa8e6108017f436304, and its usage was gone with 9adcd261054a0e99ae032be5e7428e28a6663975. Change-Id: Idb01f30b7b140b17deead7c5a83128fa1f3bdf4c Reviewed-on: https://gerrit.libreoffice.org/25074 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com>
2016-05-18Convert ATTR_* to scoped enumTakeshi Abe
Change-Id: Icbf19ca281c260ba0795c7a8e5745d1e603ac8a5 Reviewed-on: https://gerrit.libreoffice.org/25050 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-17convert TG constants to scoped enumNoel Grandin
Change-Id: Ide719e8bb0d5aacc8d5da18f385b6373c7e48184 Reviewed-on: https://gerrit.libreoffice.org/24973 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-16tdf#98238, tdf#99591 reverted old commitJan Iversen
Revert "tdf#53472 Integral Symbols too small for some integrands" This reverts commit 746633bd0315939fd5e0b50c90692d356d2ed678. Revert on request from regina, since this commit caused 2 new bugs. The code of the reverted patch is kept in the file for further investigation, once it has been confirmed that it works. The file had 3 commits later, these are not affected by this commit Change-Id: I5b24a9b88ac909c83115e8c8a430dc768c9effd4 Reviewed-on: https://gerrit.libreoffice.org/24898 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Regina Henschel <rb.henschel@t-online.de> Reviewed-by: jan iversen <jani@documentfoundation.org>
2016-05-16Avoid C-style castTakeshi Abe
Change-Id: I777920cb2e9dcc3f2b20f5a96c88bf48fcb94895 Reviewed-on: https://gerrit.libreoffice.org/25024 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-14Fix bogus nGroup for SmMatrixNode's tokenTakeshi Abe
It was an obvious mistake because TRGROUP's type is SmTokenType. Change-Id: Ib3b932482c61bd9568aa579d94f742d0dd0b5462 Reviewed-on: https://gerrit.libreoffice.org/24948 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-13Resolves: tdf#99556 if the num of arguments is not 1 infer a rawCaolán McNamara
not just if the num of arguments is > 1 Change-Id: If0cae16cc52685315708ac3b2b8456ede7c1a6ce
2016-05-13convert SHOWTRACK to scoped enumNoel Grandin
Change-Id: Ibf06f6c79f80d7265ae3239c1ea0088118e92e21 Reviewed-on: https://gerrit.libreoffice.org/24894 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-13starmath: SmMatrixNode should have the node TMATRIXTakeshi Abe
... rather than the one after its closing brace. So far having an arbitrary node is OK for SmMatrixNode because existing code does not refer to it, but it is saner to keep relevant nodes in the syntax tree. Change-Id: Ia5412454c996eedde1545cd8a2f323eb95593eb9 Reviewed-on: https://gerrit.libreoffice.org/24909 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-12Convert FLG_* to scoped enumTakeshi Abe
Change-Id: If767fff10a0bb28735578b4ec3dcf7b9e2d326a2 Reviewed-on: https://gerrit.libreoffice.org/24872 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-11clang-tidy modernize-loop-convert in scripting to svtoolsNoel Grandin
Change-Id: I98229d14109cf243839d632feabde1391ea9bad5 Reviewed-on: https://gerrit.libreoffice.org/24847 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-11starmath: Drop unused non-const variant of GetLeftMostTakeshi Abe
... resulting in one less const_cast. Change-Id: I3dad339f25524fc22e7a02b08ee7ec01b341e991 Reviewed-on: https://gerrit.libreoffice.org/24810 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-10Replace fallthrough comments with new SAL_FALLTHROUGH macroStephan Bergmann
...which (in LIBO_INTERNAL_ONLY) for Clang expands to [[clang::fallthrough]] in preparation of enabling -Wimplicit-fallthrough. (This is only relevant for C++11, as neither C nor old C++ has a way to annotate intended fallthroughs.) Could use BOOST_FALLTHROUGH instead of introducing our own SAL_FALLTHROUGH, but that would require adding back in dependencies on boost_headers to many libraries where we carefully removed any remaining Boost dependencies only recently. (At least make SAL_FALLTHROUGH strictly LIBO_INTERNAL_ONLY, so its future evolution will not have any impact on the stable URE interface.) C++17 will have a proper [[fallthroug]], eventually removing the need for a macro altogether. Change-Id: I342a7610a107db7d7a344ea9cbddfd9714d7e9ca
2016-05-10Simplify code with ForEachNonNullTakeshi Abe
Change-Id: Id149ecee4fa7737b529f3a3a19bb4bb9ed778dcd Reviewed-on: https://gerrit.libreoffice.org/24778 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-09modernize loopsJochen Nitschke
use one style (reverse_iterators) for reverse loops and use range base loops if possible Change-Id: I231572bc5923e450d7a54bb88c7d8ef63d04f41d Reviewed-on: https://gerrit.libreoffice.org/24758 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com>
2016-05-08starmath: Drop useless last entry of aTokenTableTakeshi Abe
Change-Id: I3189c875cc8b2046f5a0353fb641a7d6ea9fdd9a Reviewed-on: https://gerrit.libreoffice.org/24692 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2016-05-04use Any constructor instead of temporariesNoel Grandin
Change-Id: Iffb82a2cee1a28d89eeea2b905aaa14086ee475a
2016-05-04While at it, delete Any functions on sal_Bool*Stephan Bergmann
(at least for LIBO_INTERNAL_ONLY), to help further reduce the occurrences of sal_Bool across the code base Change-Id: I70654a0cb56655984c717b7b894f26c9ab47536e
2016-05-03Prevent Any::setValue from reinterpreting bool* as sal_Bool*Stephan Bergmann
...which only happens ot work in environments where sizeof (bool) == 1. The simpler alternative is to use the operator <<= template without passing explicit UNO type information, anyway. The std::nullptr_t overloads are needed to disambiguate calls with a nullptr argument. (Which can at least be meaningful for VOID, but for other types what it happens to do is store a default value of the given type.) As std::nullptr_t is only C++11, this all needs to be LIBO_INTERNAL_ONLY. Change-Id: Iff06a6ba94250bd4ae4afc937c2a2bfa75f0888f
2016-05-03starmath: Avoid C-style castTakeshi Abe
Change-Id: If8fdb9def831ea9720c3cad1379be47aba7dec30 Reviewed-on: https://gerrit.libreoffice.org/24584 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2016-05-03use Any constructor for bool values, instead of temporary varsNoel Grandin
mostly found with: git grep -n 'setValue.*cppu.*UnoType.*bool.*get' Change-Id: Ie8e5aa6402d25dbe90b0f492031a245bb222c1a5 Reviewed-on: https://gerrit.libreoffice.org/24464 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-02Fix typoTakeshi Abe
Change-Id: Ib8e891f3af7a9de87c54bc65be98d94a16545d71