summaryrefslogtreecommitdiff
path: root/libreofficekit/source
AgeCommit message (Collapse)Author
2023-08-14lok: a11y: when we are inside a table notify table and current cell infoMarco Cecchetti
When we get in one or more tables we notify row and column count. When we get out one or more table we notify we are leaving a table. When the fosused cell changes we notify the new row/col index. The paragraph content is notified together with table info, so that client has some opportunity for getting the screen reader to report together content and table info. Change-Id: Ic524259aa1879a70fc3de2467bdee27475352b7d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155577 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2023-06-09notify async password changeJaume Pujantell
Change-Id: I2d16c9804e65f093239e810d466de35286b28dee Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151651 Tested-by: Jenkins Reviewed-by: Andras Timar <andras.timar@collabora.com>
2023-06-05lok: callback to send the updated theme palette when theme changesTomaž Vajngerl
The callback sends the updated theme color palette when the theme changes or initially when the view is registered, so the client should always have the up-to-date theme color palette stored, so it can just show the color picker with the theme at any time without the need to call the server. Change-Id: I7cceccc46c2fad23ba89e6d3f3643e37f8dab292 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152589 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-06-02lok: accessibility event listener for focused paragraphMarco Cecchetti
LOKDocumentFocusListener keeps track of the currently focused paragraph. Also includes: Author: Andras Timar <andras.timar@collabora.com> Date: Mon May 15 22:06:10 2023 +0200 fix unused exception parameter 'e' Change-Id: Ibfee099e4e9b724648d7500b9ebb4e8ab84989b8 and: Author: Marco Cecchetti <marco.cecchetti@collabora.com> Date: Thu May 4 12:11:53 2023 +0200 lok: a11y: focused paragraph info sent to client For the currently focused paragraph the following data is notified to client: paragraph content, caret position, text selection start/end These data is kept as an instance state so the client can request such info at any time. Change-Id: Ic1a3be0d93472300b1b6a91fb0de5bad87c031aa and: Author: Marco Cecchetti <marco.cecchetti@collabora.com> Date: Sun May 7 11:52:14 2023 +0200 fixup! lok: accessibility event listener for focused paragraph It seems it was not a good idea using a unique_ptr as smart pointer for an instance of LOKDocumentFocusListener Change-Id: I8e6b0f48fee3c5db3c9b074a663f7f3fb96a601e Change-Id: I0fa400694f3129608228ade0b96e0b4e0aee87e2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152488 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2023-04-01Add LoKit callback for application color changeParis Oplopoios
Change-Id: I9d0fe4ab878c9d3a4a6d842be5cd534b97bf77a8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149822 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Paris Oplopoios <parisoplop@gmail.com> (cherry picked from commit 48650acef94147c2100eade8c583fddc770b94ef) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149876 Tested-by: Jenkins
2023-03-10sw lok: notify clients about view option changesParis Oplopoios
Send a string of the view options to the kit when the view changes Change-Id: I89f65ff1d22a83a54dde35e39eb487edda0b58e1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148078 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-12-20Async PDFExport dialog and parent methodsNickWingate
Filter dialogs are all called generically from guisaveas.cxx in GUIStoreModel() Signed-off-by: NickWingate <nick.wingate@collabora.com> Change-Id: Idfbe85c09f84d4a7cf3f00b9704d5af94868a051 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140403 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Andras Timar <andras.timar@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144511 Tested-by: Jenkins
2022-11-15gtktiledviewer: Don't call updateClientZoom until zoom is initializedMike Kaganski
Avoids some console noise Change-Id: I521e430eeabe8fcf5012834dc7be7af8c0ce418b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142724 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-10-28lok: You can't assume that destroyView would only destroy one viewMike Kaganski
In case you have some in-place clients (e.g., Math in-place editing is active), destroying the parent view would also destroy children, and then both numberOfViewsChanged (called from doc_destroyView) must tolerate 0 as a valid input, and lok_doc_view_destroy must make sure to destroy the document after the last views had gone. Change-Id: I32370fea49da0969e1fbbf971a397c4d657ec8f9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141963 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins
2022-10-26Enable gtktiledviewer on WindowsMike Kaganski
A new configure argument is introduced: --with-gtk3-build=<absolute path to GTK3 build> When provided, libreofficekit_selectionhandles package, libreofficekitgtk library and gtktiledviewer executable would be built on Windows using the GTK3 libraries in the passed directory, that must contain lib/pkgconfig subdirectory with correct pkg-config data. Change-Id: I6504af6eec0fc73cceb26a1ce923337abe14b5c4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141624 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-10-26lok: support embedded mediaAshod Nakashian
Change-Id: Ie8f3ed188cec0050a10a5d49325756931b902ef1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141807 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-10-25Consistently set document view also for zoom eventMike Kaganski
And extract this code to a dedicated function. The problem was, that creating a new view sets the document's current view shell (in SwViewGlueDocShell); upon destruction, document's view shell is set to nullptr. In desktop case, document view shell is then reset to another active shell e.g. inside "grab focus" event, which makes all following operations safe. But in gtktiledviewer case, the "grab focus" event is not handled, so setClientZoomInThread resulted in eventual nullptr dereference. It was workarounded in commit 25de85bc3ce2d2f9b7736f65492f42579048da27 Date Fri Oct 21 21:14:04 2022 +0200 nullptr check but that was not the proper fix. Possibly it could also be reasonable to start handling "focus-in-event" [1] in gtktiledviewer; but since just setting the view consistently in setClientZoomInThread solves the problem, it looks excessive. This reverts commit 25de85bc3ce2d2f9b7736f65492f42579048da27. [1] https://docs.gtk.org/gtk3/signal.Widget.focus-in-event.html Change-Id: Iac4ff4e9b043aec0e0af6ed811c0e7f018378271 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141753 Tested-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-10-21documentLoadWithOptions takes URLsMike Kaganski
m_aDocPath is set in lok_doc_view_set_property from data coming from gtv_application_open's calls to g_file_get_path. So the path is not a proper file URL, which is expected by documentLoadWithOptions. Some Linux paths can happen to be able to convert to absolute URL in rtl::Uri::convertRelToAbs, but not all, and not e.g. Windows paths. Change-Id: I0a17cb84000603336a6809b0179bbda3d54aec23 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141579 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-10-20sw content controls, alias: add LOK APIMiklos Vajna
And implement sample handling of it in lokdocview. Change-Id: Ia1975e4daef6260e2030e5d0dba8fb4293a9484f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141541 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-08-25Tell LibreOfficeKit clients what fonts in a document are missing on the machineTor Lillqvist
Use the OutputDevice::StartTrackingFontMappingUse() and OutputDevice::FinishTrackingFontMappingUse() functionality that was added last year. Add a new LibreOfficeKit document callback: LOK_CALLBACK_FONTS_MISSING. "Font" here means just the family name. We dont really know what style from the family is missing. Change-Id: Iec4349b5827e7d1dbdde7f8a9f8da92efde429e0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138802 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2022-06-23clang-tidy modernize-pass-by-value in libreofficekitNoel Grandin
Change-Id: I1a6b4eb804a8cc4eb5e67ae4bbf8f31863f323d7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136273 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-23sw content controls, picture: add LOK APIMiklos Vajna
- send a LOK_CALLBACK_CONTENT_CONTROL callback with action=change-picture when a file picker should be shown - extend lok::Document::sendContentControlEvent() to be able to replace the placeholder with the selected URL - update gtktiledviewer to work with these Change-Id: Ifb3750803885fc09fc82905b0cf85b2b8ca06e77 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134750 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-21lok-calc: new callback for print rangesDennis Francis
With this callback the lok clients can read and draw the print ranges on each sheet of the Calc document. Conflicts: include/LibreOfficeKit/LibreOfficeKitEnums.h libreofficekit/source/gtk/lokdocview.cxx Change-Id: Ie19351d4420e0f3d4191f6a354ce99ab830aede2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134375 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Pranam Lashkari <lpranam@collabora.com> (cherry picked from commit 172bc7a8f4eeab907adac077407186fbbd046a77) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134527 Reviewed-by: Gökay ŞATIR <gokaysatir@collabora.com> (cherry picked from commit 29b7b25d454e0a6cd07c00e13fdb83cc8a381583) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134614 Tested-by: Jenkins Reviewed-by: Dennis Francis <dennis.francis@collabora.com>
2022-05-13sw content controls, dropdown: add LOK APIMiklos Vajna
- expose the available list items in a new "items" key of the LOK_CALLBACK_CONTENT_CONTROL callback - add a new lok::Document::sendContentControlEvent() function to be able to select a list item from the current drop-down - add a new listbox to the gtktiledviewer toolbar to select a content control list item when the cursor is inside a dropdown - add tests for the array API of tools::JsonWriter Change-Id: I47f1333a7815d67952f7c20a9cba1b248886f6dd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134256 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-04-22sw content controls: add LOK APIMiklos Vajna
This is somewhat similar to LOK_CALLBACK_FORM_FIELD_BUTTON: if the cursor enters or leaves a content control, then we send this message, so the LOK client can render some kind of shading and/or border around the content control to indicate the boundaries of the object. Similar to selections, this can be multiple rectangles in case the string is long enough that the layout breaks it into multiple lines. Change-Id: I0641a19503b7a1d4cade8fe9b510605cab49f258 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133314 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-12-22loplugin:flatten in l10ntools..lotuswordproNoel Grandin
Change-Id: Ie6de142db1987094fdf538148ac5ee33379a3e4b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127275 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-30svp: normalize DoYieldJan-Marek Glogowski
I somehow missed / forgot, that SvpInstance::DoYield was now also yielding on the main thread and doesn't try to do "funky" multi- threaded event processing anymore (because it's no GUI), since commit 0efd06de8fca4036c4132b2745a11273b1755df2 ("vcl: fix hangs in SvpSalInstance"), So this just moves the main thread part into ImplYield and implements DoYield like on all other architectures, as described in README.scheduler. I've tried to fix the LOK poll to be more sensible. Change-Id: I4323685aa250e9d62a2f448cef358a7aa8ae862c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117899 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2021-11-19Drop F_PI1800/F_PI18000, and unify deg2rad/rad2deg conversionsMike Kaganski
Change-Id: Ib89b00c3dc8cd440e8a88906eea133becd1cef64 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125509 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
2021-11-13Use o3tl::convertMike Kaganski
Change-Id: I78db3001d602ec1a0847785b3c127b9d345f5af7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125173 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-08libreofficekit: fix lokdocview crash on startupMiklos Vajna
Regression from commit 1597cc5b3e07dd24cb4cb10b35b1e93545e4b929 (convert #defines to OUStringLiteral, 2021-07-29), the problem is that this the new path was instdir/programhandle_image_middle.png instead of the old: instdir/program/../share/libreofficekit/handle_image_middle.png This is external code, just revert back to the old code. Change-Id: I816e67091a2cd6bf07138a5166363803022bab8c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124869 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-10-22LOK: maintain blocked command list per viewPranam Lashkari
Conflicts: include/LibreOfficeKit/LibreOfficeKitEnums.h include/sfx2/viewsh.hxx libreofficekit/source/gtk/lokdocview.cxx sfx2/source/view/viewsh.cxx Change-Id: I7c621accd84f49447ab3e08a4bb662a9b91b834a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124049 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-10-12loplugin:moveparam in variousNoel Grandin
Change-Id: Ifa7c8ff2b21f63d234c29c28303d0bacd376c1e5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123434 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-07sc: lok: introduce LOK_CALLBACK_DOCUMENT_BACKGROUND_COLOR callbackDennis Francis
to send the document background color (Calc only for now). Change-Id: Ibd2f042a81c9bb714bed947c4ef92f82ff3e6f50 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120524 Reviewed-by: Szymon Kłos <szymon.klos@collabora.com> Tested-by: Dennis Francis <dennis.francis@collabora.com> (cherry picked from commit 5f2d669a51a91b21196eecb935aa55d3fc1aa7be) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120738 Tested-by: Jenkins Reviewed-by: Dennis Francis <dennis.francis@collabora.com>
2021-09-03tdf#131548 Android: jump to cellIlhan Yesil
Added LOK_CALLBACK_SC_FOLLOW_JUMP: fire this signal to jump to cell cursor in android viewer. Payload format same as LOK_CALLBACK_INVALIDATE_TILES. Change-Id: Ic896baccf1327d6ccdf104811446e3454a42679e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116448 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2021-08-02convert #defines to OUStringLiteralNoel Grandin
mostly by doing $ git grep -l '#define.*\"' -- *.cxx | xargs perl -pi -e 's/^#define\s+(\w+)\s+(\".*\")/constexpr OUStringLiteral \1 = u\2;/g' Change-Id: Idface893449b0ef2a3c5254865a300585d752fbb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119669 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-21cid#1474127 Unchecked return value from libraryCaolán McNamara
Change-Id: I6dac6f24d33ce4557ab94ff08357e597819510d5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112839 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-03-21cid#1478187 Resource leakCaolán McNamara
Change-Id: Ib63d25e358f81c428fcbbb502650c37d016b6b44 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112821 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-11-19tdf#123936 Formatting files in module libreofficekit with clang-formatPhilipp Hofer
Change-Id: I3f086de3a49181d32e54d7d58e1206615a9371e3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105687 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2020-11-10tdf#42949 Fix new IWYU warnings in directories [h-r]*Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I886b6f446293d3b1cfbf4ae05e8dbd7fabab9f20 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105510 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-10-26Allow some spelling dictionaries for gtktiledviewer.Michael Meeks
Change-Id: Ie3e646321aff2705d908b25e4beff0768a5936fb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104703 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-09-18Online: Show input help on Online / Core part.gokaysatir
Change-Id: I9d10179f266a725b770fdae50045fdb5d77178ab Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102708 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Andras Timar <andras.timar@collabora.com> (cherry picked from commit 110069adbba4d272450b30fa03c56efbd478e84c) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102935 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-08-11loplugin:flattenNoel Grandin
Change-Id: I6560756eb63856a22b43e3e65a7b7843cd2d5376 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100447 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-07-04lokit: add new callback type LOK_CALLBACK_INVALIDATE_SHEET_GEOMETRYDennis Francis
This is to notify the clients about changes in current sheet's geometry data. Use this to notify clients of various sheet geometry invalidations if the new feature flag scPrintTwipsMsgs is set. Change-Id: I478d2e646606320399905d7b15881a165a53146d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96969 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Dennis Francis <dennis.francis@collabora.com> (cherry picked from commit 7d0181f519f83b978b9040986738ad0cedc020ba) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/97956 Tested-by: Jenkins
2020-06-04Change FIXME to plain comment, there apparently is nothing to do about it hereTor Lillqvist
Change-Id: I81e50e7e604e8ef17ba0d369e8987f4c840f8361
2020-06-04Bin two leftover spurious writes to std::cerrTor Lillqvist
Change-Id: I89601e3682a5f8eca81b45af62e5aa50c481bc84 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95502 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Tor Lillqvist <tml@collabora.com>
2020-06-04tdf#128502: Add a FIXME commentTor Lillqvist
The view id concept is badly broken. Way too many wild assumptions that the "current" view is the one we expect here and there. For instance here. Change-Id: Icf36808b2c09f0b3fd8070deecf175ba7f52b5f7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95508 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Tor Lillqvist <tml@collabora.com>
2020-05-08lok: MSForms: Add callback for form field button.Tamás Zolnai
Show and hide the button and send the button area, where it should be displayed. Change-Id: I5922eb9f5e544483dd4efd12e4218d2e51270632 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93657 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-04-14lok: add tabstop changing and callback to send tabstop updatesTomaž Vajngerl
This adds callback LOK_CALLBACK_TAB_STOP_LIST to send the tabstops for the current paragraph. In addition it adds .uno:ChangeTabStop action, with which it is possible to change just one tabstop identified by the index. Change-Id: I7762ead12e47288cbb0b0a1c8ffb8e9872cee8e8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92147 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-03-06tdf#42949 Fix IWYU warnings in libreofficekit/Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ic57b1259e612cc38ad22f123edbaca690cd506ab Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89937 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-11-29lokdocview: Add notify_property when the document is initializedCorentin Noël
The property "is-initialized" was updated under the hood but no notification was sent to the user preventing to use features like g_object_bind_property Change-Id: If5fab557fbd2b3ae2b2531799548907404d79a33 Reviewed-on: https://gerrit.libreoffice.org/82472 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-11-29lokdocview: Add support for HiDPI renderingCorentin Noël
Change-Id: I3c6b8c958dec78de1457d06ceb81e56b9ae36ce9 Reviewed-on: https://gerrit.libreoffice.org/82714 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2019-11-26lok: calc formula bar tunneling: function list callbackMarco Cecchetti
Added a lok callback for sending the list of functions matching the current characters typed by the user. Change-Id: Ia971fc55ec5eb961b4098592a8049dd0eed3ba14 Reviewed-on: https://gerrit.libreoffice.org/83750 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-11-19lokdocview: Add support for get_command_valuesCorentin Noël
Change-Id: I6a007724de8aea0e4de035313855acd6e9342ee7 Reviewed-on: https://gerrit.libreoffice.org/82377 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2019-11-19Improved loplugin:external, handling class typesStephan Bergmann
...plus follow-up loplugin:fakebool and loplugin:consttobool findings Change-Id: I2b19d80f7313d3d5b0e502581b39fe20147bdfcc Reviewed-on: https://gerrit.libreoffice.org/83121 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2019-11-14New loplugin:consttoboolStephan Bergmann
...to: "Find implicit conversions from non-'bool' constants (e.g., 'sal_False') to 'bool'". Due to how FALSE is defined as just #define FALSE (0) (i.e., a literal of type 'int') but TRUE is defined as #define TRUE (!FALSE) (i.e., an implicit conversion from 'int' to 'bool') in GLib (see the comment in ConstToBool::VisitImplicitCastExpr), we get more warnings about uses of 'TRUE' than of 'FALSE'. For example, in libreofficekit/source/gtk/lokdocview.cxx there is a warning about the 'TRUE' in g_main_context_iteration(nullptr, TRUE); but not about the 'FALSE' in g_main_context_iteration(nullptr, FALSE); (where the parameter of 'g_main_context_iteration' is of type 'gboolean'). Lets live with that asymmetry for now... (Besides the issues addressed directly in this commit, it also found the two bogus asserts at 7e09d08807b5ba2fd8b9831557752a415bdad562 "Fix useless assert(true) (which would never fire)" and 122a0be8ae480473bd1d7f35e197a2529f4621e3 "Fix useless assert(true) (which would never fire)", plus 5f0d6df7f57ae281fe161e61c7f25d67453fddd2 "Use two-argument form of static_assert".) Change-Id: Id77322de9f94b85a7b65608a03e0e9865d14467b Reviewed-on: https://gerrit.libreoffice.org/82667 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>