Found after running bin/find-unneeded-includes --headersfwd include/vcl/[A-Z]*
This shaves off about 100M input, not bad for such a small amount
of files checked
This time --headersfwd skips files that contain #if defs,
in hope of not breaking builds that are not checked by CI
(...except for include/vcl/BitmapTools.hxx - this was cleaned accidentally,
due to a bug in the bin/find-unneeded-includes script that is fixed
by the previous commit 930ff2b830
- but let's keep this anyway, it seems fine)
Change-Id: Ia8e49d94f6adb3cdbedbc40ffa56dbf846c9b6e4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196235
Reviewed-by: Gabor Kelemen <gabor.kelemen@collabora.com>
Tested-by: Jenkins
This means that native Qt widgets are used for that dialog
now when using the qt5 or qt6 VCL plugin and starting LO with
environment variable SAL_VCL_QT_USE_WELDED_WIDGETS=1 set.
The dialog can be triggered like this:
* start Writer
* "Insert" -> "OLE Object" -> "OLE Object..."
Change-Id: I646bbe0e62e0da500630bae19e469bc24ecd53c3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196461
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
The MRU entries are logically a list/vector, so
use a vector of strings for those in the weld::ComboBox
API instead of a serialized string.
Instead of (de)serializing to/from string in each
of the weld::ComboBox implementations, let the
caller take care of that.
Also adjust the underlying vcl widgets used
by SalInstanceComboBoxWithEdit accordingly.
At this point in time, FontNameBox (use for the
font combobox in the Writer formatting toolbar)
is the only user of the API.
No change in behavior expected or seen in a quick
test using that combobox. (After selecting entries
in that combobox, they show up in the MRU list at
the top as expected and are restored when exiting
and restarting Writer.)
For GtkInstanceComboBox, GtkInstanceComboBox::get_mru_entries
was seen returning a vector with an empty entry initially.
Explicitly filter out empty strings to avoid that.
(It was not a problem before, because an empty string
was interpreted as "no entries", while a vector with
a single entry consisting of an empty string is no more.)
Change-Id: I8422e1abaaabaa500cdffaba1fae97638bd4d5f0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196460
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Implement these QtInstanceComboBox methods by
by creating a QtInstanceEntry for the combobox's
entry/QLineEdit and calling the corresponding
weld::Entry methods.
Change-Id: Ib6ffe878c18a4a90c8ad227aae3957a646ef7479
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196459
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Implement clipboard-related methods in
QtInstanceComboBox by creating a QtInstanceEntry
for the combobox's entry/QLineEdit and calling the corresponding
weld::Entry methods.
Change-Id: I0ed2c5180e36ab85ad7414a2069100490e05a62c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196458
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
Move the duplicate logic to set the font (color) from
QtInstanceEntry and QtInstanceTextView to a new
shared base class QtInstanceTextWidget.
Change-Id: I817aa8342b6126c8dcdd1cf2a6f0b137faf12db1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196457
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
Add an implementation of TextWidget::paste_clipboard
right in the abstract base class, as it provides
all relevant API to do that.
Drop the QtInstanceEntry and QtInstanceTextView
overrides that would so far only trigger an assert.
For now, leave the GTK and vcl
implementations/overrides in place.
Change-Id: Ia41cad18204781ee7982e06bb2b51afdeeb5fbd1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196455
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Add an implementation of TextWidget::cut_clipboard
right in the abstract base class, as it provides
all relevant API to do that.
Drop the QtInstanceEntry and QtInstanceTextView
overrides that would so far only trigger an assert.
For now, leave the GTK and vcl
implementations/overrides in place.
While it's probably not relevant in practice, those
might be more efficient than operating on the whole text
of the widget to extract the relevant substring to copy/cut.
Change-Id: I9b4f70daa3f3fa7af2fb16cfc0d840d9da6551a1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196454
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Add an implementation of TextWidget::copy_clipboard
right in the abstract base class, as it provides
all relevant API to do that.
Drop the QtInstanceEntry and QtInstanceTextView
overrides that would so far only assert.
For now, leave the GTK and vcl
implementations/overrides in place.
While it's probably not relevant in practice, those
might be more efficient than operating on the whole text
of the widget to extract the relevant substring to copy.
Change-Id: I9333ce659cecc5155f4bcf424ad1989919623142
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196453
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
So far, weld::TextView::replace_selection was
blocking signals, by not being virtual itself
but calling a virtual helper method
weld::TextView::do_replace_selection and
blocking signals while doing so, while
weld::Entry didn't do that.
The weld::TextView behavior is consistent
with how signals are handled elsewhere
(only emitted on user-triggered changes,
not programmatic ones).
Therefore, align the weld::Entry behavior
with the weld::TextView one, and move the
logic to the common base class, weld::TextWidget.
It seems unlikely that any existing code using
weld::Entry would rely on signals being emitted,
but if that turns out to be the case (i.e. behavior
regresses with this commit), that code should
probably be adjusted as necessary.
This also prepares for implementing
clipboard-related methods directly in
the weld::TextWidget base class in an upcoming
commit.
Change-Id: I566c70bd98bbb92430107b1d40f9ee338fdbd749
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196451
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
weld::Entry and weld::TextView have quite some logic
that is the same for both classes.
Introduce weld::TextWidget as new abstract base class
for both classes and move some logic there, in order to
deduplicate that and ensure the API for both classes
stays consistent (as now, both are changed at the
same time when the signature for any common method is
changed).
weld::Entry::get_saved_value didn't have a
weld::TextView equivalent before, so this is
implicitly added with this commit.
This refactoring also prepares for implementing
clipboard-related methods directly in
the weld::TextWidget base class in an upcoming
commit.
Change-Id: I68cbea4c9bb1438976f7473bd752e07175ee91dc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196450
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Move the class out of weld.hxx into its own header and source
file, in order to make it easier to keep an overview and to avoid
having to recompile ~all UI code when the class is
modified.
Change-Id: I27033905fe8be1c3646c8cf08799c9bf53eeb471
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196448
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Move the class out of weld.hxx into its own header file,
in order to make it easier to keep an overview and to avoid
having to recompile ~all UI code when the class is
modified.
This also prepare for moving weld::Entry (which is
a weld::FormattedSpinButton base class) to its own header.
Change-Id: Iceb05e4055a22d483be9e0052199f738a7406097
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196447
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
Now that
Change-Id: I6555d2343ec9b01d7915cd52508c0db4c8704509
Author: Michael Weghorn <m.weghorn@posteo.de>
Date: Sat Jan 3 11:48:36 2026 +0100
weld: Move weld::SpinButton to own header/source
introduced a source file for weld::SpinButton method
implementations, move these 2 static methods there, too.
Change-Id: Ib37bc7af03df32e4566a7c3ab3c4c3d0db15806b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196446
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
Move the class out of weld.hxx into its own header and source
file, in order to make it easier to keep an overview and to avoid
having to recompile ~all UI code when the class is
modified.
Change-Id: I6555d2343ec9b01d7915cd52508c0db4c8704509
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196445
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
- give warning if a header is skipped because it contains #if defs
- give an option to still check those (together with --noexclude)
Change-Id: I9e878b213300a53b6236325f2bafb280f8b0290f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196396
Reviewed-by: Gabor Kelemen <gabor.kelemen@collabora.com>
Tested-by: Jenkins
Move the class out of weld.hxx into its own header and source
file, in order to make it easier to keep an overview and to avoid
having to recompile ~all UI code when the class is
modified.
Change-Id: I05a3ae87147fedfa39f4acd8c3f744fd88a83e5e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196442
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
Move the class out of weld.hxx into its own header and source
file, in order to make it easier to keep an overview and to avoid
having to recompile ~all UI code when the class is
modified.
Change-Id: I43279e6479c9a0b5c9521dadf6e634e22bf39442
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196438
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
Move the class to its own header and source file.
This prepares for an upcoming commit to return a weld::Assistant*
from weld::AssistantController::getDialog without having to
include weld.hxx (or an upcoming Assistant.hxx) in DialogController.hxx.
Change-Id: I4f9467cdf8d4e136fca7628cfd5e0975b4855d66
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196436
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
Move the class out of weld.hxx into its own header and source
file, in order to make it easier to keep an overview and to avoid
having to recompile ~all UI code when the class is
modified.
Change-Id: Ib2fe4a6b5e34ad8ae2194ba85249ca25ed16e9d5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196435
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
This is similar to
commit 82edaf048b
Author: Michael Weghorn <m.weghorn@posteo.de>
Date: Sun Dec 21 01:36:30 2025 +0100
weld: Return std::unique_ptr in weld::ItemView::get_selected
, but now for weld::TreeView::get_dest_row_at_pos.
See the above-mentioned commit for more background.
Change-Id: I53834d637e558e9ee3be341f653dbaed73082ebe
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196405
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Instead of having an out param and a bool return value,
return a std::unique_ptr and create the weld::TreeIter
inside of the method implementation instead of having
to do so in the caller.
This is similar to
commit 82edaf048b
Author: Michael Weghorn <m.weghorn@posteo.de>
Date: Sun Dec 21 01:36:30 2025 +0100
weld: Return std::unique_ptr in weld::ItemView::get_selected
that simplified weld::ItemView API.
Change-Id: I7ede7f51f76b35fdeec45c3373a19a3808429b38
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196391
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
By now, this class member is only used in one method.
Use a local variable instead.
Change-Id: Ic2f096aaef9c34d7f697b6ca0a204780db69a28d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196390
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
This is similar to
commit 82edaf048b
Author: Michael Weghorn <m.weghorn@posteo.de>
Date: Sun Dec 21 01:36:30 2025 +0100
weld: Return std::unique_ptr in weld::ItemView::get_selected
, but now for weld::ItemView::get_cursor.
See the above-mentioned commit for more background.
Change-Id: I6a8d8daa3dd3326c2716c0c0b4e4cb424f73ecb8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196389
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
It is only used by that subclass (and subclasses of that
subclass), so there's no need to have it in the
ThumbnailView base class.
Change-Id: Iafb2578ca90e9ccd50b5393621a34f56de6e55da
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196385
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
For RecentDocsView, the base class member
ThumbnailView::mxContextMenu is set but unused.
Drop the menu altogether and have a default param
in the ThumbnailView ctor for the menu instead to
not have to explicitly pass a null one.
Change-Id: I46528a662aaf7dc738eb97a7aa81aa32fc04ae79
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196384
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins