summaryrefslogtreecommitdiff
path: root/vcl/unx
AgeCommit message (Collapse)Author
2021-03-07move queue_resize to baseclassCaolán McNamara
Change-Id: I7f34037fc2c48168a56918c83ac7323febfe7486 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112139 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-03-05use container_focus_changed instead of toplevel_focus_changedCaolán McNamara
seeing as its the same thing, but available one level of inheritance down Change-Id: Ieedbf2bc8cea09cdafff1514eac5c35b85c2fdd0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112023 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-03-05add a callback for when a container gains or loses focusCaolán McNamara
Change-Id: Id8e8e59547280297db9140a840228f62b75593ed Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112021 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-03-03layout on resize immediatelyCaolán McNamara
but continue to layout at idle on queue_resize Change-Id: I1d0f2dd2d2f5631753092cf0450d2002e2ba3484 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111902 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-03-03vcl/floatwin.hxx can be toolkit only nowCaolán McNamara
Change-Id: Ifd8f58771ea6f9212a0dca7d4550c86ebecd9333 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111814 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-03-03loplugin:refcounting in vclNoel
Change-Id: I92e9db7abdfe5912335fd94e42422e8556d71091 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111769 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-03drop TransparentType::Color usageNoel Grandin
which is dead code, since we convert to TransparentType::Bitmask in the constructor of BitmapEx Change-Id: I047b7d25317c4be4d17a8b0db9a90ec101875c9f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111683 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-02Fix typosAndrea Gelmini
Change-Id: Ieedfe4b3d6bedfd09851836575cdc7e864a7635a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111766 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-03-01drop commented out codeCaolán McNamara
since... commit e717d1dcce7f8906311c5ccdbb2326b61a702630 Date: Tue Oct 23 12:46:28 2012 +0000 Resolves: #i121237# Rework/Cleanup of Region code... Change-Id: I6851ad46f3fc341e9f64eeeef6c3d7cebd804e06 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111719 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-28downgrade 'Restore on withdrawn window' to INFOCaolán McNamara
Change-Id: Ia9c91070a4c94e741a8bf117533e07618e5c406e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111714 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-26drop intermediate vcl container for these welded floating toplevelsCaolán McNamara
Change-Id: I4a528485de62a0e0acabd41abf6872e2f0e1710e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111567 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-26dummy clipboard for unit testsNoel Grandin
Change-Id: I285b36536dd38e41a199e8b6fd654666d125d906 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111498 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins
2021-02-25drop archaic rollable supportCaolán McNamara
Change-Id: I69f94cd8013a31f8f6bcf62d703b99f659a1ebb4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111555 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-24crashtesting: avoid assert on loading tdf98681-3.docxCaolán McNamara
as in 80e5e3826f6919e68c75d63f9dfe6417577d41ed this documents font stretch is now 135 Change-Id: I3139d36b909ef1546a1e083c8aabcc9597e314e3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111451 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-24add additional 0-1 alpha argument to DrawTransformedBitmap()Luboš Luňák
This allows the VCL backends the apply the extra alpha transformation as it sees fit, rather than it being done manually elsewhere (and even if the backend doesn't implement it, at least do it in one place in the function). With the document from tdf#136223, going from slide 2 to slide 3, this easily saves 10-30% of CPU cycles. As an additional bonus, using AlphaMask::BlendWith() rather than AlphaMask::Replace() makes edges of shapes noticeably more smooth. Change-Id: I036dc9b887d6def0c7cdad3982becabdc7cd5206 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111247 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2021-02-24simply use drawTransformedBitmap()Luboš Luňák
At least with Skia this is faster than GraphicObject trying to handle it manually, even in raster mode. Change-Id: If77d108751f5621878d4ea87a996c2ea0253d111 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111246 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2021-02-19ignore "fake" keypress in slideshowCaolán McNamara
where the fake keypress is needed to workaround https://gitlab.gnome.org/GNOME/gtk/issues/1785 which exists as a problem in gtk < 3.24 Change-Id: If8cdd536668f515327ab8fc11033e5f9c6e56a35 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111237 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-19foward declare NotebookBarAddonsItem instead of using includeCaolán McNamara
Change-Id: I57e5a8f28a40994b61ab0f554401e4f70c8ffc12 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111230 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-19detect if menubutton already has an image and reuse itCaolán McNamara
Change-Id: Id8e48491ad27cd3bfac96817ae1bb4da751c38e2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111210 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-19rename get_vscroll_width to get_scroll_thicknessCaolán McNamara
and add split customize_scrollbars to form a separate set_scroll_thickness Change-Id: Ia4b1c85d6ae85b0fb7aeb852d3a91b36b63143db Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111207 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-19loplugin:refcounting in vclNoel
Change-Id: Ieca3dd33a7ae40c3f7b8ba30f763d71a548cd144 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111171 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-02-18move async focus-in/focus-out workaround to known client that needs itCaolán McNamara
and for the normal case process immediately. Use-case is the bibliography editor, modified uncommitted entry, click in browser column margin area to select a new row, the entry should commit its old contents to the old row before filling from the new row Change-Id: Ib41d96afcfa86bcd1075b9512d4cfab593afa66d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111152 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-18loplugin:referencecasting add check for new rtl::Reference operatorNoel
rtl::Reference now has a conversion operator to uno::Reference, so look for places where we can simplify the code and use that. Change-Id: Ic81db50d670bed5e875300577d4bf5f3599cc2c4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110798 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-02-15use GetPopupParent for editeng transient dialogsCaolán McNamara
Change-Id: Ie799643b68ea41b4c4d0d0493755d09d3983d9e0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110934 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-15tdf#140414 add getting mouse pos to EditViewCallbacksCaolán McNamara
Change-Id: I09172e0cb24f5c45d2837cf2f2fc7cc4baa456a4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110932 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-12weld impress annotation windowCaolán McNamara
Change-Id: Idc89f4e382392103d373b6a84edaae10abd56056 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110650 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-12when there is label and icon align label to left and don't expand iconCaolán McNamara
Change-Id: I158b6c40ecb1b1713546cdbce7f7c001b8940b00 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110802 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-12allow using css::graphic::XGraphic to set menu imageCaolán McNamara
Change-Id: Ice5062f26ea300aec73d5fd849484c8bc4fc43bd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110793 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-11tdf#139429 Convert Style previews widget to IconViewSzymon Kłos
- this adds labels to easily identify the styles - easier to work with many styles - nice native widget in gtk3 - double click opens the style settings - added Command callback fro iconview Change-Id: I08743515cbd2a4e4bd592d1509e48bbe2a43b129 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110408 Tested-by: Jenkins Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
2021-02-11Remove unneeded breaksAndrea Gelmini
Extending this: https://gerrit.libreoffice.org/c/core/+/110512 Change-Id: I1066aac690fe297a557352266f3405ae29ed4593 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110522 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-02-10Resolves: tdf#140225 remove action when item is removed from GtkSalMenuCaolán McNamara
and we have previously ensured that all items are removed by Menu::dispose before GtkSalMenu dtor is called Change-Id: Id91cfb96a16dfa7c55bb8bc6676cb7921ec8dd37 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110704 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-10Related: tdf#140225 ignore activate/deactivate of a disposed VclMenuCaolán McNamara
prep work for improved solution for tdf#140225 Change-Id: I381d018725c8981ea09ca5d30ec6d669fba15226 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110699 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-09tdf#140225 call cancel before destroying menubarCaolán McNamara
a) in case there are some menus open cancel them before removing their parent menubar b) when a GtkSalMenu is deleted clear the action-group of the hierarchy and flag it as needed a refresh, clearing it of any references to the deleted GtkSalMenu Change-Id: I9ec59c52c72b8b58976a8ee41727ca7612ebf6b1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110542 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-06Use more conversion functions from <tools/UnitConversion.hxx>Mike Kaganski
This unifies conversion functions to provide both floating-point and integral overloads, with correct rounding for the latter. Also sanitizing code it templatized to allow reuse if needed. Change-Id: Ibe1c9fe4d5baa226c600445779dbaf7dc41a02cb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110487 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-02-06complete TODO to keep color if font changes and vice versaCaolán McNamara
Change-Id: Ic38ed14ed67e477d97523b5a670528f5aa0f93f1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110482 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-05Revert "Fix typo in code"Stephan Bergmann
This reverts commit 3ed9bba283a6a67864c0928186e277240be0d9ba. osl_Pos_Absolut (include/osl/file.h) is part of the stable URE interface; it must not be changed. Change-Id: I1f49923a9351e4be5aee39b10720d38b424feb9b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110435 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-02-04Fix typo in codeAndrea Gelmini
Change-Id: Ib8b306a27d25a34e784aeeb72708b0d5d1511f3c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110394 Tested-by: Jenkins Reviewed-by: Andrea Gelmini <andrea.gelmini@gelma.net>
2021-02-04split rect arg into dest pos and source rectCaolán McNamara
Change-Id: I622979fa54e54f1c6e00b5a16546fdbc12957422 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110383 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-02-01this needs to be 'trough' a long, narrow open container, not throughCaolán McNamara
Change-Id: I61d199887c7f0adf98219d8f27508235529ba492 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110260 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-31Fix typosAndrea Gelmini
Change-Id: Id81d2876dc6ead2de03c21e35b7940fee35bc773 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110176 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-01-30add something to override scrollbar colorsCaolán McNamara
Change-Id: Ibc2e428fcda41f4e9150f3e5029ba346c459c4b7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110159 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-29keep focus in GtkSalObject child on gtk_widget_hideCaolán McNamara
gtk will take the focus out on hiding the GtkSalObject's child widget, we want to keep it in. e.g. writer's comments in margin feature put cursor in a sidebar comment and scroll the page so the comment is invisible, we want the focus to stay in the invisible widget, so its there when we scroll back or on a keypress the widget gets the keystroke and scrolls back to make it visible again Change-Id: If200779ef1b9cdfa9c4b027c27eca0afd5013ac5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110094 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-28TopLeft().Y() -> Top() etc.Caolán McNamara
TopLeft().X() -> Left() BottomLeft().X() -> Left() TopRight().X() -> Right() BottomRight().X() -> Right() TopLeft().Y() -> Top() TopRight().Y() -> Top() BottomLeft().Y() -> Bottom() BottomRight().Y() -> Bottom() Change-Id: I5050f619bf92cfc59b6f8dfe7c9f98ef1453c294 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110022 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-27rename Toolkit::Gtk3 to Toolkit::Gtk because Gtk2 support is goneCaolán McNamara
so the need to distinguish no longer exists Change-Id: I4c11ddffbfa77f04497c454358c1c707ecf1d162 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109942 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-27tdf#139609 avoid fetching unnecessary xid under gtk3Caolán McNamara
because of the side effects using a bare GtkGrid as m_pSocket in vcl/unx/gtk3/gtk3gtkobject.cxx is perhaps a poor choice, getting its xid causes poor side effects wrt events belonging to its child widgets getting delivered to the SalFrame widget, so duplicate scrolling after showing a opengl slide and/or showing a video and lots of flickering we're (generally at least) not using the xid under gtk3 so don't set it unless it's explicitly asked for. Happily the gtk Player::createPlayerWindow doesn't use its arg[0] xid in any case, so don't bother setting it for that backend. Change-Id: I1c59a607a332635091782c3b49de10647558f301 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109941 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-27drop unused GDK_WINDOW_XWINDOW defineCaolán McNamara
and expand out gdk_window_foreign_new_for_display macro Change-Id: I4e29c16bda98f5b7eb44d91345b9f987631281cf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109944 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-26fix --enable-gtk3-kde5 buildCaolán McNamara
Change-Id: I3a49a184f06e7d78a461c3a868de8054aa7069bb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109954 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-26Resolves: tdf#106484 Print Properties Device tab dropdown change not detectedCaolán McNamara
probably since... commit 07602e5a8b869be1c45158cf71d6015d17a5f797 Date: Wed Jun 24 17:31:32 2015 +0200 tdf#91362: Don't override printer page autodetection if printer settings haven't been modified Change-Id: I6a7cb7c7ae00d7d31defe7bc1d191a6bff3ff31c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109951 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-26use an accessor for SystemEnvData::aWindowCaolán McNamara
with an eye to making it on-demand Change-Id: If6cefd68a336dc6afe23591c857bd71034215b54 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109929 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-26loplugin:passstuffbyrefNoel
Change-Id: I330e0ab6c9955939dad313f9d472f93e39dbd313 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109924 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>