summaryrefslogtreecommitdiffstats
path: root/sc
Commit message (Collapse)AuthorAgeFilesLines
* cosmetic changesfeature/unitverBenjamin Ni2016-01-055-3/+7
| | | | | | | Change-Id: I6826a23655c9556dac2be49a8f28d67e95e91ff2 Reviewed-on: https://gerrit.libreoffice.org/17582 Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com> Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
* unit-verification: more convert Link<> to typedAndrzej Hunt2015-10-212-22/+14
| | | | Change-Id: I8f330dbfb3b5a0a7409475a5a8802c3640e6bb31
* Make incompatible-output-box visible to ensure layout spaceAndrzej Hunt2015-10-211-0/+1
| | | | | | | | | | If the incompatible-output warning is not visible when the dialog is loaded, it receives no space in the layout - this then looks ugly when this warning is enabled (as it overlaps the OK/Cancel buttons). We already set the boxes visibility again on startup, hence we then hide the box as needed at that time. Change-Id: I61c9ce463ad80aaec08ae680aa3ad1535c33d9c5
* Set default focus on output unit entry boxAndrzej Hunt2015-10-211-1/+2
| | | | | | | This allows the user to immediately enter their desired unit - the input area selection is likely to be used only rarely. Change-Id: I08de7718ed183db21513d1f46f346da27c3ebbf7
* unit-verification: convert Link<> to typedAndrzej Hunt2015-10-214-34/+34
| | | | | | (fix build after rebasing on master) Change-Id: Iecbdbf5a854de0b552f6c9074e72da3fa47d91a4
* loplugin:vclwidgetsAndrzej Hunt2015-10-211-7/+8
| | | | Change-Id: I8edbf71d961067ee565954cbb91ee9e503e3077d
* Implement undoing conversion of individual locally annotated cellsAndrzej Hunt2015-10-213-13/+96
| | | | Change-Id: I16b62f1105f7839b047a96fdab0e3e6089d400ee
* Remove redundant parameters.Andrzej Hunt2015-10-212-11/+9
| | | | Change-Id: I0230fdd69d4f60058ca4f0258c5098f77099a3e4
* Test for tdf#92455 (persist purely local annotations after conversion)Andrzej Hunt2015-10-211-0/+12
| | | | Change-Id: I3f0ed297ef4eb9ac7876a9e24e3c2f0c1ec0b521
* Added checkbox and config option to toggle unit verificationBenjamin Ni2015-10-216-47/+104
| | | | Change-Id: Ie218821d05466b77ed42a26365b04a6798dec067
* tdf#92455 - inconsistent unit handlingBenjamin Ni2015-10-201-2/+3
| | | | Change-Id: Ifbb85a32ef9d84199d17cedd28fa0f9e66eabf66
* Coding style cleanupBenjamin Ni2015-10-201-11/+26
| | | | | | | Change-Id: I6171ba59e4df40dfc4734204832857f0fe7637e9 Reviewed-on: https://gerrit.libreoffice.org/16738 Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com> Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
* Added more range conversion testsBenjamin Ni2015-10-201-40/+109
| | | | Change-Id: If4898e6c70cb9731af35d51457de28410f808b96
* refresh cell rendering after changing unitMarkus Mohrhard2015-10-201-0/+7
| | | | Change-Id: I6f68c319df89906b29d1f8409f6170a0b68c8b87
* add test case for unit conversionMarkus Mohrhard2015-10-201-0/+20
| | | | Change-Id: I726758c93b25ed16b5708a71645004537f32ac76
* fix crash when converting unitsMarkus Mohrhard2015-10-201-1/+1
| | | | Change-Id: Ic883e13b5c6923c31e65a887597f0910807dc94d
* fix build and adapt a few places to calc coding styleMarkus Mohrhard2015-10-203-33/+45
| | | | Change-Id: I9759b96f7ba53c6737ea1576f16d6b46ad5f472b
* Don't assert on unsupported opcode, return unknown insteadAndrzej Hunt2015-10-201-1/+1
| | | | | | | | | We should eventually support all opcodes, but crashing* isn't really the correct response if not. *or continuing with completely wrong behvaiour in non-debug builds. Change-Id: I22d7746f4e809bdc3da62b8b6f741216504b3f22
* Enable --with-system-udunits2Andrzej Hunt2015-10-207-7/+7
| | | | | | | | We also have to move udunits2 headers to match the default system installation location of ududnits2/udunits2.h (whereas udunits2 bundled build puts the headers in lib/udunits2.h by default). Change-Id: I1d314f6b3e016f90cfb8e19a143bb77ae98e7734
* Rename VERIFIED->VALID for formula status.Andrzej Hunt2015-10-204-19/+19
| | | | Change-Id: I93a07e11546ebecf912449c72e57404731c346e9
* Kill unnecessary UnitsStatusAndrzej Hunt2015-10-202-32/+25
| | | | | | | | | Is redundant now that we've got the public FormulaStatus. FormulaStatus adds two new variants that we don't need internally however they are only relevant in one location hence it makes sense to share the enum. Change-Id: Idb08a41574e56a2f994c7e8bc816ffd370d86766
* Fix building with disabled unit verification.Andrzej Hunt2015-10-208-4/+29
| | | | Change-Id: I78633082a0e0dfcaa27515ce8d9c8635e50735e9
* Show whether error is in formula or output in units warningAndrzej Hunt2015-10-203-5/+27
| | | | Change-Id: Ib21462b3d67bb9b960c0d37384cdcef5003a884e
* Add tests for output unit verification.Andrzej Hunt2015-10-201-0/+54
| | | | Change-Id: Ia273a64fdbb5e1fe57f41679e9d77e0df78987de
* Return status for formula errorsAndrzej Hunt2015-10-206-48/+92
| | | | | | | Returning a status (instead of a boolean) means we will be able to print better error messages for the user in future. Change-Id: I0b08913267fedb5735112acc7427156e07e32b31
* Invalid formulas can't have unit correctness verified.Andrzej Hunt2015-10-201-10/+2
| | | | | | | Formulas that can't be processed will already be treated as invalid, we shouldn't additionally complain about unit verification in this case. Change-Id: I0556bf76b6e2343cdf27ec53669e6fd78da9280b
* Implement units conversion dialog.Andrzej Hunt2015-10-2017-0/+777
| | | | Change-Id: Iea99d0c86de970e185bfc03e548be47f5235be5f
* Add Units::isValidUnitAndrzej Hunt2015-10-203-0/+10
| | | | Change-Id: Ibb9c6e0d713ceeaa4fc4c67467d76da2f6183502
* Use GetParamCount instead of GetByte.Andrzej Hunt2015-10-201-1/+1
| | | | Change-Id: I8f49d198c2e49246a28839a77c37563e9a8b19a5
* Update units error messsage for clarity.Andrzej Hunt2015-10-201-1/+1
| | | | Change-Id: Ib59b2317f962d01bcc65a981040c3452cee7206e
* Convert convertCellUnits to handle rangesAndrzej Hunt2015-10-204-21/+24
| | | | Change-Id: Ibe95cbd9ea9efd08a48e0651f469434802bfa40e
* Split convertCellUnits and change contractAndrzej Hunt2015-10-203-66/+98
| | | | | | | This is in preparation for rewriting convertCellUnits to handle ScRangeList's. Change-Id: I17fecdb64674af79a33f2b1a62b4b46150177af5
* Make more methods of UtUnit constAndrzej Hunt2015-10-201-4/+4
| | | | Change-Id: I652a77ad3bf547788bf6d566fdeaac525effb541
* Implement getUnitsForRangeAndrzej Hunt2015-10-204-0/+249
| | | | | | This will be useful for e.g. the units conversion dialog. Change-Id: I36391e9aeab5689bfde1d1865549cc2e136a4812
* Store original input string for UtUnitAndrzej Hunt2015-10-202-5/+29
| | | | | | | String->UtUnit isn't necessarily reversible, hence we should store the original input too in case it is needed by the user. Change-Id: I8794a1544a9c996da574ee753d95b44f067e819f
* Return invalid unit for empty and string cells.Andrzej Hunt2015-10-202-0/+7
| | | | Change-Id: I6dbec9be643040f9fc567e6065f860a3985f138a
* Implement areUnitsCompatible API methodAndrzej Hunt2015-10-204-0/+30
| | | | | | | We need this for the conversion dialog, where it's probably better if we can avoid directly fiddling with UtUnits. Change-Id: I090e59c49f3b77ffcc0571838023165c2da931a0
* Add setNumberFormatUnit utility method to units testAndrzej Hunt2015-10-201-33/+26
| | | | | | Should simplify writing further tests. Change-Id: Idf991d12d0731d531f7e7c84e1ebe10b76d82b7a
* Use HeaderUnitDescriptor to pass around header specificsAndrzej Hunt2015-10-203-118/+162
| | | | Change-Id: I7c74211236b00c570941fda39cb0d69c1ce4e02c
* Implement unit conversion for ranges.Andrzej Hunt2015-10-204-0/+205
| | | | | | | Not entirely finished yet, some further refactoring needed elsewhere to allow sensible implementation of the header editing. Change-Id: I81af74d698098f901b17fcda413e7aac04c94274
* Use the actual default format for value/unit splitting.Andrzej Hunt2015-10-201-1/+1
| | | | Change-Id: I1da34b43d273d1ae2f91591aafcfab8adf9a4f02
* Add some assertions for UtUnit::convertValueToAndrzej Hunt2015-10-201-0/+3
| | | | Change-Id: Ie606bbb3cab0b4445274b8bf92f8b1533b39c9fd
* UtUnit::isValid should be const.Andrzej Hunt2015-10-201-1/+1
| | | | Change-Id: I209dca17b0101ec8a36e590870e90dcaca510a42
* Store pre-conversion value in cell annotation.Andrzej Hunt2015-10-201-0/+16
| | | | Change-Id: I67d8d1a7b0190b91107987a1ae4f03f2e91b06ca
* Set document modified on local unit conversion.Andrzej Hunt2015-10-202-9/+19
| | | | Change-Id: I6666668817a7987d14728fb1de1abe3711e34d9a
* Upgrade units test to use SfxModelFlags (rebase fixup).Andrzej Hunt2015-10-201-3/+3
| | | | | | Necessary due to afc728fe76fbf1afea725afd6ff5e9af92e10b08 Change-Id: Iea6dfb08a36f56485ed43a9c4cd2dcf652ff0b97
* loplugin:staticmethodsAndrzej Hunt2015-10-202-4/+4
| | | | Change-Id: I31969836cc9e9147aaa370779fa281792efa9de2
* Move and rename Range/Unit Stack.Andrzej Hunt2015-10-205-73/+139
| | | | | | | This in preparation for implementing a combined Unit and Range iterator. Change-Id: I08d28e175453f65c3696e9d1c6c20c7076d9b164
* Check output unit against header definition during verification.Andrzej Hunt2015-10-201-1/+17
| | | | Change-Id: I98a706d80eb442d274fc111fb6c22e43d79fb9ff
* Use correct stack for multiparam opcodes.Andrzej Hunt2015-10-202-2/+18
| | | | | | Also add an appropriate unit test. Change-Id: Ie2e9cce74563dea80b33f5e8238ba6ad1aae1b49