summaryrefslogtreecommitdiff
path: root/include/test/beans
ModeNameSize
-rw-r--r--xpropertyset.hxx1922logplain
any accessible text changes have occurred and fire text and value changed notifications if needed. Change-Id: I106ad0138d5d834367be59ca625d41a692696d4a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167961 Reviewed-by: Patrick Luby <guibomacdev@gmail.com> Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de> 2023-10-07tdf#157568 After deleting the content of a cell by pressing the delete..Noel Grandin .. key, Orca still speaks the content. this reverts commit f22cb3dfab413a2917cd810b8e1b8f644a016327 Author: Noel Grandin <noelgrandin@gmail.com> Date: Mon Jun 12 20:02:19 2023 +0200 tdf#155376 weakly cache ScAccessibleCell which was a nice idea, but means that we would need to have some way of updating the ScAccessibleCell when the associated cell data changes. Which is likely to be complicated. So return to creating new ScAccessibleCell objects all the time, but fix them to not leak. Change-Id: Ie17ee5c950c9809d4c7281f93761584f75256121 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157673 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2023-08-02split Point/Size/Rectangle into AbsoluteScreenPixel* typesNoel Grandin to attempt to make it obvious in code what kind of coordinate system we are dealing with. The idea is that by doing this, the compile-time type checking will flush out inconsistencies between different code. I started with vcl::Window::OutputToAbsoluteScreenPixel and worked outwards from there. Change-Id: Ia967d7a0bb38886695f3a761b85c8b9340ddb1c0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154676 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2023-06-13tdf#155376 weakly cache ScAccessibleCellNoel Grandin the macOS accessibility framework repeatedly queries and enumerates all of the visible cells. Every time this happens we create a new set of ScAccessibleCell, which then live until the application shuts down, which then causes a very slow shutdown. So I fix the problem by caching the ScAccessibleCell so we return the same one for a given cell position. Of course, this begs the question of why the ScAccessibleCell objects are not dying when we create new ones, which means we have some kind of leak or lifecycle problem somewhere, but anyhow, this is a fairly simple and comprehensive fix. Change-Id: Id2765236ac4524f490a51b56268fb8038612fd43 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152932 Tested-by: Jenkins Reviewed-by: Patrick Luby <plubius@neooffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2022-09-02[API CHANGE] tdf#150683 a11y: Switch a11y child index to 64 bitMichael Weghorn With 16k column support in Calc enabled by default in commit 4c5f8ccf0a2320432b8fe91add1dcadf54d9fd58 Date: Tue Mar 8 12:44:49 2022 +0100 change default Calc number of columns to 16384 (tdf#50916) , the number of Calc cells in a spreadsheet is larger than SAL_MAX_INT32, meaning that a 32-bit a11y child index is no more enough and using it resulted in integer overflows in methods handling corresponding Calc cells in the a11y layer. This e.g. had the effect of the Orca and NVDA screen readers not announcing focused or selected cells properly when their a11y child index was out of the 32-bit integer range. Switch the internal a11y child indices to 64 bit to be able to handle this properly internally. Since the platform APIs (at least AT-SPI on Linux and IAccessible2 on Windows; from what I can see LO's macOS a11y bridge doesn't directly expose the child index) are still restricted to 32 bit, larger child indices still cannot be exposed via the platform APIs. As a consequence, use of the the IAccessible2 and AT-SPI methods that use the child index remains problematic in those cases where the child index is larger. However, as an alternative to using the AT-SPI Table interface and the IAccessibleTable/ IAccessibleTable2 interfaces with the child index to retrieve information about a specific cell, both AT-SPI and IAccessible2 also provide interfaces to retrieve that information directly from the cell object (TableCell interface for AT-SPI, IAccessibleTableCell for IAccessible2). Those interfaces are already implemented/exposed for winaccessibility (s. `CAccTable`) and the qt5/qt6/kf5 VCL plugins (s. the `QAccessibleTableCellInterface` methods implemented in `QtAccessibleInterface`). With the switch to 64-bit internal a11y child indices, these now behave correctly for cells with a child index that doesn't fit into 32 bit as well. NVDA on Windows already uses the IAccessibleTableCell interface and thus announcing focused cells works fine with this change in place. Orca on Linux currently doesn't make use of the AT-SPI TableCell interface yet, but with a suggested change to do so [1], announcement of selected cells works with the qt6 VCL plugin with a current qtbase dev branch as well - when combined with the suggested changes to implement support for the AT-SPI TableCell interface in Qt [2] [3] and the LO change based on that [4] and a fix for a nullptr dereference [5]. The gtk3 VCL plugin doesn't expose the AT-SPI TableCell interface yet, but once it does so (via `AtkTableCell`), it also works with the suggested Orca change [1] in place. (Adding that is planned for an upcoming change, works with a local WIP patch.) For handling return values that are larger than what platform APIs support, the following approach has been chosen for now: 1) When the return value is for the count of (selected) children, the maximum value N supported by the platform API is returned. (This is what `ScAccessibleTableBase::getAccessibleChildCount` did previously.) The first N elements can be accessed by their actual (selection) indices. 2) When the return value is the child/cell index, -2 is returned for objects whose index is greater than the maximum value supported by the platform API. Using a non-negative value would mean that the index would refer to *another* actually existing child. A child index of -1 on the other hand tends to be interpreted as "child is invalid" or "object isn't actually a child of its (previous) parent any more)". For the Orca case, this would result in objects with a child index of -1 not being announced, as they are considered "zombies" [6]. What's still somewhat problematic is the case where more than 2^31 children are *selected*, since access to those children still happens by the index into the selection in the platform APIs, and not all selected items are accessible this way. (Screen readers usually just retrieve the first and last element from the selection and announce those.) Orca already seems to apply different handling for the case for fully selected rows and columns, so "All cells selected" or "Columns ... to ... selected" is announced just fine even if more than 2^31 cells are selected. (Side note: While Microsoft User Interface Automation - UIA - also uses 32-bit indices, it also has specific methods in the ISelectionProvider2 interface that allow to explicitly retrieve the first and last selected item, `ISelectionProvider2::get_FirstSelectedItem` and `ISelectionProvider2::get_LastSelectedItem`, but we currently don't support UIA on Windows.) Bound checks at the beginning of the methods from the `XAccessibleContext`, `XAccessibleSelection` and `XAccessibleTable` interfaces that take a child index (or in helper methods called by those) should generally already prevent too large indices from being passed to the methods in the lower layer code that take smaller integer types. Such bound checking has been been added in various places where it wasn't present yet. If there any remaining issues of this kind that show after this commit, they can probably be solved in a similar way (s.e.g. the change to `AccessibleBrowseBox::getAccessibleChild` in this commit). A few asserts were also added at places where my understanding is that values shouldn't be larger than what is supported by a called method anyway. A test case will be added in a following change. [1] https://gitlab.gnome.org/GNOME/orca/-/merge_requests/131 [2] https://codereview.qt-project.org/c/qt/qtbase/+/428566 [3] https://codereview.qt-project.org/c/qt/qtbase/+/428567 [4] https://gerrit.libreoffice.org/c/core/+/138750 [5] https://codereview.qt-project.org/c/qt/qtbase/+/430157 [6] https://gitlab.gnome.org/GNOME/orca/-/blob/82c8542002e36e0d3d918088d583162d25136143/src/orca/script_utilities.py#L5155 Change-Id: I3af590c988b0e6754fc72545918412f39e8fea07 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139258 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de> 2022-07-08[API CHANGE] Drop css::accessibility::XAccessibleStateSetNoel Grandin which is internal API, unused (as far as I can tell) by external users. This state is purely a bitset (as implemented by utl::AccessibleStateSetHelper) so we can just return it as a 64-bit value. This shaves significant time off the performance profiles of code that loads very complex shapes, because this state is frequently used, and we no longer need to allocate a return value on the heap for every call. Change-Id: Icf1b3bd367c256646ae9015f9127025f59459c2c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136786 Reviewed-by: Michael Weghorn <m.weghorn@posteo.de> Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2021-09-13ScAccessibleSpreadsheet: Use 2 local vars instead of class membersMichael Weghorn Those vectors are only used in 'ScAccessibleSpreadsheet::CalcScAddressFromRangeList' and cleared before use, so just use local variables instead. Also, use a 'std::pair<SCCOL,SCCOL>' instead of a 'std::pair<sal_uInt16,sal_uInt16>' for holding a pair of column indices and drop the 'PAIR_COL' typedef. Change-Id: Iacddba03cb72a5cfb6cf3ced0001258ef9db9107 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122028 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de> 2021-03-23tdf#124176 Use pragma once in s*Vincent LE GARREC sc, scaddins, sccomp, scripting Change-Id: Ia99fec9e238033821cb784810edd4762c09bd5db Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112049 Tested-by: Jenkins Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org> 2020-06-11loplugin:unusedmethodsNoel Grandin Change-Id: I1050fabdc0c98bbb0cc1d81a41c5b6ac3404cacf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96111 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2020-03-12Revert "loplugin:constfields in sc"Noel Grandin This reverts commit fb1d3b580763a333bbbfe115d09e1b5cd8849675. Now that we know that making fields has negative side effects like disabling assignment operator generation. Change-Id: Ib48334ffbeb2c768896dd8ced6818aa0b9910b0b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90333 Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2019-12-05inline some typedefsNoel Grandin Change-Id: Iff907f325352130c3af49c1f75b8e87cf7230110 Reviewed-on: https://gerrit.libreoffice.org/84449 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2019-12-05clean up members in ScAccessibleSpreadsheetNoel Grandin re-arrange them so the private/public sections are continuous. And make a bunch of public fields private, no-one seems to be touching them outside the class. Change-Id: I6378793fb01bc884961d19627a46f2a1e7eda79c Reviewed-on: https://gerrit.libreoffice.org/84448 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2019-08-12Fix typosAndrea Gelmini Change-Id: I6ceb04830192bd6415cb41688bb604fccc25a882 Reviewed-on: https://gerrit.libreoffice.org/77294 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr> 2019-03-09loplugin:unusedmethodsNoel Grandin Change-Id: I242f56f2bc5dc8fce6db1ba8f1f8269da4fec0fa Reviewed-on: https://gerrit.libreoffice.org/68938 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2019-02-23loplugin:unusedfields in scNoel Grandin Change-Id: I5e9842970821d0ae61e06e3ad35c9f571b43632c Reviewed-on: https://gerrit.libreoffice.org/68224 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2018-10-16tdf#42949 Fix IWYU warnings in sc/source/ui/inc/[a-e]*Gabor Kelemen Also files starting with capital letters. Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ia79de45524315e2aaa1283ee6e42c54c9e14a31e Reviewed-on: https://gerrit.libreoffice.org/61735 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> 2018-10-15loplugin:constfields in scNoel Grandin Change-Id: If326175d571d15752efd1b63df45b2bc785f7541 Reviewed-on: https://gerrit.libreoffice.org/61653 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2018-04-10loplugin:useuniqueptr in ScAccessibleSpreadsheetNoel Grandin Change-Id: Ia3df85292aba5a506a60b2ae5345e4e78c676c93 Reviewed-on: https://gerrit.libreoffice.org/52650 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2018-03-10don't use heap for elements in ScRangeListNoel Grandin no need to store small objects like this out of line. Also - add move constructor and move assignment operator - drop Assign method since it now has the same signature as push_back Change-Id: I9a8647d3a11f24166a83d399a358a2bce3b2cb79 Reviewed-on: https://gerrit.libreoffice.org/50899 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com> 2017-10-27loplugin:finalclasses in scNoel Grandin Change-Id: I83438eaf2c1045a9212a63ed9fd8b3371e9b06aa Reviewed-on: https://gerrit.libreoffice.org/43896 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2017-10-23loplugin:includeform: scStephan Bergmann Change-Id: I2ed763e0584a188032c80fde60890de3c6985cbd 2017-08-24loplugin:constparam in sc part4Noel Grandin Change-Id: I745f50257948a53ca07766955c4f4e86dd2a366e Reviewed-on: https://gerrit.libreoffice.org/41497 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2017-08-15loplugin:checkunusedparams in scNoel Grandin Change-Id: Ib4572899caeb7bc2dceb2c188ceb306b8ffc9193 Reviewed-on: https://gerrit.libreoffice.org/40629 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2017-06-28loplugin:unusedfields in sc part1Noel Grandin in ScNavigatorDlg::ScNavigatorDlg, we replace the assignment of nAreaId with an assignment to nDataId instead, which is never initialized but used, whereas nAreaId was initialized but never used. Change-Id: I9681af7f7d515d4891c9b52d3809e88e3d5e8256 Reviewed-on: https://gerrit.libreoffice.org/39062 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2017-03-31tdf#82580 tools: rename Rectangle to tools::RectangleMiklos Vajna Mostly generated using make check COMPILER_EXTERNAL_TOOL=1 CCACHE_PREFIX=clang-rename-wrapper RENAME_ARGS="-qualified-name=Rectangle -new-name=tools::Rectangle" Except some modules have their own foo::tools namespace, so there have to use ::tools::Rectangle. This commit just moves the class from the global namespace, it does not update pre/postwin.h yet. Change-Id: I42b2de3c6f769fcf28cfe086f98eb31e42a305f2 Reviewed-on: https://gerrit.libreoffice.org/35923 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org> 2017-01-26Remove dynamic exception specificationsStephan Bergmann ...(for now, from LIBO_INTERNAL_CODE only). See the mail thread starting at <https://lists.freedesktop.org/archives/libreoffice/2017-January/076665.html> "Dynamic Exception Specifications" for details. Most changes have been done automatically by the rewriting loplugin:dynexcspec (after enabling the rewriting mode, to be committed shortly). The way it only removes exception specs from declarations if it also sees a definition, it identified some dead declarations-w/o-definitions (that have been removed manually) and some cases where a definition appeared in multiple include files (which have also been cleaned up manually). There's also been cases of macro paramters (that were used to abstract over exception specs) that have become unused now (and been removed). Furthermore, some code needed to be cleaned up manually (avmedia/source/quicktime/ and connectivity/source/drivers/kab/), as I had no configurations available that would actually build that code. Missing @throws documentation has not been applied in such manual clean-up. Change-Id: I3408691256c9b0c12bc5332de976743626e13960 Reviewed-on: https://gerrit.libreoffice.org/33574 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com> 2016-11-07loplugin:expandablemethods in scNoel Grandin Change-Id: Ib417c5e978fca563f8c0ef0dbe6b9d50fead9828 Reviewed-on: https://gerrit.libreoffice.org/30566 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2016-09-15loplugin:singlevalfields in sc..vclNoel Grandin Change-Id: I68752a3daf5ddd8581c07759b8be2c1dabbb9258 2016-09-13loplugin:override: No more need for the "MSVC dtor override" workaroundStephan Bergmann The issue of 362d4f0cd4e50111edfae9d30c90602c37ed65a2 "Explicitly mark overriding destructors as 'virtual'" appears to no longer be a problem with MSVC 2013. (The little change in the rewriting code of compilerplugins/clang/override.cxx was necessary to prevent an endless loop when adding "override" to OOO_DLLPUBLIC_CHARTTOOLS virtual ~CloseableLifeTimeManager(); in chart2/source/inc/LifeTime.hxx, getting stuck in the leading OOO_DLLPUBLIC_CHARTTOOLS macro. Can't remember what that isAtEndOfImmediateMacroExpansion thing was originally necessary for, anyway.) Change-Id: I534c634504d7216b9bb632c2775c04eaf27e927e