summaryrefslogtreecommitdiff
path: root/vcl
AgeCommit message (Collapse)Author
2021-05-13gtk4: add default spacing in GtkBox GtkButtonBox replacementCaolán McNamara
except for message dialog which are left at whatever default they want Change-Id: I0e5a63a909f3e4bf1800868e8c14dcc71147f5b7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115561 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-13inline some typedefsNoel Grandin
Change-Id: I1608e03ff9f6fbc55987010e88897e034b690b3a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115552 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-13make some classes privateNoel Grandin
Change-Id: I14b2c27a99e76b1141c7a7bd3d0edaf57737bee2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115544 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-13gtk4: get word count dialog visibleCaolán McNamara
Change-Id: I96d061198c54f623c366916f78655b716e1a2698 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115550 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-13gtk4: add a mechanism to support reusing the same .uis for gtk3 and gtk4Caolán McNamara
well, a base so experiment on anyway gtk4-builder-tool simplify --3to4 isn't sufficient to do what we need Change-Id: Ic5f5be90f9b9775eadecc7eaa6881c75cc2041ef Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115549 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-13gtk4: skip gtk_widget_get_root if pWidget is nullCaolán McNamara
Change-Id: I3ac47e67b1b16728a448ff8341f31c107d38556f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115548 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-13Revert "simplify the vcl<->toolkit connection"Noel Grandin
because it introduces a link-time dependency of vcl on toolkit, and toolkit already depends on vcl This reverts commit f7a86c5cdf4323c99d26512bf78de7f7c380667d. Change-Id: Ibdd4f3e8221d70e2abd8fcbda67f85af3ac0396e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115547 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-13error: use of undeclared identifier '_exit'Caolán McNamara
Change-Id: I6802c8afe4b02ec8398fa9d62728694ddc6f770f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115539 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12simplify the vcl<->toolkit connectionNoel Grandin
No need to store two different pointers and hide the underlying class behind an UNO interface Change-Id: I72c55e912caa9eae1cffa6c9d1b1d480e5668d40 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115496 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-12gtk4: add a typedef for different gtk_widget_translate_coordinates arg typeCaolán McNamara
Change-Id: I07c514309d1c687361609818d1d16e808e8b4a56 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115487 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12gtk4: add widget_get_first_child to wrap gtk_widget_get_first_childCaolán McNamara
and equivalent gtk3 calls Change-Id: Iab6801466d6677ae5a7419470ce3bb32e16e68ac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115486 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12gtk4: wrap gtk_image_get_icon_name for different version argsCaolán McNamara
Change-Id: I38f2c11309965b08a5c85f543127f3c8b6720e08 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115484 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12gtk4: enable CreateBuilder but forward to generic one stillCaolán McNamara
Change-Id: Ifba5d0de1606ed238a3e71c4149baf1c97848b1a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115483 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12gtk[3|4]: drop m_xFrameWeld before gtk_window_destroy invalidates m_pWindowCaolán McNamara
for gtk4 Change-Id: If9446411bd5dde1ad1b0d5d02bd0354b63f5c3c0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115481 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12gtk4: renable providing parent to native dialogsCaolán McNamara
Change-Id: Ic21d57d8c58db855d80cb905e45a3cd37985ca0b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115480 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12gtk4: reenable gtk message dialogsCaolán McNamara
Change-Id: I115901d5e86be7aee261df4d548b8b660e904f9c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115476 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12vcl PDF tokenizer: fix EOF position when \r is not followed by \nMiklos Vajna
Otherwise this would break partial tokenize when we only read a trailer in the middle of the file: m_aEOFs.back() is one byte larger than rStream.Tell(), so we reader past the end of the trailer, resulting in a tokenize failure. What's special about the bugdoc: - it has 2 xrefs, the first is incomplete, and refers to a second which is later in the file - the object length is as indirect object, triggering an xref lookup - the first EOF is followed by a \r, but then not with a \n This results in reading past the end of the first trailer and then triggering a lookup failure. FWIW, pdfium does the same in <https://pdfium.googlesource.com/pdfium/+/59d107323f6727bbd5f8a4d0843081790638a1dd/core/fpdfapi/parser/cpdf_syntax_parser.cpp#446>, we're on in sync with it. Change-Id: Ia556a25e333b5e4f1418d92a98d74358862120e2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115466 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-05-12fix leak in VCLXWindowNoel Grandin
which is a little tricky because dispose() can be called from either side (vcl::Window or VCLXWindow) Change-Id: Ifc380feec6bec84b2cf7d903d42db00755d4cd97 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115441 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-12tdf#141426 Fix VclBox inital size allocation.Gülşah Köse
Change-Id: If7380c9dbbcda091a2de93b722bf90182677af6c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115295 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Gülşah Köse <gulsah.kose@collabora.com>
2021-05-12gtk4: wrap gtk_widget_get_root vs gtk_widget_get_toplevelCaolán McNamara
Change-Id: I416b157defd927e7c2fa828c5d3b3ba2a5e20c5a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115448 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12gtk4: wrap gtk_css_provider_load_from_data for arg difference in gtk versionsCaolán McNamara
Change-Id: Iabbf7f6a746efae2ec4abecfb27b4b097ce822ed Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115447 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12gtk4: unset gtk_popover_set_has_arrow for popover menusCaolán McNamara
which is what I see in e.g. the gtk file dialog so lets follow that pattern. Change-Id: I505318c0e1e12ea8c75d2960184092927fd2f744 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115446 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-12gtk4: improve gtk_dialog_run replcement to not crash on ESCCaolán McNamara
e.g. open/save file dialog Change-Id: I71813125589866affc2313c72e44159c15501ec4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115445 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11ofz#32899 missing scripting_BrowseNodeFactoryImpl_get_implementationCaolán McNamara
Change-Id: Ifd7d40f67234bc852776cde8d7855f86f73a8fb2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115440 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk[3|4] don't create File Dialog with buttons that need to be removedCaolán McNamara
just create it without the offending buttons in the first place Change-Id: I0708e69a82e8fbabf149b64186a9d20cfd011cd1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115439 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: replace gtk_dialog_runCaolán McNamara
with effectively the same thing, so still a loop within a loop. File Dialog now appears and is semi-functional Change-Id: Ibd7584c5e41b5de84975c3cb7886fe97a74d8587 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115438 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: incomplete GetDisplayBuiltInScreen implementationCaolán McNamara
only x11 possible as far as I can see, maybe we can assume index 0 is built-in otherwise. We like to default to put the presentation console on the built-in laptop monitor and the presentation on the external projector. Change-Id: I5d17403032b04750a5fb4d52904db0a81a6234c5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115436 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: reduce ifdefsCaolán McNamara
Change-Id: Ibfbc5a37666c233590cf2d4169730a89d37ff7f1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115435 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: have just one way to determine if its an X11 DisplayCaolán McNamara
Change-Id: I59e2cd44252616e93c8781ffa9a916f846b24b80 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115434 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: drop unneeded ifdefCaolán McNamara
Change-Id: I85180b68ee2db3469ea93f14c73e9b325e3d948d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115433 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: flatten this methodCaolán McNamara
Change-Id: I4dfceaf70a2be541b7ed750e47e3565e3341b32e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115432 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: drop unneeded ifdefCaolán McNamara
Change-Id: I6bc4c95b1eebaec6362ce852a76ae8d947b81199 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115431 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: tidy up messy xid/native handle behind GtkSalFrame::GetNativeWindowHandleCaolán McNamara
Change-Id: Icefbfe3922b46de8da54a8117709e3a01b4b21db Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115430 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: rename ensure_dbus_setup to attach_menu_modelCaolán McNamara
Change-Id: I26b657aaad0dfbdbe6917815a8a4c5ca2d3bf4f3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115426 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: trim ensure_dbus_setup down to the minimum neededCaolán McNamara
Change-Id: Ic74ae09ca36ec110c67718fdb3de0513ef36d387 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115425 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: drop no-op filterGdkEventCaolán McNamara
Change-Id: Ia94f7f70be9b2ac21608d97095a76624cad78aac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115407 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: listen to monitors changing the new wayCaolán McNamara
Change-Id: Iab483c86a0d9810e801a19a9daf3cb9cc1632608 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115406 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: style provider is at GdkDisplay rather than GdkScreen nowCaolán McNamara
Change-Id: I9ae0d2e306c7470237ab16436dd80518c911deb7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115401 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: enable svg pointer cursorsCaolán McNamara
Change-Id: I15086c16733b862dfea7dc9be621a527000b97cf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115398 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: add basic scrolling supportCaolán McNamara
Change-Id: Ibe492ad1589d6ffeb8e8f18958e2b9cb2f0f9761 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115397 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: add basic Input Engine supportCaolán McNamara
old hack to emulate single key press events not supported (yet?) Change-Id: I0de44fab76d0fa82f7586a6712b1f4a469550c45 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115395 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: add initial keyboard event supportCaolán McNamara
basic typing works now Change-Id: Iee248855c44151a9418818081910f748ff911755 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115391 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11loplugin:noexceptmoveNoel Grandin
after commit adfd91d24678053b9a1475ad6985eb1fc548706a Date: Mon May 10 20:17:11 2021 +0200 fix leak in SalLayoutGlyphs Change-Id: I495106d9930ce6f2dad8e62fd89bc2970f747088 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115392 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-11change usage of boost::hash_combine to o3tl::hash_combineTomaž Vajngerl
Change-Id: I840518a36ac43d36c95f38e09c7bfcfe1a25a525 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114984 Tested-by: Tomaž Vajngerl <quikee@gmail.com> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2021-05-11gtk4: gtk_widget_set_focusable needed for GtkEventControllerFocusCaolán McNamara
worth mentioning in the docs Change-Id: I635bff1e7cf416796f78173ce719ce01f6cf1e5f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115386 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: current-folder-changed removed without replacementCaolán McNamara
since... commit e31bacf7be3dcc5295c89f8e929b53636976ebaa Date: Thu Jul 9 01:48:33 2020 -0400 filechooser: Drop the ::current-folder-changed signal This signal does not work on native file choosers, and it exposes internals of the widget that should not be public. And it is just not very interesting. Change-Id: I170f91b6dc87965248e206c2b1a2863448e5c976 and selection-changed removed without replacement since... commit 2746a2d929615231af10f221fc2ab416537285f3 Date: Thu Jul 9 02:06:31 2020 -0400 filechooser: Drop the ::selection-changed signal This signal does not work on native file choosers, and it exposes internals of the widget that should not be public. And it is just not very interesting. which doesn't bode too well. Change-Id: Ib8657afbbc23bf921c0bfad037d7cdb0bc490790 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115385 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: GtkCheckButton no longer inherits from GtkToggleButtonCaolán McNamara
Change-Id: I7bbf97b6a4a076d2cbc77e03bd21ecdf9b194c82 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115383 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11vcl: Popover - signal "closed" when calling popdown()Tomaž Vajngerl
Change-Id: Iabb5c7441560f1f9fa5a25cd87075f1b15e1fd51 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115379 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2021-05-11gtk4: menu item text seems to be parsed as xml now, so escape the basicsCaolán McNamara
"Zoom & Pan" in impress causing trouble Change-Id: If738eebaa3d9fd9abdd09a4fba4abce600c28743 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115363 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-11gtk4: have to explicitly ask to listen to all buttonsCaolán McNamara
right click works now Change-Id: I35326a7adab6287644ab9059fdf6ecbb66959346 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115364 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>