summaryrefslogtreecommitdiff
path: root/starmath
AgeCommit message (Collapse)AuthorFilesLines
2017-09-24Adjust DockingWindow layout calculation, tdf#106762 prepMaxim Monastirsky1-1/+0
This is needed for the color widget to have the correct size at initial show, and to keep this size after selecting a different palette. The parent FloatingWindow will assume that the border width stays outside the space that was allocated to the DockingWindow (see VclContainer::setLayoutPosSize), and yet DockingWindow tries to handle the border width as part of its allocated space. One option could be to let FloatingWindow handle this alone, but this won't work for other possible parents. The current solution is to load and store the border width in a way that can be used internally, but not visible to the outside world via get_border_width(). Change-Id: Id51152cf64eef719368e29253eb93e99834489cd
2017-09-23loplugin:flatten in sdext..stocNoel Grandin1-57/+51
Change-Id: I460e813e20a691c53738373376d3363f553bbab2 Reviewed-on: https://gerrit.libreoffice.org/42636 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-09-22Fresh run of bin/update_pch.shMike Kaganski1-33/+19
Change-Id: I69d4157aaf6570cecd51ea59df20556914942e06 Reviewed-on: https://gerrit.libreoffice.org/42565 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2017-09-22ofz: don't leak in face of exceptionsCaolán McNamara1-36/+34
Change-Id: Ic15590a13bd3770ee5dd7db76b21c830a4fe73e2 Reviewed-on: https://gerrit.libreoffice.org/42587 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-09-21Rename GetSelectEntryPos -> GetSelectedEntryPosSamuel Mehrbrodt2-2/+2
Change-Id: I0bd4cb463575af843c72d9c8aaf91742203532a4 Reviewed-on: https://gerrit.libreoffice.org/42283 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-09-21Rename GetSelectEntry -> GetSelectedEntrySamuel Mehrbrodt2-9/+9
Change-Id: Ibb7d8c59c0e61b0e87455bd78f241d8691dd9dce Reviewed-on: https://gerrit.libreoffice.org/42282 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-09-17valgrind: Conditional jump or move depends on uninitialised valueCaolán McNamara1-1/+1
Conditional jump or move depends on uninitialised value(s) at 0x4C3535E: strstr (vg_replace_strmem.c:1623) by 0x4FCD9E59: SmFilterDetect::detect(com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue>&) (smdetect.cxx:102) by 0x41A1A774: filter::config::TypeDetection::impl_askDetectService(rtl::OUString const&, utl::MediaDescriptor&) (typedetection.cxx:1038) Change-Id: I2f98fd3f7799f34cb5bd9242379ce6440645034d Reviewed-on: https://gerrit.libreoffice.org/42381 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-09-15Moved Math/Font-Size dialog buttons to the bottomAndreas Brandner1-24/+25
Change-Id: Iac1bd80836d42a136823bafb2290d32c693e0de5 Reviewed-on: https://gerrit.libreoffice.org/42316 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-09-13Fraction: make conversion operators and constructor explicitNoel Grandin1-2/+2
and simplify some of the calculations that needed to be changed. Which resulted in one unit test needing to change by one pixel, let's hope not an indication of a real problem. Change-Id: Ie56434f35f4e58d21ee6f671392e93dc7542fca3 Reviewed-on: https://gerrit.libreoffice.org/42240 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-09-08set parent for file dialog helperCaolán McNamara1-1/+1
Change-Id: I3994ee48dcb5b2732cb27cb9ccb54926abf0828a Reviewed-on: https://gerrit.libreoffice.org/42048 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-09-06tdf#101876 Math Fonts dialog: moved buttons to bottom of dialogAndreas Brandner1-28/+29
Change-Id: I588d9a9f2c87e57bc596cdcae823834f500c7d67 Reviewed-on: https://gerrit.libreoffice.org/41984 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2017-09-04loplugin:unnecessaryparen include c++ castsNoel Grandin1-2/+2
Change-Id: I132d3c66f0562e2c37a02eaf4c168d06c2b473eb Reviewed-on: https://gerrit.libreoffice.org/41874 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-08-28Translate German comments/debug strings (leftovers in dirs starmath to sysui)Johnny_M1-1/+1
Translates leftovers found using a custom regex. Additionally translated: - One randomly found comment in /reportdesign - Test strings in /stoc/test (let's see if it works) Change-Id: I5f893c194c4b56b5365700928a3b8b63936d03e2 Reviewed-on: https://gerrit.libreoffice.org/41583 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2017-08-22tdf#108706 Unify loading document progress bar labelTakeshi Abe2-3/+3
This also reduces the number of strings to be translated. Change-Id: I032ba12c1e762ee3851658d439dfe2c81c6bd34f Reviewed-on: https://gerrit.libreoffice.org/41329 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2017-08-17remove UL/L suffixes from integer constants on the RHS of expressionsNoel Grandin1-2/+2
Change-Id: I899a8126c9d971601fea6c77eca165718aea0ac5 Reviewed-on: https://gerrit.libreoffice.org/41237 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-08-17remove UL/L suffixes from integer constants in initialiser/call expressionsNoel Grandin2-2/+2
Change-Id: Iae081567c4fa5b88edbd12cf2fbafd2b8f31b300 Reviewed-on: https://gerrit.libreoffice.org/41214 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-08-03loplugin:constparams in starmathNoel Grandin14-33/+33
Change-Id: Iac470b572311241216622f22bc543c0bd10a28f6 Reviewed-on: https://gerrit.libreoffice.org/40714 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-08-03loplugin:checkunusedparams in variousNoel Grandin2-221/+99
Change-Id: I4f54940a9ebdcd47776b2a5f7bae6e49b633ee44 Reviewed-on: https://gerrit.libreoffice.org/40706 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-08-03starmath: cleanup includes with iwyuJochen Nitschke34-154/+34
Change-Id: I6de145f8b59d3ebcbc0cb32df3f955c9ee738eeb Reviewed-on: https://gerrit.libreoffice.org/40666 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-08-02remove unnecessary use of 'this->'Noel Grandin1-2/+2
Change-Id: I5c115389af7d24c18ddaf5fbec8c00f35017a5b4 Reviewed-on: https://gerrit.libreoffice.org/40671 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-08-01move resmgr to unotoolsCaolán McNamara1-2/+2
and the vast majority of translations is to the ui language so default ctor with that arg and now drop OModuleResourceClient Change-Id: I3b85a560ffdfe5f019c2271ac56a5fe4a361522b
2017-07-31starmath, sw: fix inconsistent param naming in interface/implementationMiklos Vajna1-1/+1
At least some of them. Change-Id: I69d4b0b000efec863bf66e9719b57e881ff23689 Reviewed-on: https://gerrit.libreoffice.org/40596 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2017-07-31loplugin:oncevarNoel Grandin1-3/+3
extend oncevar to any POD type Change-Id: Ia98ee0a67f183e40fb0c38477760124b2c411dc0 Reviewed-on: https://gerrit.libreoffice.org/40564 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-26loplugin:unusedmethodsNoel Grandin2-10/+1
Change-Id: I7f26ee112ed89ee3e69c56930260565f66ff145b Reviewed-on: https://gerrit.libreoffice.org/40442 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-26convert SfxGroupId to scoped enumNoel Grandin1-30/+30
in the process I had to teach the idl compiler to cope with identifiers like SfxGroupID::Math, which has the side effect of requiring a space before a ':' in some of the .sdi files. Change-Id: If256599cb8aa1dfc0a33642c5070c5560702f3ba Reviewed-on: https://gerrit.libreoffice.org/40441 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-25loplugin:unusedmethodsNoel Grandin2-9/+0
Change-Id: Ia874baf21257e5fe41e104211068a2bcc50446eb Reviewed-on: https://gerrit.libreoffice.org/40391 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-25tdf#109304: Seems infobar child window wasn't registered in MathKatarina Behrens1-0/+2
thus no signature status infobar appeared (I wonder if read-only bar ever worked too) Change-Id: I8829b2b6a17fb8d38e3ea79b87d544e3fb29f1c1 Reviewed-on: https://gerrit.libreoffice.org/40377 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-07-21de-hrc various thingsCaolán McNamara5-8/+3
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 McNamara42-2251/+779
* 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-14 use more OUString::operator== in sfx2..svtoolsNoel Grandin3-9/+8
Change-Id: I859b77319f551eabd19dae54bd69c212221112a8 Reviewed-on: https://gerrit.libreoffice.org/39938 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-13loplugin:oncevar: empty strings: starmathStephan Bergmann1-3/+1
Change-Id: I01750964033db223a5f4bd5d0820a7bfb97d4f3d
2017-07-10teach unnecessaryparen loplugin about identifiersNoel Grandin2-3/+3
Change-Id: I5710b51e53779c222cec0bf08cd34bda330fec4b Reviewed-on: https://gerrit.libreoffice.org/39737 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-07loplugin:unnecessaryparen handle parens inside call exprNoel Grandin1-1/+1
stick to single-arg function calls, sometimes parens in multi-arg calls might be there for clarity Change-Id: Ib80190c571ce65b5d219a88056687042de749e74 Reviewed-on: https://gerrit.libreoffice.org/39676 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-05new loplugin unnecessaryparenNoel Grandin3-6/+7
Change-Id: Ic883a07b30069ca6342d7521c8ad890f4326f0ec Reviewed-on: https://gerrit.libreoffice.org/39549 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-04tdf#105831 Add Donate entry on Help menuOlivier1-0/+2
The full implementation depends on infra Task #2179 https://redmine.documentfoundation.org/issues/2179 revision1: change to https, per demand of #2179 Removed ellipsis Code changed as suggested Change call to pass BCP47 string, with language as fallback. task #2179 will be reviewed accordingly. Change-Id: I573542da0f394d7128faab0106df852d622c98b3 Reviewed-on: https://gerrit.libreoffice.org/34693 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
2017-07-03loplugin:unusedfields in slideshow..svtoolsNoel Grandin3-8/+1
Change-Id: I74d5a4b8cfc4b18267f99648a3112b163c91fd8c Reviewed-on: https://gerrit.libreoffice.org/39474 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-02loplugin:casttovoid: starmathStephan Bergmann1-1/+0
Change-Id: I39dd0d8d146f6af4f725f8954185df1a4222ff57
2017-06-27xmloff: remove duplicate XML_NAMESPACE_##prefix##_IDX macrosMichael Stahl1-2/+2
Why do we need 2 identical constants? Change-Id: Ib969f9b9583261f26fe65e04f183bdfabcb9eefe
2017-06-27loplugin:oncevar in starmath..svlNoel Grandin7-25/+16
Change-Id: I20e3796407c7e429a88d2811673929ac1141a41c Reviewed-on: https://gerrit.libreoffice.org/39280 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-26Fix typosAndrea Gelmini1-1/+1
Change-Id: I2ce725f87ee6f8ebcffbac268cc7e7f8850023e5 Reviewed-on: https://gerrit.libreoffice.org/39232 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-06-21loplugin:unusedfields in sfx2 part1Noel Grandin1-1/+0
and fix a memory leak in NotebookbarTabControl where it was not freeing it's m_pListener field Change-Id: Ib9970c9084982d532fa38d1bc3c44180ab2c3c39 Reviewed-on: https://gerrit.libreoffice.org/39036 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-21convert ErrCode to strong typedefNoel Grandin4-10/+10
would have preferred to re-use o3tl::strong_int, of which this is a modified copy, but there are lots of convenience accessors which are nice to define on the class. Change-Id: I301b807aaf02fbced3bf75de1e1692cde6c0340a Reviewed-on: https://gerrit.libreoffice.org/38497 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-19Make SfxItemSet ranges correct by construction: Fix static casesStephan Bergmann2-19/+12
...with the aid of an extended compilerplugins/clang/store/sfxitemsetrewrite.cxx (which in turn needed a small addition to compilerplugins/clang/check.hxx). Enable svl::detail::validGap check for the static case, but keep it disabled for now for the dynamic case. Change-Id: I4846ba8e99aff94a86518e2cb5044e575093386e
2017-06-18remove unused osl/mutex.hxx includesJochen Nitschke6-6/+0
Change-Id: I3b50e45fdb99e9cd8bfda07356ee3ddb4dd0f8bb Reviewed-on: https://gerrit.libreoffice.org/38905 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
2017-06-17TransferableObjectDescriptor::mnOle2Misc field is unusedNoel Grandin2-7/+0
which means that SfxObjectShell::GetMiscStatus becomes unused Change-Id: I5c89a2cd5c77c7f08a57fdac08237aab514fc7fa Reviewed-on: https://gerrit.libreoffice.org/38843 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-16Make SfxItemSet ranges correct by constructionStephan Bergmann4-11/+9
This is a follow-up to 45a7f5b62d0b1b21763c1c94255ef2309ea4280b "Keep WID ranges sorted, and join adjacent ones". While SfxItemSet::MergeRange relies on the m_pWhichRanges being sorted (and, under DBG_UTIL, asserts if they are not), the various SfxItemSet constructors curiously only check (via assert or DBG_ASSERT) that each individual range has an upper bound not smaller than its lower bound. Arguably, all SfxItemSet instances should fulfill the stronger guarantees required and checked by MergeRange. And in many cases the ranges are statically known, so that the checking can happen at compile time. Therefore, replace the two SfxItemSet ctors taking explicit ranges with two other ctors that actually do proper checking. The (templated) overload taking an svl::Items struct should be used in all cases where the range values are statically known at compile time, while the overload taking a std::initializer_list<Pair> is for the remaining cases (that can only do runtime checking via assert). Most of those latter cases are simple cases with a single range covering a single item, but a few are more complex. (At least some of the uses of the existing SfxItemSet overload taking a const sal_uInt16* pWhichPairTable can probably also be strengthened, but that is left for another day.) This commit is the first in a series of two. Apart from the manual changes to compilerplugins/clang/store/sfxitemsetrewrite.cxx, include/svl/itemset.hxx, and svl/source/items/itemset.cxx, it only consists of automatic rewriting of the relevant SfxItemSet ctor calls (plus a few required manual fixes, see next). But it does not yet check that the individual ranges are properly sorted (see the TODO in svl::detail::validGap). That check will be enabled, and the ensuing manual fixes will be made in a follow-up commit, to reduce the likelyhood of accidents. There were three cases of necessary manual intervention: * sw/source/core/unocore/unostyle.cxx uses eAtr of enum type RES_FRMATR in braced-init-list syntax now, so needs explicit narrowing conversion to sal_uInt16. * In sw/source/uibase/uiview/formatclipboard.cxx, the trailiing comma in the definition of macro FORMAT_PAINTBRUSH_FRAME_IDS needed to be removed manually. * In svx/source/svdraw/svdoashp.cxx, svx/source/svdraw/svdotext.cxx, sw/source/uibase/app/docstyle.cxx, sw/source/uibase/shells/frmsh.cxx, sw/source/uibase/shells/grfsh.cxx, and sw/source/uibase/shells/textsh1.cxx, some comments had to be put back (see "TODO: the replaced range can contain relevant comments" in compilerplugins/clang/store/sfxitemsetrewrite.cxx). A few uses of the variadic form erroneously used nullptr instead of 0 for termination. But this should have been harmless even if promoted std::nullptr_t is larger than promoted sal_uInt16, assuming that the part of the nullptr value that was interpreted as sal_uInt16/promoted int was all-zero bits. Similarly, some uses made the harmless error of using 0L instead of 0. Change-Id: I2afea97282803cb311b9321a99bb627520ef5e35 Reviewed-on: https://gerrit.libreoffice.org/38861 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2017-06-16starmath: SfxObjectShell::GetMiscStatus() returns sal_uIntPtrTakeshi Abe2-2/+2
Change-Id: I2a4fa44414975e7b87c8313d01d7120d13a205e6 Reviewed-on: https://gerrit.libreoffice.org/38790 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
2017-06-14use ERRCODE_NONE instead of 0Noel Grandin4-5/+5
peeling off a small chunk of my ErrCode strong_int conversion Change-Id: Idc89e8496083beed7608cba705cd981139eb7111 Reviewed-on: https://gerrit.libreoffice.org/38777 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-14Let CreateItemSet return unique_ptrStephan Bergmann2-4/+7
...and address resulting loplugin:useuniqueptr Change-Id: Ia79eb8d59ce5092b2d93b656eab687096baedf17
2017-06-14starmath: Use sal_uInt32 for ERRCODE instead of sal_uLongTakeshi Abe3-10/+10
Change-Id: I9fab0cdc29cf10551b31619cbcbf7f304eeb3b69 Reviewed-on: https://gerrit.libreoffice.org/38729 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>