summaryrefslogtreecommitdiff
path: root/svtools/source/control/ctrlbox.cxx
AgeCommit message (Collapse)Author
2021-08-17tdf#143357 use a DateFormatter and a separate Calendar menubuttonCaolán McNamara
similar to what we ended up with in DateControl in svtools/source/brwbox/ebbcontrols.cxx Change-Id: I37c843ff7e1e8e39b318db80fe590ce5f796f46a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120453 Tested-by: Jenkins Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2021-07-15crashreporting: Crash seen in CachePreview from Idle UpdateHdlCaolán McNamara
the intent here is regenerate the previews if font settings changed which should mean that we restart at index 0 and not continue from the old index https: //crashreport.libreoffice.org/stats/crash_details/a01c5fcd-983b-40ab-b90a-8ee90286e5b8 Change-Id: I9604ad96cf6cc757d2d33469827d1295d309454d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118922 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-05-21add Toggleable as a separate thing to a ButtonCaolán McNamara
and inherit ToggleButton from both it and Button Change-Id: If0e500aca8d0ffa087cb5e2bfc1786372fbff4eb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115921 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-04-27use more string_view in tools/streamNoel Grandin
Change-Id: I2a957cd72d71fea717734488cdb3670e0bcdd6f4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114657 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-13merge the various SetPointFont via DefaultDevice callsCaolán McNamara
Change-Id: I769bb95c588c7222ff0dc6c4b845dfc3f0d7cbc0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112390 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-03-04Related tdf#140762 Add texts for "Border style" toolbar itemMichael Weghorn
Make 'GetLineStyleName' a static method of 'SvtLineListBox' and use it to retrieve and set the names for the items used in the "Border Style" dropdown button in Calc's formatting toolbar. This ensures that the corresponding names are available as tooltips and for screen readers. Change-Id: I6b775e1bcd62deefd8a8a6a778dcee426bf3a1f3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111905 Tested-by: Michael Weghorn <m.weghorn@posteo.de> Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2020-12-01tdf#42949 Fix new IWYU warnings in directories s*Gabor Kelemen
Except recently checked sc, sd, svx, sw Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ice1b86628e4f22a39f307b9c5fa567b6ab9d5acb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106917 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-10-29tdf#132536 free the cached VirtualDevicesJan-Marek Glogowski
Once again I forgot, that VclPtr is not really a shared pointer, as someone has to release the contained instance. It just prevents others from working on a dangling pointer and also freeing the contained instance multiple times. Using a "Scoped" variant in the vector instead of the loop doesn't compile. This fixes the major memory leak when deleting the last FontNameBox, which freed the caching VclPtr vector but not the contained VirtualDevice instances. It seems there is still some other minor leak left to fix, probably unrelated to the regressing patch. Found, after I realized the memory leak just happened with font preview enabled... Regressed-by: 2e0a32b51681fb356699b4a722f461f55a46b890 Change-Id: Ic0c60cd31bb6dabf03b0f8bd232390e784421588 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105017 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2020-10-28convert some more long -> tools::LongNoel
grepping for stuff in template params this time Change-Id: Ia37bfd85480b3a72c3c465489581d56ad8dde851 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104855 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-19use tools::Long in svtoolsNoel
Change-Id: I2b26da23e625e643dc2bb5393abff3671c457884 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104518 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-06loplugin:const& make some params and methods constNoel
Change-Id: I2973128a9c6c53187e1da400d1a5df763d515596 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104020 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-09-28rename for disentangling AA and B2D use in VCL drawingLuboš Luňák
This renames AntialiasingFlags::EnableB2dDraw to just Enable, and the AntiAliasB2DDraw names to just AntiAlias. This is in preparation for a second commit that will actually separate the AA and B2D functionality of these flags. Change-Id: I9cc215c5752dfabce41e00e19d9074fc8dc3d4de Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103416 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-09-12replace sal_IntPtr with simple integer typeCaolán McNamara
Change-Id: I5aaf606b684b69641a872b3405b4d4d378289ad4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102466 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-09-11invalidate prerendered fontname cache on style changeCaolán McNamara
Change-Id: Ie2111f23dc3346b914442090e3d9257c5659fafc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102459 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-09-02replace unnecessary includeCaolán McNamara
Change-Id: I799dcb6e7042e6d0174616458fa09b80ede59163 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101910 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-07-28drop use of SvtFontOptionsCaolán McNamara
Change-Id: Ib3ef6ec415d5e61d484e338290030fac2ed7b215 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99647 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-07-04tdf#134479 allow disable font preview to work on existing font comboboxesCaolán McNamara
not just newly created one. you can only restore back to a text-only view, not a text+(icon/whatever) view Change-Id: Ic3becd7a942ee6b1dbabb57eebf1e25d1b626fdb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/97972 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-05-22tdf#133043 explicitly set the combobox edit textCaolán McNamara
because earlier we set it to "" rather that set_active(-1) so its still at the same active pos with the wrong text so setting a new active pos that's the same as the old active pos is a nop from the vcl case the original code used Edit::SetText so leave the logic as it is traditionally rather than try to change that Change-Id: I520d1c0371579850d073d37295ccc7d852298aaa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94699 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-05-19Related: tdf#132536 limit to ~25 pre-rendered font previews for nowCaolán McNamara
The font caches look b0rked, the massive charmaps are ~never swapped out, and don't count towards the size of a font in the font cache and if the freetype font cache size is set experimentally very low then we crash, so there's an awful lot to consider there. Change-Id: I0e322109c02b00cfb6aff88b4fa650ac3cb1f178 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94466 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-04-29don't run generate preview idle if there are no fonts in the listCaolán McNamara
and reset preview idle when font list is cleared Change-Id: Ice8c149754fbf64c9f81aa812465f0269de4c9d0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93161 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-04-26tdf#132424 don't generate font previews in advance for loolCaolán McNamara
Change-Id: I393db7b019fe16b2b7361bd20ec99dc5671ba1ef Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92943 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-04-25rename SvtValueSet back to ValueSetCaolán McNamara
Change-Id: I51ab96ffef7acc0d416d13ac8e380e49381f4d1d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92902 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-04-24weld StylesPropertyPanelCaolán McNamara
and SvxStyleToolBoxControl, etc. use a GtkOverlay to support the submenu hackery in the Style wysiwyg combobox dropdown Change-Id: I17baa56f382243070ee49e6d707e97324e4f4d67 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/85720 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-04-22tdf#42949 Simplify use of rtl::math::approxEqual in include/basegfx/Gabor Kelemen
Turns out we can save about 500Mb of preprocessor input if we use rtl_math_approxEqual from rtl/math.h instead of its C++ wrapper rtl::math::approxEqual from rtl/math.hxx and manage the fallout accordingly. Before: bin/includebloat.awk | head sum total bytes included (excluding system headers): 19017296671 After: $ bin/includebloat.awk | head sum total bytes included (excluding system headers): 18535432672 Change-Id: I1691171f3a309405a7099882ad9989d147f59118 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92508 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-04-21weld FontNameBoxCaolán McNamara
with custom row rendering Change-Id: Ia909b5b9ad56b6ea4611e9ea0a1e2cb0064a8cd4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91841 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-04-20drop EnableSelectAllCaolán McNamara
Change-Id: I57dcca28daf7fe8544ee524b8b41bbc1fe591fac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92489 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-04-06remove newly unused stuffCaolán McNamara
Change-Id: Idce9955294372817c0dd1f40ebd38f16fc90eab5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91007 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-03-13Revert "loplugin:constfields in svtools"Noel Grandin
This reverts commit 07c4aa4298f062cee1894b80ef82e76d5ffcf4c7. Change-Id: Ic3f639581b9aca373f82c011f15be60d117b1943 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90476 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-03-09save/restore the entry text of the fontsize widgetCaolán McNamara
instead of its value, because the min value is 2, but we set empty text to indicate multiple values are selected in the underlying text. Change-Id: If4232b500cd177a264aa5e6ca0537021483db95f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90208 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-14split StringToMetric and TextToValue into fieldvalue.hxxCaolán McNamara
Change-Id: I5d1102f7a50a7a246df9f6de8b7a6df6557eb54d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88682 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-14split out MetricField value conversion functionsCaolán McNamara
Change-Id: I67a33bd2a5cb06dc66e471918b5c378044a2eff2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88679 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-11cypress: mobile: Font size combobox is broken on core/master.Caolán McNamara
so https://cgit.freedesktop.org/libreoffice/online/commit/?id=08d6c3fdf9bac4ad8318151ab1402690eb950f52 isn't needed Change-Id: I8836969ae064342835287a63065e591f083f2220 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88433 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-08cid#1458164 silence Unchecked return valueCaolán McNamara
Change-Id: If5c77b40195e7f6599fa24c1317c22507043de32 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88240 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-06no FontNameBox exists in any .ui file anymoreCaolán McNamara
Change-Id: I9ca3a4da0cd9bcc2b528d5c761a55efd2a4de2f9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88106 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-06drop unnecessary includeCaolán McNamara
Change-Id: Ifb7e34d5648238a1cf0a893a6713671fa6881161 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88066 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2020-02-06rename SvtFontSizeBox back to FontSizeBoxCaolán McNamara
Change-Id: I2ec0c6dd376f3a192a62dc97f7454af946e2a5ce Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88065 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-06drop newly unused FontSizeBoxCaolán McNamara
Change-Id: I8a84ce74888e1d3c468251ddd3633aedf6339a11 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88064 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-06weld SvxFontSizeBox_ImplCaolán McNamara
which enables making a native gtk widget a member of a toolbar This widget wants to distinguish between a value getting selected by the menu or not, which is fairly tricky Change-Id: I9014785530bd0d82ffa66842f940feb2d3237e68 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87971 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-06svtlo-FontSizeBox now appears in no .ui fileCaolán McNamara
Change-Id: I711a5d1b7a6ced113ac0c671ea1ba868d70d6346 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88063 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-03rename SvtFontStyleBox back to FontStyleBoxCaolán McNamara
Change-Id: I709f100541964b8740a7d0639a58214b1553458f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87836 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-03FontStyleBox is unusedCaolán McNamara
Change-Id: I1490c41c86a2f2a51ffc591a4d32499ab7b5faef Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87835 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-02-03FontStyleBox does not appear in any .ui files anymoreCaolán McNamara
Change-Id: I8da23000064c475863b3b911207fa220ed662a2f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87834 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-01-20loplugin:unusedfieldsNoel Grandin
Change-Id: If130c8a4861998d7eafd2e9525592f3c811ec21c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87069 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-12-09weld Property BrowserCaolán McNamara
Replaced the odd HyperlinkField Edit whose text can be clicked on to activate listeners, with an ordinary Edit and a Button beside it which can be clicked instead to do that. I couldn't find a real world use of this HyperlinkField in the forms or control properties, nor in casual experimentation in the sidebar in the basicide dialog editor. Also replaced the other strange Edit-alike TextView with a real Edit entry and a dropdown which can be used to support entry of multi-line labels Change-Id: Iad5265e404f6de14c8e760d617dbad49cd6ddead Reviewed-on: https://gerrit.libreoffice.org/82213 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-11-27don't put focus into unmapped windowsCaolán McNamara
defer until the color selectors are activated to grab focus, otherwise esc doesn't work to close a dialog under gtk3 until focus is put into some visible widget Change-Id: I297c2738c4103024bbefd70bbcb5d72b8429dd3e Reviewed-on: https://gerrit.libreoffice.org/83917 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-11-20loplugin:unusedmethodsNoel Grandin
Remove a filtering step in the python script that was hiding some results Change-Id: Id94268f150902405ab197c077f18aaedf98845fc Reviewed-on: https://gerrit.libreoffice.org/83256 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-10-31setting has-default true on an element in a GtkPopover is fatalCaolán McNamara
in gtk 3.24.12 at least. in ColorWindow explicitly track which button is the 'default' one for the two modes instead of using get/use-default and then just grab_focus instead of setting has-default for these popover cases Change-Id: Ia226f847f666d2356c6ea4e8c47f5db8e2535410 Reviewed-on: https://gerrit.libreoffice.org/81834 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-09-19tdf#42949 Fix IWYU warnings in svtools/Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ifc70900022efcd089c0874bd46e0aacaef0efb72 Reviewed-on: https://gerrit.libreoffice.org/78767 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-09-03Ensure that VCL builder entry points use proper function typeMike Kaganski
This removes duplicating typedefs from NotebookBarAddonsMerger, and removes dependency of include/vcl/builder.hxx on include/vcl/NotebookBarAddonsMerger.hxx. Change-Id: Ica5787c934d1b8ce21623f28ce155337637fdf54 Reviewed-on: https://gerrit.libreoffice.org/78549 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2019-09-03Parent reference should be const in VCL builder entry pointsMike Kaganski
Change-Id: I2331e19f5e23e0dde8edd22befc7287515adf37e Reviewed-on: https://gerrit.libreoffice.org/78536 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>