Age | Commit message (Collapse) | Author |
|
If the scrollbar has a mnMin == 0 and mnMax == 0 then nVisibleSize
is set to -1?! I don't know if a negative nVisibleSize makes any
sense, so this just handles this case without crashing LO with a
SIGFPE in the Qt library. If min == max then the visible size is
just zero.
It's actually not clear, that this crash is the same then the bug
report, but it fixes at least the later reproducer crash.
Change-Id: Ib2dd51ddecfd24ddf2d89f746cbc8975269e13da
Reviewed-on: https://gerrit.libreoffice.org/82600
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
|
|
Basically reverts commit 3f0dbdd61df ("Draw button focus so that
it doesn't obscure the actual button") and declares qt5 doesn't
support an extra native focus for a button.
LO's own "ant" focus is prevented by Qt5Data::Qt5Data():
pSVData->maNWFData.mbNoFocusRects = true;
pSVData->maNWFData.mbNoFocusRectsForFlatButtons = true;
Change-Id: Ifdce615cac92f69b008780cf986cdfd0915ccd14
Reviewed-on: https://gerrit.libreoffice.org/75415
Tested-by: Jenkins
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
|
|
Just a little cleanup for all functions, which already modify the
QStyle::State of their QStyleOption* parameter.
Change-Id: Ib1fbe3ed3481a17a57ac07f390fafe8a7333f218
Reviewed-on: https://gerrit.libreoffice.org/75418
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
This is visible in Writer, where the 2nd toolbar misses the handle.
Change-Id: Iddf3a002c9d75f668c40977cf02671640b38f083
Reviewed-on: https://gerrit.libreoffice.org/75417
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
For RTL decisions we always use Qt's own setting after setting it on
startup using QGuiApplication::setLayoutDirection. The only difference
between LO and Qt events is the mirrored cursor position, which needs
explicit mirroring before reporting mouse based events (mouse and
wheel). Tooltips and frame positioning will be handled in separate
patches.
Additionally the horizontal scroll bar direction hack based on the
scroll bar button positions, needs to handle RTL explicitly.
Change-Id: I5ce5e69113a6cb6a9cf37a449265c49d92a7c159
Reviewed-on: https://gerrit.libreoffice.org/74545
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
Drawing a QTabWidget is a really complex procedure. The main
problems I had were the adjustment of the frame, which I totally
missed in the Qt code for a long time.
Then there is the frame gap, which Qt draws by simply overlapping
the items a bit with the frame. And all the calculations need the
tabs together with the pane. None of it really fits very good into
the way VCL handles drawing the TabControl and since I needed a
way back from the plugin into VCL for the nOverlap value, there is
this hack using a static. I hope nOverlap never changes.
Change-Id: I8fe6eb12d39a2ac7f6fb89424586cac76e12545b
Reviewed-on: https://gerrit.libreoffice.org/74480
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
I don't understand why WidgetDrawInterface, which is basically a
copy of the SalGraphics native controls interface, duplicated it,
instead of cleaning things up.
The whole commit message of commit 8fcfa3853a81, which added this
code, is just: "custom widgets: Custom Widget Themes". That's it.
So this patch does, what the original one skipped: replacing the
SalGraphics interface with the WidgetDrawInterface. One result is
the addition of handleDamage to SalGraphics to correctly handle
the damage done by a custom widget theme to the underlying
SalGraphics implementation.
Change-Id: I5fda1a64b28e6560fb3c62e02b6dcda827f698e2
Reviewed-on: https://gerrit.libreoffice.org/74118
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
localClipRegion was just set but never used, when KDE4 xlib
blitting was replaced by Cairo / QPainter blitting. So this
converts all the occurences to apply these clippings to the
drawing QPainter instance.
Change-Id: Ibfd60049ce604ac1415dc5c602ed5c952f972891
Reviewed-on: https://gerrit.libreoffice.org/70006
Tested-by: Jenkins
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
|
|
...after 7ffdd830d5fb52f2ca25aa80277d22ea6d89970b
"HAVE_CPP_ATTRIBUTE_FALLTHROUGH is always true now"
Change-Id: I54e5ff4e036a6bb3e5774d1c0524158aae18e937
Reviewed-on: https://gerrit.libreoffice.org/64800
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...warning about (for now only) functions and variables with external linkage
that likely don't need it.
The problems with moving entities into unnamed namespacs and breaking ADL
(as alluded to in comments in compilerplugins/clang/external.cxx) are
illustrated by the fact that while
struct S1 { int f() { return 0; } };
int f(S1 s) { return s.f(); }
namespace N {
struct S2: S1 { int f() { return 1; } };
int f(S2 s) { return s.f(); }
}
int main() { return f(N::S2()); }
returns 1, both moving just the struct S2 into an nunnamed namespace,
struct S1 { int f() { return 0; } };
int f(S1 s) { return s.f(); }
namespace N {
namespace { struct S2: S1 { int f() { return 1; } }; }
int f(S2 s) { return s.f(); }
}
int main() { return f(N::S2()); }
as well as moving just the function f overload into an unnamed namespace,
struct S1 { int f() { return 0; } };
int f(S1 s) { return s.f(); }
namespace N {
struct S2: S1 { int f() { return 1; } };
namespace { int f(S2 s) { return s.f(); } }
}
int main() { return f(N::S2()); }
would each change the program to return 0 instead.
Change-Id: I4d09f7ac5e8f9bcd6e6bde4712608444b642265c
Reviewed-on: https://gerrit.libreoffice.org/60539
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ib734b3d578f8036182a2f3e22eb1f3f8951b7fad
Reviewed-on: https://gerrit.libreoffice.org/58699
Tested-by: Jenkins
Reviewed-by: Jens Carl <j.carl43@gmx.de>
|
|
The native painting code in the kde5 backend is Qt based only.
To prevent multiple inheritance, it's moved into an extra class
and just leaves the backend specific QImage blitting in the
specific SalGraphics implementation.
Change-Id: I3d5f58f42a37966794541fe1214c1b9557376a98
Reviewed-on: https://gerrit.libreoffice.org/58652
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
Change-Id: I9539eb77f663e1174919ae801495801f81571710
|
|
Change-Id: I2d17ccdc9addb911fef8925d87b794075946c3ca
|
|
...even if that can cause reformatting of already formatted code. The problem I
came across is that without this something like
> namespace {
>
> void f1();
>
> void f2();
>
> }
(which is quite a common style in the current code base) would be changed to
> namespace
> {
>
> void f1();
>
> void f2();
> }
instead of
> namespace
> {
> void f1();
>
> void f2();
> }
and I found no other clang-format style option that would result in the
presence or absence of an empty line be identical at the start and end of the
namespace block.
vmiklos asked to reformat the existing new (i.e., non-blacklisted) files at the
same time, so this commit includes that. Some of those new files had not been
formatted at all, so this commit includes their full reformatting changes.
Change-Id: I54daf0c11098d07d02c802104cf7f56372e61f7c
Reviewed-on: https://gerrit.libreoffice.org/44450
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Move out of unx, as this will eventually compile on other
OS platforms. At least currently it doesn't contain platform
dependant code.
Change-Id: Iea0bebf574201881ea158381fe7ba8af2a9a6488
|