summaryrefslogtreecommitdiff
path: root/basctl
AgeCommit message (Collapse)Author
2024-08-02cid#1556472 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1556481 COPY_INSTEAD_OF_MOVE cid#1556486 COPY_INSTEAD_OF_MOVE cid#1556491 COPY_INSTEAD_OF_MOVE cid#1556507 COPY_INSTEAD_OF_MOVE cid#1556515 COPY_INSTEAD_OF_MOVE cid#1556518 COPY_INSTEAD_OF_MOVE cid#1556519 COPY_INSTEAD_OF_MOVE cid#1556533 COPY_INSTEAD_OF_MOVE cid#1556536 COPY_INSTEAD_OF_MOVE cid#1556559 COPY_INSTEAD_OF_MOVE cid#1556577 COPY_INSTEAD_OF_MOVE cid#1556581 COPY_INSTEAD_OF_MOVE Change-Id: I2ad2f2194e2a89c7246e8742b2fc8be7580e38c3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171394 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-28cid#1556624 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1556622 COPY_INSTEAD_OF_MOVE cid#1556629 COPY_INSTEAD_OF_MOVE cid#1556632 COPY_INSTEAD_OF_MOVE cid#1556634 COPY_INSTEAD_OF_MOVE cid#1556642 COPY_INSTEAD_OF_MOVE cid#1556644 COPY_INSTEAD_OF_MOVE cid#1556663 COPY_INSTEAD_OF_MOVE cid#1556674 COPY_INSTEAD_OF_MOVE cid#1556682 COPY_INSTEAD_OF_MOVE cid#1556683 COPY_INSTEAD_OF_MOVE cid#1556685 COPY_INSTEAD_OF_MOVE cid#1556694 COPY_INSTEAD_OF_MOVE cid#1556708 COPY_INSTEAD_OF_MOVE cid#1556711 COPY_INSTEAD_OF_MOVE cid#1556712 COPY_INSTEAD_OF_MOVE cid#1556714 COPY_INSTEAD_OF_MOVE cid#1556719 COPY_INSTEAD_OF_MOVE cid#1556727 COPY_INSTEAD_OF_MOVE cid#1556744 COPY_INSTEAD_OF_MOVE cid#1556757 COPY_INSTEAD_OF_MOVE cid#1556782 COPY_INSTEAD_OF_MOVE cid#1556784 COPY_INSTEAD_OF_MOVE Change-Id: I5d5bc884cd7351a81c18b35aaf4e304256242988 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171128 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-07-24cid#1556131 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1556135 COPY_INSTEAD_OF_MOVE cid#1556146 COPY_INSTEAD_OF_MOVE cid#1556164 COPY_INSTEAD_OF_MOVE cid#1556171 COPY_INSTEAD_OF_MOVE cid#1556177 COPY_INSTEAD_OF_MOVE cid#1556181 COPY_INSTEAD_OF_MOVE cid#1556182 COPY_INSTEAD_OF_MOVE cid#1556183 COPY_INSTEAD_OF_MOVE cid#1556192 COPY_INSTEAD_OF_MOVE cid#1556201 COPY_INSTEAD_OF_MOVE cid#1556208 COPY_INSTEAD_OF_MOVE cid#1556215 COPY_INSTEAD_OF_MOVE cid#1556224 COPY_INSTEAD_OF_MOVE cid#1556227 COPY_INSTEAD_OF_MOVE cid#1556228 COPY_INSTEAD_OF_MOVE cid#1556238 COPY_INSTEAD_OF_MOVE cid#1556246 COPY_INSTEAD_OF_MOVE cid#1556247 COPY_INSTEAD_OF_MOVE cid#1556288 COPY_INSTEAD_OF_MOVE cid#1556293 COPY_INSTEAD_OF_MOVE cid#1556305 COPY_INSTEAD_OF_MOVE cid#1556310 COPY_INSTEAD_OF_MOVE cid#1556317 COPY_INSTEAD_OF_MOVE cid#1556321 COPY_INSTEAD_OF_MOVE cid#1556322 COPY_INSTEAD_OF_MOVE cid#1556331 COPY_INSTEAD_OF_MOVE cid#1556339 COPY_INSTEAD_OF_MOVE cid#1556342 COPY_INSTEAD_OF_MOVE cid#1556351 COPY_INSTEAD_OF_MOVE cid#1556358 COPY_INSTEAD_OF_MOVE cid#1556370 COPY_INSTEAD_OF_MOVE cid#1556379 COPY_INSTEAD_OF_MOVE cid#1556390 COPY_INSTEAD_OF_MOVE cid#1556423 COPY_INSTEAD_OF_MOVE cid#1556532 COPY_INSTEAD_OF_MOVE cid#1556561 COPY_INSTEAD_OF_MOVE cid#1556662 COPY_INSTEAD_OF_MOVE cid#1556704 COPY_INSTEAD_OF_MOVE cid#1556730 COPY_INSTEAD_OF_MOVE cid#1556988 COPY_INSTEAD_OF_MOVE cid#1557071 COPY_INSTEAD_OF_MOVE cid#1557081 COPY_INSTEAD_OF_MOVE cid#1557177 COPY_INSTEAD_OF_MOVE Change-Id: I2c723f0fe9a4eefa62a68f47049ed690d06eb0ba Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170932 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-23cid#1555167 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1555172 COPY_INSTEAD_OF_MOVE cid#1555184 COPY_INSTEAD_OF_MOVE cid#1555188 COPY_INSTEAD_OF_MOVE cid#1555197 COPY_INSTEAD_OF_MOVE cid#1555209 COPY_INSTEAD_OF_MOVE cid#1555211 COPY_INSTEAD_OF_MOVE cid#1555215 COPY_INSTEAD_OF_MOVE cid#1555216 COPY_INSTEAD_OF_MOVE cid#1555217 COPY_INSTEAD_OF_MOVE cid#1555218 COPY_INSTEAD_OF_MOVE cid#1555222 COPY_INSTEAD_OF_MOVE cid#1556674 COPY_INSTEAD_OF_MOVE cid#1555229 COPY_INSTEAD_OF_MOVE cid#1555233 COPY_INSTEAD_OF_MOVE cid#1555234 COPY_INSTEAD_OF_MOVE cid#1555242 COPY_INSTEAD_OF_MOVE cid#1555250 COPY_INSTEAD_OF_MOVE cid#1555251 COPY_INSTEAD_OF_MOVE cid#1555254 COPY_INSTEAD_OF_MOVE cid#1555304 COPY_INSTEAD_OF_MOVE cid#1555307 COPY_INSTEAD_OF_MOVE cid#1555317 COPY_INSTEAD_OF_MOVE cid#1555329 COPY_INSTEAD_OF_MOVE cid#1555340 COPY_INSTEAD_OF_MOVE cid#1555347 COPY_INSTEAD_OF_MOVE cid#1555352 COPY_INSTEAD_OF_MOVE cid#1555358 COPY_INSTEAD_OF_MOVE cid#1555363 COPY_INSTEAD_OF_MOVE cid#1555365 COPY_INSTEAD_OF_MOVE cid#1555367 COPY_INSTEAD_OF_MOVE cid#1555374 COPY_INSTEAD_OF_MOVE cid#1555380 COPY_INSTEAD_OF_MOVE Change-Id: I343194c10749488a1143e2517ee0638ab19da218 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170888 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-11Unify/Port to use VCLUnoHelper for AWT <-> VCL conversionsMichael Weghorn
Following Change-Id: Id48f81deb05aee2026509037f7d14575735e5be0 Author: Michael Weghorn <m.weghorn@posteo.de> Date: Wed Jul 10 14:49:03 2024 +0200 VCLUnoHelper: Align AWT <-> VCL helpers with convert.hxx impl , port all uses of the helper functions defined in `include/toolkit/helper/convert.hxx` to use the `VCLUnoHelper` equivalents instead, to unify usage and avoid duplication. Drop `include/toolkit/helper/convert.hxx` now that it's unused. Change-Id: I22695a93e40e47bb2b14d191a2e0a4eb7c856895 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170317 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2024-06-24Add newline at end of fileTaichi Haradaguchi
Change-Id: I731d8d80e075c8df8a104ec963b89337a91d536c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169376 Reviewed-by: Taichi Haradaguchi <20001722@ymail.ne.jp> Tested-by: Jenkins
2024-06-24Resave with newer Glade versionBogdan Buzea
Change-Id: I6abcf8d983550e92a2ccc768de47c2ccb6d8583b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169381 Tested-by: Jenkins Reviewed-by: Taichi Haradaguchi <20001722@ymail.ne.jp>
2024-06-23Resave with newer Glade versionBogdan Buzea
Change-Id: I3b06e8341b71d816df2cfa1f4343d48d4156cfbc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169370 Reviewed-by: Taichi Haradaguchi <20001722@ymail.ne.jp> Tested-by: Jenkins
2024-06-23Resave with newer Glade versionBogdan Buzea
Change-Id: Ibebe4caede19886e47a9ebbbcaf53c79df8511cf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169369 Reviewed-by: Taichi Haradaguchi <20001722@ymail.ne.jp> Tested-by: Jenkins
2024-06-18Add SfxItemType to SfxPoolItemOliver Specht
The SfxPoolItem has a new member SfxItemType m_eItemType to compare types based on enums instead of typeinfo() which consumes a lot of time e.g. while AutoFormat is running Change-Id: I033ce67bc9a28ee4790f162380314de85fb4154e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166452 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de> Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2024-06-04basctl: use SAL_RET_MAYBENULL in GetBindingsPtr()...Xisco Fauli
... GetDispatcher() and FindBasicManager() Change-Id: I6de6035f17b74313a5cbb9964ceafcbe3161ef2c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168397 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org> Tested-by: Jenkins
2024-06-03tdf#157664 Drop operator !=, where respective operator == is definedZainab Abbasi
Change-Id: Ib6f2338bf457b7a7e7b36152337bd777b9e1d293 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166192 Tested-by: Jenkins Tested-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org> Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2024-05-30AreObjectsMarked -> GetMarkedObjectList().GetMarkCount() != 0Xisco Fauli
In order to reduce number of calls to GetMarkedObjectList() later on Change-Id: Ib2eb7c88338e64744f886a338acca65f782f8170 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168218 Tested-by: Jenkins Tested-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2024-05-03loplugin:ostr in basctlNoel Grandin
Change-Id: I59c25d52d8f59ff1b7ab498041c2888b8e718f64 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167056 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-05-01WaE: C6011 Dereferencing NULL pointer warningsCaolán McNamara
Change-Id: I9870360076260e71c0e02375558606cbdb68fc08 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166960 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-04-29Drop uses of css::uno::Sequence::getConstArray in accessibility .. basegfxMike Kaganski
where it was obsoleted by commits 2484de6728bd11bb7949003d112f1ece2223c7a1 (Remove non-const Sequence::begin()/end() in internal code, 2021-10-15) and fb3c04bd1930eedacd406874e1a285d62bbf27d9 (Drop non-const Sequence::operator[] in internal code 2021-11-05). Change-Id: I14e3634d8e8dd294b673dcda4dde13f01c3e5112 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166813 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
2024-04-08tdf#146619 Drop unused 'using namespace' in: basctl/Gabor Kelemen
Change-Id: I7df9fa0e7de3cf7ee39ce96bf9ff32c54db14763 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165687 Tested-by: Jenkins Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-03-11Use weak reference to SfxObjectShell in SfxEventHint to avoid use-after-freeMike Kaganski
The events may be processed after the shell has been destroyed. This is happening reliably after commit e2bfc34d146806a8f96be0cd2323d716f12cba4e (Reimplement OleComponentNative_Impl to use IGlobalInterfaceTable, 2024-03-11) when controlling LibreOffice from external Java scripts; but obviously, it could happen before as well. Now SotObject inherits from cppu::OWeakObject, instead of SvRefBase. Change-Id: I73a3531499a3068c801c98f40de39bdf8ad90b2b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164458 Tested-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-03-10basctl : use OUstring literal for XServiceInfo implementationArnaud VERSINI
Change-Id: Iee7585585b5e01fad4609f37a06d2aeeff492123 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164304 Tested-by: Jenkins Reviewed-by: Arnaud Versini <arnaud.versini@pm.me>
2024-03-07add truncate-multiline for consistencyCaolán McNamara
Change-Id: Ib9c2e28b583dd3cc8d877d69a39dce73fd54fdba Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164488 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-02-16tdf#114441 : sal_uLong to better integer typesseturaj
Change-Id: I7c9df411775812cfea4a41e84d34782cc5a9578e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162424 Tested-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org> Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2024-02-12ITEM: ItemPool Rework (I)Armin Le Grand (allotropia)
Driving forward the Item reworks I now take the ItemPool in focus: It now does not hold any items anymore and should be renamed to something like ItemInfoProvider/ItemHelper, since it's main purpose is to provide the Defaults for the Item functionality. There is that SfxItemInfo, only a struct and bundling SlotID and ItemFlags. There are also the DefaultItems, just handled as ptrs in an array. It is/was always error-prone to keep these in sync. Remember that it's also necessary for the order to not only being sorted but being increments of one with no gaps allowed in the WhichIDs to which the Items are bound. I now bundled that to a new class ItemInfo that joins WhichID, SlotID, ItemFlags and the default Item. This is a pure virtual base class, it comes in three derivations: (1) ItemInfoStatic: This is supposed to be global static and hosts the Item in a std::unique_ptr to ensure cleanup. It is designed to be constructed once during runtime and being shared globally. It allows the ItemPtr to be nullptr to mark as non-static (if initial static is not possible for some reason) but still offers the needed data. Most cases (95%+) are of that case. The contained Item is owned by that instance. The flag isStaticDefault() is set at the Item. (2) ItemInfoDynamic: This is supposed to be used for cases where the Item cannot be static: Mainly for SfxSetItem (that needs a Pool itself in the contained SfxItemSet, so lifetime is bound to that Pool), but other cases showed up in the transition. These instances live while the Pool lives and get destructed when the Pool goes down. Also uses std::unique_ptr for the Item instance for as much automated cleanup as possible, the contained Item is owned by that instance, the instance by the Pool. The flag isDynamicDefault() is set at the Item. (3) ItemInfoUser: This is used for UserDefaults that can be set for every ItemInfo entry to 'overshadow' the default from the 'outside'. It uses a regular Item and the central access methods implCreateItemEntry/ implCleanupItemEntry to manage the Item instance, thus works like a SfxPoolItemHolder. The Item instance can be globally shared and re-used even when the Pool goes down. Instances belong to the Pool and are cleaned up when the Pool goes down. This Item does not need any further flag to be set. The ItemInfos are organized using a class called ItemInfoPackage: This bundles groups of ItemInfoStatic to functional instances. There are derivations/ implementations of this e.g. for Writer ItemPool bundling all the needed defaults for Writer, similar for draw/impress, Calc and other usages. These ItemInfoPackage can be 'registered' at an ItemPool using it's method registerItemInfoPackage. This does all the needed stuff to setup that group of ItemInfos at the Pool (It even sets internal vars First/LastWhich, that info can just be derived from the buildup ItemInfo Ptrs). The ItemInfoPackage has methods 'size()' and 'getItemInfo(index) to allow looping over it and deliver the infos the Pool needs. The (forced, pure virtual) overloads of getItemInfo in the specific implementations check for the ItemPtr being nullptr and create a exclusive incarnation of ItemInfoDynamic for the Pool if needed, returning that. The Pool owns the ItemInfoDynamic incarnations and uses the ItemInfoStatic directly. On shutdown it cleans up the ItemInfoDynamic as needed. The ItemInfoUser is used by the Pool when a UserDefault is set/used: for SetUserDefaultItem, GetUserDefaultItem, ResetUserDefaultItem. It is not held in a 2nd list, but directly in the list of ItemInfo'ptrs: To keep track of this an unordered_map is used that helds the original ItemInfo associated with the WhichID. That way no two lookups (as before) are needed to get the current Pool's default for any WhichID. The derivations of ItemInfoPackage are encapsulated and just allow access to an ItemInfoPackage& with a single method as return value. All use a static local instance of a std::array<ItemInfoStatic, FIXED_SIZE> which constructs all ItemInfoStatic and the static Item instances - if already possible. Sometimes it is necessary to overload the constructor to set some static instances for Items later than the lib init. These are also just marked with nullptr as Item instance. Some need to overload getItemInfo to complete instances of ItemInfoStatic, if needed, or create and deliver instances of ItemInfoDynamic. The registerItemInfoPackage also offers a optional lambda callback: there were two cases where local data from the Pool was needed to incarnate the item - just add that to the call to registerItemInfoPackage if needed, see examples in the adapted code. For the re-use of Items this means that now in SfxItemSet/SfxPoolItemHolder *true* static Items can and will be used without RefCount directly and globally. This is also the case for dynamic Items, with the exception of differing Pools for SfxSetItems which cannot be done. Future: That design is already prepared to allow solving that Pool-chaining problem: currently there are master/sub-pools and all accesses have to traverse that structure before even doing anything. For the future the idea is more to 'compose' a Pool by registering ItemInfoPackages, e.g. for Writer pool you may start with SfxItemPool, register the writer-specific ItemInfoPackage, then the one for DrawingLayer (if needed) and the one for EditEngine. It should also be possible to get to smaller granularities of that packages. Ideas for new ones will emerge. We might also think about composing Pools which can e.g. run Writer and Chart, so allowing to use Chart *without* OLE stuff in Writer - just ideas... More changes: - Adapted all stuff, cleaned up old stuff/ definitions - Removed FreezeIdRanges, that can be done once per Pool on-demand (and cannot be forgotten to be called) - Merged XOutdevItemPool with SdrItemPool and offered a ItemInfoPackage which joins both needed sets of Items - All the cleanup hassle with Pools and defaults cleaned up - Adapted all access methods of the pool to use that new stuff. Pool chaining currently stays, but I use a central method 'getTargetPool' instead of recursive calling to get the correct Pool for the action Change-Id: I2b8d3d4c3cc80b1d0d0b3c0f4bd90d7656b4bab7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163157 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2024-02-01tdf#140004 Toggle comment in the Basic IDERafael Lima
This patch adds the "toggle comment" functionality to the Basic IDE. The shortcut Ctrl + Alt + C is used to execute it. It works similarly to other code editors such as Kate and VSCode. Change-Id: Ifdae42b3729cc909baf87c729fe8c3cdf6428184 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162005 Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de> Tested-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
2024-02-01tdf#131641 Enter selected text in the search bar (Basic IDE)Rafael Lima
This patch makes the selected text in the code editor be automatically inserted in the search bar. Change-Id: Ibbe64aa3375a5a47dedb762001ed4b99f4b22e46 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162548 Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de> Tested-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
2024-01-31Related tdf#158750 Fix line highlight for all modules when color scheme changesRafael Lima
Prior to this patch, if a library had multiple modules and the color scheme was changed (via View - Color Scheme), the line hightlight color would only update for the current module and remain unchanged for the other modules in the same library. Change-Id: Idda78c07d02534dfedcd927c37116a2617500ebc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162818 Tested-by: Jenkins Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
2024-01-27Drop std::as_const from css::uno::Sequence iterationsMike Kaganski
Obsoleted by commit 2484de6728bd11bb7949003d112f1ece2223c7a1 (Remove non-const Sequence::begin()/end() in internal code, 2021-10-15) and commit fb3c04bd1930eedacd406874e1a285d62bbf27d9 (Drop non-const Sequence::operator[] in internal code, 2021-11-05). Change-Id: Idbafef5d34c0d4771cbbf75b9db9712e504164cd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162640 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-01-26tdf#153853 Line numbering and breakpoint should be on the left (RTL)Rafael Lima
As requested by the user in the ticket, the Line Numering and Breakpoint windows should be on the left side, even on RTL locales. Change-Id: Iad2ba8efa0a23a13cf88c2fa277c4eed45002aae Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162540 Tested-by: Jenkins Reviewed-by: Hossein <hossein@libreoffice.org>
2024-01-25Resolves: tdf#159368 crash on tools, macros, editCaolán McNamara
when launched from startcenter Change-Id: I362bfe27914445c3027b6e8a125a75cc31679678 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162557 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-01-24Related tdf#158749 The "Go to Line" dialog should not be resizableRafael Lima
Change-Id: I93c5c1b4a2832b60e194abd7e7d528362885bb24 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162461 Tested-by: Jenkins Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2024-01-23tdf#158749 Open "Go to Line" dialog from the statusbar in Basic IDERafael Lima
With this change, if the user clicks the StatusGetPosition item in the status bar, the Go To Line dialog will be shown. Change-Id: Iba75e2dbf6ba83fce24e1af237bdf9813d4ecb69 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162108 Tested-by: Jenkins Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2024-01-19tdf#159247 Fix crash while adding control with default properties (Dialog ↵Rafael Lima
Editor) Controls created using the Ctrl+toolbar (which adds a control with default properties) did not have a parent form, which causes the crash. Change-Id: Ic2f469e6656a93bbed25d86092384f81b21aaca5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162217 Tested-by: Jenkins Reviewed-by: Patrick Luby <plubius@libreoffice.org> Reviewed-by: Rafael Lima <rafael.palma.lima@gmail.com>
2024-01-18tdf#159221 Fix color scheme names under Gtk3 (Basic IDE)Rafael Lima
Color scheme names were not appearing in the "Color Scheme" dialog in the Basic IDE under gtk3 (View - Color Scheme). This patch fixes that. Change-Id: I9b019f3ed867ca6f45b53d67a3dc01139251391e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162215 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-01-12cid#1545535 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1545526 COPY_INSTEAD_OF_MOVE cid#1545442 COPY_INSTEAD_OF_MOVE cid#1545426 COPY_INSTEAD_OF_MOVE cid#1545425 COPY_INSTEAD_OF_MOVE cid#1545387 COPY_INSTEAD_OF_MOVE cid#1545379 COPY_INSTEAD_OF_MOVE cid#1545337 COPY_INSTEAD_OF_MOVE cid#1545334 COPY_INSTEAD_OF_MOVE cid#1545289 COPY_INSTEAD_OF_MOVE cid#1545282 COPY_INSTEAD_OF_MOVE cid#1545270 COPY_INSTEAD_OF_MOVE cid#1545237 COPY_INSTEAD_OF_MOVE Change-Id: Iae44a7347c85ae2e367bf672214b2013f30466f6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161968 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-01-11tdf#158750 Highlight the line where the cursor is positioned (Basic IDE)Rafael Lima
This patch implements support for highlighting the selected line in the code editor, similar to what Kate, VSCode, etc do. If the cursor is positioned in a single line and nothing is selected, then a highlight color is applied to the line. The line number window also highlights the selected line. Change-Id: I2047d79500cd783b122b6752bb00996de0a7c702 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161861 Tested-by: Jenkins Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
2024-01-11tdf#155381 Remember the visibility of UI components in the Basic IDERafael Lima
This patch remembers the visibility of the Object Catalog, Watched Expressions and Stack Window in the Basic IDE. Change-Id: I2fea038ffc56af45cd6570feeb14ab84307f8cef Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161852 Tested-by: Jenkins Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
2024-01-10cid#1583747 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1583746 COPY_INSTEAD_OF_MOVE cid#1583745 COPY_INSTEAD_OF_MOVE cid#1583744 COPY_INSTEAD_OF_MOVE Change-Id: Ib63c469844925723645f01720f8cebc60388ae29 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161875 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-01-09Fix typoAndrea Gelmini
Change-Id: I75bcd6459f0bb8d0dcaf4d5646e31da2b71fb78f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161804 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2024-01-09Fix typoAndrea Gelmini
Change-Id: Icf3d2feb84f287e3e75f1eab488ec2804cd22a40 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161803 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2024-01-08tdf#156925 Add Color Scheme selector to the Basic IDERafael Lima
This patch implements a color scheme selector for the Basic IDE. With this new feature the user can either: 1) Choose to stick with "Application Colors", meaning that the colors defined in "Tools - Options - Application Colors" are applied. 2) Use one of the available color schemes in the dialog To access the color scheme dialog, go to View - Color Scheme. A color schema was defined in the "BasicIDE.xcs" file and six color schemes were defined in "BasicIDE.xcu" to be shipped with LibreOffice. This way, it is possible to install more color schemes via extensions; Change-Id: I5d382d19f982d02ba3c0fda5d1596aed2c38f13c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155928 Tested-by: Jenkins Tested-by: Heiko Tietze <heiko.tietze@documentfoundation.org> Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org> Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de> Reviewed-by: Rafael Lima <rafael.palma.lima@gmail.com>
2023-12-30cid#1545421 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1545403 COPY_INSTEAD_OF_MOVE cid#1545397 COPY_INSTEAD_OF_MOVE cid#1545376 COPY_INSTEAD_OF_MOVE cid#1545339 COPY_INSTEAD_OF_MOVE cid#1545288 COPY_INSTEAD_OF_MOVE Change-Id: I0e24a3fc7148d0b7ff8126debe3cddbb4fbdd713 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161453 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-12-26cid#1545970 COPY_INSTEAD_OF_MOVECaolán McNamara
Change-Id: Ifbec5f91dd11a495fcf01ad95fcdcc867e882f70 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161293 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-12-23cid#1546006 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1545999 COPY_INSTEAD_OF_MOVE cid#1545995 COPY_INSTEAD_OF_MOVE cid#1545994 COPY_INSTEAD_OF_MOVE cid#1545989 COPY_INSTEAD_OF_MOVE cid#1545982 COPY_INSTEAD_OF_MOVE cid#1545977 COPY_INSTEAD_OF_MOVE cid#1545970 COPY_INSTEAD_OF_MOVE cid#1545856 COPY_INSTEAD_OF_MOVE cid#1545845 COPY_INSTEAD_OF_MOVE cid#1545838 COPY_INSTEAD_OF_MOVE cid#1545776 COPY_INSTEAD_OF_MOVE cid#1545774 COPY_INSTEAD_OF_MOVE cid#1545744 COPY_INSTEAD_OF_MOVE cid#1545719 COPY_INSTEAD_OF_MOVE cid#1545716 COPY_INSTEAD_OF_MOVE cid#1545687 COPY_INSTEAD_OF_MOVE cid#1545648 COPY_INSTEAD_OF_MOVE cid#1545643 COPY_INSTEAD_OF_MOVE cid#1545641 COPY_INSTEAD_OF_MOVE cid#1545604 COPY_INSTEAD_OF_MOVE cid#1545531 COPY_INSTEAD_OF_MOVE cid#1545530 COPY_INSTEAD_OF_MOVE cid#1545524 COPY_INSTEAD_OF_MOVE cid#1545516 COPY_INSTEAD_OF_MOVE cid#1545501 COPY_INSTEAD_OF_MOVE cid#1545486 COPY_INSTEAD_OF_MOVE Change-Id: Idcf3e27bb9e81b6a77d5ef75c9376eb1d6aff8c9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161245 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-12-21Remove DeleteItemOnIdlexArmin Le Grand (allotropia)
There are some CrashReports in 7.6 which have DeleteItemOnIdle on the stack, but there is nothing reproducable. So I took a look... I first thought it's a MCGR regression, due to classes on the stack. But the Item involved is just random, can happen with any Item. Then I thought it may have to do with ITEM refactorings, but it happens with DeleteItemOnIdle involved, so also not the case. I already saw DeleteItemOnIdle when doing these and qualified as 'hack' in the way. already It is only on Windows and DeleteItemOnIdle is involved. This again (took a deeper look now) is an old hack to keep an SfxPoolItem 'alive' for some 'time'. For that, it triggers an async reschedule which then deletes the Item when being called. If the Item will be used after that is pure coincidence - seems to work in most cases. It seems as if for Windows the timing slightly changed for some scenarios, so a reschedule is too early. This can happen with this hack anytime. DeleteItemOnIdle is used in scenarios where SfxPoolItem* is e.g. returned, but is *not* anchored, so e.g. not member of an SfxItemSet. Or in short: Lifetime is not safe. DeleteItemOnIdle exists since 1st import, but was changed to AsyncEvent ca. 4 months ago (see 57145acf9ec47c23e307b7a5c0029d21d937cc35), so that may have caused it. It is possible that these errors happen on Windows since then. Before something more complicated was used to delete it late, but surely also not really safe. Due to ITEM refactor I have the knowledge/tooling to solve this. It will not be a 1-5 lines fix, but it is a hack and in the way for further ITEM refactor anyways. What we have nowadays is a SfxPoolItemHolder -> it's like an SfxItemSet for a single Item. It safely holds/ controls the lifetime of an SfxPoolItem. It is already used in quite some places. It helps to solve many hacks, also the ones putting Items directly to the Pool - due to there never was an alternative for that. In principle the ItemPool/ItemSet/Item paradigm was never complete without SfxPoolItemHolder. Thus I started to fix that (and remove that hack for good, sooo many changes over the years, sigh), but as said is not straightforward. Will have to change retvals of involved stuff to SfxPoolItemHolder - it's just two pointers and designed to be copied (one is a Pool, needed to cleanup when destructing). CopyConstruct/destroy just counts the RefCnt up/down, so cheap. 1st version compiling, let's check on gerrit... Corrected one error in QueryState for securitypage, also added some security features/asserts. Change-Id: Ida49fd35ca88ead84b11d93e18b978cb9e395090 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161083 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2023-12-20capture these explicitly by nameCaolán McNamara
Change-Id: I0908aedada9c59426373080d7d3894b452693939 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161076 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-12-16cid#1545970 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1545957 COPY_INSTEAD_OF_MOVE cid#1545944 COPY_INSTEAD_OF_MOVE cid#1545939 COPY_INSTEAD_OF_MOVE cid#1545931 COPY_INSTEAD_OF_MOVE cid#1545926 COPY_INSTEAD_OF_MOVE cid#1545909 COPY_INSTEAD_OF_MOVE cid#1545899 COPY_INSTEAD_OF_MOVE cid#1545896 COPY_INSTEAD_OF_MOVE cid#1545894 COPY_INSTEAD_OF_MOVE cid#1545858 COPY_INSTEAD_OF_MOVE cid#1545823 COPY_INSTEAD_OF_MOVE cid#1545820 COPY_INSTEAD_OF_MOVE cid#1545819 COPY_INSTEAD_OF_MOVE cid#1545772 COPY_INSTEAD_OF_MOVE cid#1545749 COPY_INSTEAD_OF_MOVE cid#1545743 COPY_INSTEAD_OF_MOVE cid#1545739 COPY_INSTEAD_OF_MOVE cid#1545635 COPY_INSTEAD_OF_MOVE cid#1545603 COPY_INSTEAD_OF_MOVE cid#1545602 COPY_INSTEAD_OF_MOVE cid#1545592 COPY_INSTEAD_OF_MOVE cid#1545544 COPY_INSTEAD_OF_MOVE cid#1545532 COPY_INSTEAD_OF_MOVE cid#1545520 COPY_INSTEAD_OF_MOVE cid#1545512 COPY_INSTEAD_OF_MOVE cid#1545490 COPY_INSTEAD_OF_MOVE cid#1545483 COPY_INSTEAD_OF_MOVE cid#1545467 COPY_INSTEAD_OF_MOVE cid#1545461 COPY_INSTEAD_OF_MOVE cid#1545458 COPY_INSTEAD_OF_MOVE cid#1545428 COPY_INSTEAD_OF_MOVE cid#1545394 COPY_INSTEAD_OF_MOVE cid#1545385 COPY_INSTEAD_OF_MOVE cid#1545383 COPY_INSTEAD_OF_MOVE cid#1545366 COPY_INSTEAD_OF_MOVE cid#1545357 COPY_INSTEAD_OF_MOVE Change-Id: I76224326977b4067b94ca3176cad1ca6de17930a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160847 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-12-08cid#1545617 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1545748 COPY_INSTEAD_OF_MOVE cid#1545741 COPY_INSTEAD_OF_MOVE cid#1545698 COPY_INSTEAD_OF_MOVE cid#1545594 COPY_INSTEAD_OF_MOVE cid#1545588 COPY_INSTEAD_OF_MOVE cid#1545558 COPY_INSTEAD_OF_MOVE cid#1545545 COPY_INSTEAD_OF_MOVE Change-Id: I5dfec77a68959b9384fc71a2fc0908c5d1b42869 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160448 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-12-07simplify and modernise ScopedBitmapAccessNoel Grandin
(*) Make all of it use a "Scoped" paradigm (*) pass by value, no need to allocate on heap (*) make all of the construction go via the *Access constructors, instead of it being some via the constructors and some via the Acquire*Access methods. (*) take the Bitmap& by const& in the constructor, so we can avoid doing const_cast in random places. Change-Id: Ie03a9145c0965980ee8df9a89b8714a425e18f74 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160293 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-12-05Resolves: tdf#158441 we don't want to return early for all handled keysCaolán McNamara
a problem since: commit c39bd1f6690ade936d62a66265b9b277061024d8 Author: Caolán McNamara <caolanm@redhat.com> Date: Wed Feb 19 10:13:15 2020 +0000 weld CodeCompleteWindow Change-Id: I520a591bad89515c973098f4200f01ae0ddbdc34 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160337 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-11-18c++20: use std::erase instead of std::removed followed by erase (part 1)Julien Nabet
Change-Id: I8d038fc37a4de25bdeff2e2cc55775e3981240b7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159610 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2023-11-08loplugin:stringstatic, lopluign:ostr (clang-cl)Stephan Bergmann
Change-Id: I7a928a2385286f6d1ab3887c8d315af3f47c052d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159135 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>