summaryrefslogtreecommitdiff
path: root/sc
AgeCommit message (Collapse)Author
2017-07-15emfplus: create a wmf/emf/emf+ primitive based importerArmin Le Grand
First steps to organize an importer that can read/interpret wmf/emf/emf+ and deliver a primitive representation for the content by parsing it. Use the same mechanisms as already applied for Svg, so to reuse abilities to keep original binary data to allow save again and embedding in files and have an implemented replacement bitmap based representation. For this, unify the used helper classes to handle more than just Svg. For 1st try, add test code and static bool switches Change-Id: I6e0a82943541d811a8f8d65a84115569fcd8cee7
2017-07-14implement Application.FileDialog attributeTamas Bunth
Documentation: https://msdn.microsoft.com/en-us/vba/excel-vba/articles/application-filedialog-property-excel https://msdn.microsoft.com/VBA/Office-Shared-VBA/articles/filedialog-object-office Using FilePicker and FolderPicker uno services. Change-Id: Ifd3b3fc9c135efb0663d2ef36ecbe2b2fbe6132f Reviewed-on: https://gerrit.libreoffice.org/39806 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2017-07-14Assert non-empty sheet nameEike Rathke
Change-Id: I6794d134a6f0d1f1b1531782c5f8011ce322085b
2017-07-14Fix export test crash of ooo95715-1.xlsEike Rathke
Negative sheet number injected by sc::FormulaLogger::GroupScope::addRefMessage() wans't handled by lcl_Format() #9 0x00007f292172c322 in ScGroupTokenConverter::convert (this=0x7ffc5b1940d0, rCode=..., rScope=...) at /build/libo/dev/sc/source/core/data/grouptokenconverter.cxx:140 #8 0x00007f29224c54d8 in sc::FormulaLogger::GroupScope::addRefMessage (this=0x7ffc5b193ff0, rCellPos=..., rRefPos=..., nLen=111, rArray=...) at /build/libo/dev/sc/source/core/tool/formulalogger.cxx:147 #7 0x00007f292181c071 in ScRange::Format (this=0x7ffc5b193dc0, nFlags=-32760, pDoc=0x4b1db70, rDetails=..., bFullAddressNotation=false) at /build/libo/dev/sc/source/core/tool/address.cxx:2211 #6 0x00007f292181b9a9 in ScAddress::Format (this=0x7ffc5b193dc0, nFlags=-32760, pDoc=0x4b1db70, rDetails=...) at /build/libo/dev/sc/source/core/tool/address.cxx:2111 #5 0x00007f292181ecf5 in lcl_Format<rtl::OUStringBuffer> (r="", nTab=-1, nRow=75, nCol=0, nFlags=-30968, pDoc=0x4b1db70, rDetails=...) at /build/libo/dev/sc/source/core/tool/address.cxx:2018 #4 0x00007f29214471fb in rtl::OUString::operator[] (this=0x7ffc5b193c00, index=0) at /build/libo/dev/include/rtl/ustring.hxx:668 Change-Id: I68ecfb11574644e9e5670431789ee42d37d27523
2017-07-14extend loplugin useuniqueptr to POD typesNoel Grandin
Change-Id: I6ff24f048bd8f75bf87a78b718f37b57855d4781 Reviewed-on: https://gerrit.libreoffice.org/39932 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-14use more OUString::operator== in scNoel Grandin
Change-Id: I1a7691fe59e5e93c15bd812f03366da814f9f3db Reviewed-on: https://gerrit.libreoffice.org/39900 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-14Moving legacy contexts to FastContexts:Mohammed Abdul Azeem
ScXMLTrackedChangesContext ScXMLChangeInfoContext ScXMLBigRangeContext ScXMLCellContentDeletionContext ScXMLDependenceContext ScXMLDependingsContext ScXMLChangeDeletionContext ScXMLDeletionsContext ScXMLChangeCellContext ScXMLPreviousContext ScXMLContentChangeContext ScXMLInsertionContext ScXMLDeletionContext ScXMLMovementContext ScXMLRejectionContext Change-Id: I13b657efa47bd037e9f83c39ba8fd0f6b7edba1c Reviewed-on: https://gerrit.libreoffice.org/39927 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org>
2017-07-13tdf#108758 : do not write to undo document when...Dennis Francis
...updating references during a block move, for formula cells that are in the target range of the move operation. The fix is for formula cells that are not grouped. For the grouped case, it was already doing correctly. Added two unit tests in ucalc_formula.cxx for grouped formula and non-grouped formula cases. Change-Id: I9f4d988f5e154f56670bd1c0cc366ee6704fb858 Reviewed-on: https://gerrit.libreoffice.org/39883 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
2017-07-13Reorganize Scheduler priority classesJan-Marek Glogowski
This is based on glibs classification of tasks, but while glib uses an int for more fine grained priority, we stay with our enum. 1. Timers start with DEFAULT priority, which directly corresponds with the previous HIGH priority 2. Idles start with DEFAULT_IDLE priority instead of the previous HIGH priority, so idle default becomes "really run when idle". As RESIZE and REPAINT are special, and the DEFAULTS are set, there is just one primary decision for the programmer: should my idle run before paint (AKA HIGH_IDLE)? If we really need a more fine-grained classification, we can add it later, or also switch to a real int. As a result, this drops many classifications from the code and drastically changes behaviour, AKA a mail merge from KDE is now as fast as Gtk+ again. Change-Id: I498a73fd02d5fb6f5d7e9f742f3bce972de9b1f9
2017-07-13Move scheduler task into its own headerJan-Marek Glogowski
Change-Id: I54534787b8cfa4c47dc09dde9c38a7893df9d367
2017-07-13improve useuniqueptr loplugin to find arraysNoel Grandin
Change-Id: I81e9d0cd4f430b11d20037054055683240792240 Reviewed-on: https://gerrit.libreoffice.org/39825 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-13loplugin:oncevar: empty strings: scStephan Bergmann
Change-Id: I8eca50560d9ce0a3be5ffe6a4a88cb0de5d5d451
2017-07-13loplugin:useuniqueptr in scNoel Grandin
Change-Id: I004e1f0292c8a40515880546574255ab835dbdbe Reviewed-on: https://gerrit.libreoffice.org/39875 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-12Eliminate trailing blanks from descriptions and some parameter namesEike Rathke
... where they don't belong, ie. at non-repeating parameters that don't get numeration appended in UI. Change-Id: I1516185978fecfbadcf2836eb60530b456c4d041
2017-07-12borderline: correct problems with border displayArmin Le Grand
Borderline display with direct paint and with primitive direct paint has quite some errors in the current state. Started to unify usages, check deeper with creation/usage. borderline: deep changes to BorderLine Found basic error in determining the offset values for BorderLinePrimitive creation, these were not centered on the lines. Corrected that. This makes it possible to remove the formally used clipping which seems to have been used to correct that. Also allows to go back to a 'normal' decomposition that creates line primitives as expected. That again can then be painted quite normally. Also added view-dependent case to the decomposition to guarantee a gap of one discrete unit (pixel). Removed the direct painter, too. Checked and corrected stroking. borderline: Adapted previews to primitives Added code to use the primitive representation in all dialogs and apps using tables. The edit views use these mostly, so the preview should do that, too. Currently missing is a good visualization of diagonals, but this is also true for edit views. Checked all apps and table usages to not get worse borderline: correct line dash visualization When a dashed line is used, a factor of 10.0 was applied in the original coded, added that. Also the orientation of vertical borders was inverted since it was simpler to exchange Start/End, but this also mirrors the line dash visualisation, corrected that Change-Id: I4c1b380a76cb37389fab1259a53fb7cc9da982d1 e95e246d5563360617a2a2213e4d5ec7d0e736b9 62369b4de58fb0264aeb710ec6983ceddca5701d 77418cc6c84ebb0632f8c3448976e82ce612d6b6 b4eb28dc86ce05eb89b26517167305b994158ef8 borderline: adapt cppunittest and clang
2017-07-12loplugin:unreffunJan-Marek Glogowski
Fix some HAVE_MORE_FONTS dependent tests. Change-Id: I79fec705d02b38222d66368759a95b667604335c
2017-07-11replace 'resize(size+1)' with emplace_backNoel Grandin
which is considerably faster if we're dealing with a std::list, and just easier on the eyes if we're dealing with a std::vector Change-Id: I373689205ebc048689f29ab80a7ee8551b20cc96 Reviewed-on: https://gerrit.libreoffice.org/39816 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-11Introduce IFormulaEditorHelper::createCompiler()Eike Rathke
For application specific derivatives. Change-Id: I8af95bd120c642e47ec5d0708ed463c98c471567
2017-07-11simplify calls OUString::copy in foo.copy(x, foo.getLength() - x)Noel Grandin
Change-Id: I20318c77dcc3bc2a64336541ef5a3f412bfd9483 Reviewed-on: https://gerrit.libreoffice.org/39803 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-11simplify some OUString::copy callsNoel Grandin
Change-Id: Ifa228ca02ea79a1309e1875414028aade7e5f12d Reviewed-on: https://gerrit.libreoffice.org/39801 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-11use more range-for on uno::SequenceNoel Grandin
Change-Id: Ifad32425d79be5a22d33d721bdc5fb993f699759 Reviewed-on: https://gerrit.libreoffice.org/39763 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-11Helper function to cast to FastAttributeList:Mohammed Abdul Azeem
Refactoring codes that cast XFastAttributeList reference to FastAttributeList pointer using the helper function. Change-Id: Iecf4b815d6556b0992d638b633260fbd459c0dc4 Reviewed-on: https://gerrit.libreoffice.org/39723 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2017-07-11add missing override, -Werror,-Winconsistent-missing-overrideMarkus Mohrhard
Change-Id: I99864b43f3b54eefbb80a885b701838b3e27d806
2017-07-10Introduce IFormulaEditorHelper::getCompiler()Eike Rathke
Implemented at rptui::FormulaDialog as nullptr and at ScFormulaDlg as ScCompiler* Change-Id: I0edaca56f5d9e3505ed766d43bc9ee4af80f03ff
2017-07-10Adding an overloaded IsXMLToken method:Mohammed Abdul Azeem
Passing FastAttributeIter to the method makes the code much cleaner and easy to read. Change-Id: I227e9dc378dfba51168c29452667576a779dc215 Reviewed-on: https://gerrit.libreoffice.org/39730 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2017-07-10simplify some OUString compareTo callsNoel Grandin
to either startsWith or == or != Change-Id: Ie4b4662f5b8e4532cbc1ab36910389e0b3d41ef0 Reviewed-on: https://gerrit.libreoffice.org/39750 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-10tdf#107135, add missing ODFF function REPLACEB.Winfried Donkers
Change-Id: I8d782b109eb390838b6c4f3a85e9b344ecef87ec Reviewed-on: https://gerrit.libreoffice.org/39606 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins <ci@libreoffice.org>
2017-07-10lok: sc: missing invalidation on pasting text and deleting a cellMarco Cecchetti
In the desktop case we invalidate up to the right side of the visible area, however in the tiled rendering case we need to take care to invalidate also cached tiles. Change-Id: I7290ff35c155fab6bda3ce8b5d9c765624507052 Reviewed-on: https://gerrit.libreoffice.org/39728 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2017-07-10teach unnecessaryparen loplugin about identifiersNoel Grandin
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-09add test for non-ascii gnumeric file names, tdf#107827Markus Mohrhard
Change-Id: Ib530567df9cb487951d8dbf1b7824f78a7d150d9 Reviewed-on: https://gerrit.libreoffice.org/37581 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-07-09tdf#79304 - Handle CrossedOutItems in HTML export.Sean Stangl
Change-Id: I766fedb34737a1a7815693bf496fa08c08f492b1 Reviewed-on: https://gerrit.libreoffice.org/39719 Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com> Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-07-08Add a way to resize ScDBDataJaskaran Singh
Change-Id: I6e0e1a7f58873c012e0e8015ed69da38a32a44f4 Reviewed-on: https://gerrit.libreoffice.org/39323 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-07-08tdf#45904 Move Java XSheetAnnotationShapeSupplier test to C++Jens Carl
Change-Id: I5a3d64fd255fb8fd1f1caba572bc00a5399a6519 Reviewed-on: https://gerrit.libreoffice.org/39550 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-07-07merge BS and ToPsz10, etcCaolán McNamara
Change-Id: I25d4efe816bf6ae4ba456bb42a827b9a70f503c7 Reviewed-on: https://gerrit.libreoffice.org/39689 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-07-07loplugin:unnecessaryparen handle parens inside call exprNoel Grandin
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-07coverity#1413006 Mixing enum typesCaolán McNamara
Change-Id: I9dcaf17b75228ac409e88d9fddba717ba40c58ea Reviewed-on: https://gerrit.libreoffice.org/39668 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-07-07C++11 remove std::binary_function bases from functorsJochen Nitschke
std::binary_function is deprecated since C++11 and removed in C++17 90% done with regexp magic. removed obsolete <functional> includes. The std::binary_function base class was used by deprecated std::bind2nd, this was solved in individual commits. The members first_argument_type and second_argument_type were used in chart2/source/controller/dialogs/DataBrowserModel.cxx: DataBrowserModel::implColumnLess and are inlined in this commit. Change-Id: I60ded60a8d4afd59e15ac15a58e18d2498c9be5a Reviewed-on: https://gerrit.libreoffice.org/39659 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-06Assert that GetClipDoc() is indeed a clipboard document, tdf#108612 relatedEike Rathke
Change-Id: Idb782bc04239e28967830fae9e89a7433579669b
2017-07-06Attempt to blind fix tdf#108612 explicitly checking for clipboard documentEike Rathke
It seems that for some yet unknown reason in an (un)certain constellation ScDocument::IsClipboardSource() returns true because ScModule::GetClipDoc() does not return the clipboard document but the actual document instead, so destroying the clipboard document executes ScDocument::ClosingClipboardSource() and (or in earlier versions) ScDocument::ForgetNoteCaptions() on the actual document instead. Check also that ScDocument::bIsClip is set, hopefully curing the symptom, the real cause is something else. Change-Id: I5ffd0706592d2737808e7004630a56c53115295b
2017-07-06GSoC: Recent Charaters Toolbar Dropdown ControlAkshay Deep
Change-Id: Ib04d26fa5556e5c32db6799c16d0bbedc45504ec Reviewed-on: https://gerrit.libreoffice.org/38944 Reviewed-by: Akshay Deep <akshaydeepiitr@gmail.com> Tested-by: Akshay Deep <akshaydeepiitr@gmail.com> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-07-06loplugin:unusedfields in scNoel Grandin
found a couple more by running make build-nocheck to exclude testing code Also, teach unusedfields loplugin about operator<<, since referring to a field in an ostream operator<< does not indicate a real use, it's normally for debugging Change-Id: I3dce22bf5afda2fd09e01de9bf1d0ef85e535aa8 Reviewed-on: https://gerrit.libreoffice.org/39625 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-06tdf#108923 : Use display string for generating chart labelsDennis Francis
Use display string for generating chart labels in PivotTableDataProvider::collectPivotTableData as chart2 does not seem to use number format for labels although it does for the data. Added unit test PivotChartTest::testPivotChartWithDateRowField() for this fix. Change-Id: I668d4c9d7cf8bbb7e4213cce7a6e7cd4d7d07cbe Reviewed-on: https://gerrit.libreoffice.org/39548 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2017-07-06ensure safe GlobalEditData release of xForbiddenCharsTableCaolán McNamara
ensure that when the editeng GlobalEditData dtor is called that the vtable of the xForbiddenCharsTable shared_ptr will point to functions that are callable from editeng. otherwise a shared_ptr created in the sw uwriter cppunit test, but now belonging to GlobalEditData, will have deleter entries pointing to functions in uwriter that have been unloaded and are not available anymore Change-Id: I375a84156c0b1a0f8b24194fc07f0c512f556dbc Reviewed-on: https://gerrit.libreoffice.org/39605 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-07-06rework as a shared_ptrCaolán McNamara
mostly to try and track down a crash on exit of sw uwriter under windows Change-Id: Id67e93863056da319dd8225038d60a7f5783b103 Reviewed-on: https://gerrit.libreoffice.org/39604 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-07-06use more begin()/end() for SequenceNoel Grandin
Change-Id: I399be6b6ef7a6ce01e883569a177c0969bc29c69
2017-07-06teach unnecessaryparen plugin about other kinds of statementsNoel Grandin
i.e. do / while / switch Change-Id: Id0985015cc425557f9984734701d56466f8a6088 Reviewed-on: https://gerrit.libreoffice.org/39601 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-06loplugin unnecessaryparan improvementsNoel Grandin
Change-Id: I73e945d6ec53537a0da45f6b6291018c7f251a7e Reviewed-on: https://gerrit.libreoffice.org/39587 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-05Display string results in the Function Wizard quotedEike Rathke
To distinguish number strings from numeric results. Change-Id: I68e044e839b2d5d2e87835dd0002f42aa0fc8192
2017-07-05coverity#1414481 Uninitialized scalar fieldCaolán McNamara
regression from commit 7b850c15b15be10ed3b52822f63b02d8787bcb2f Date: Wed Jun 21 15:32:03 2017 +0200 loplugin:unusedfields in sc part1 Change-Id: Ibd3a8410f7916bf7c03b436f45bf382ff9eb3798 Reviewed-on: https://gerrit.libreoffice.org/39571 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-07-05coverity#1414486 Unchecked dynamic_castCaolán McNamara
and coverity#1414482 Unchecked dynamic_cast coverity#1414480 Unchecked dynamic_cast coverity#1414479 Unchecked dynamic_cast Change-Id: Ia33e4cfa5c13beeae5dfa46411f526433d87ea99 Reviewed-on: https://gerrit.libreoffice.org/39568 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>