summaryrefslogtreecommitdiff
path: root/vcl
AgeCommit message (Collapse)AuthorFilesLines
2018-11-07sc lok: Implement hi-dpi and zoom for spreadsheets.Jan Holesovsky1-3/+12
A bit different approach than trying to paint different zoom levels at the samet time, because it is terribly hard to achieve with Calc - things misalign, because Calc tries to fit the lines into the pixels etc. Instead, always paint the spreadsheet at 100%, but use cairo to scale the actual painting. Change-Id: I228a9dd41bf29862bdd188825d12e61e1c86cccc
2018-11-06update main thread "properly" in headless caseAndras Timar1-0/+3
Change-Id: Ie76555a007db13e89f06c85d02beebf84eadea0b Reviewed-on: https://gerrit.libreoffice.org/62912 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2018-11-06Add function to map custom widget name to its function to native-code.pyTor Lillqvist1-4/+8
Use that function in the dialog builder instead of looking up the function dynamically, which won't work in a Release build as the linker will filter out functions that aren't explicitly referenced. For now this simply uses a manually curated list of custom widgets. I used some command line tools to extract the names of custom widgets used in our .ui files, and then filtered out some I guess (hope) will not be needed in a mobile app. For this to work the custom widgets need to have unique names. Currently that is not the case. Unless I did some mistake, there is just one case of duplicate name, NotebookbarTabControl, which exists both in the sfx and vcl libraries. (I simply filtered out that one, too, for now.) Change-Id: I29bbf6dfef2b3bde03acfc322495d051a7f275a8 Reviewed-on: https://gerrit.libreoffice.org/62946 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2018-11-05Add assertion for the non-DESKTOP case if the function is not foundTor Lillqvist1-0/+6
Change-Id: I8ac042ca99037f99e36449bcc9799beb2b2fd5d5 Reviewed-on: https://gerrit.libreoffice.org/62919 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2018-11-05We do need Dialog::Execute() for iOSTor Lillqvist1-1/+4
Otherwise the Data>Sort dialog in a spreadsheet document, for instance, will not show up. No idea about Android, so keep it dummied out for that. Change-Id: If9a8f8f4cfb813721a9edd6a0a3da398615981b2 (cherry picked from commit 2a8a93b521c313aba09c034899a70849d8b17710) Reviewed-on: https://gerrit.libreoffice.org/62918 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2018-11-05Start of work in progress on making dialogs work in the iOS appTor Lillqvist1-4/+0
Build the swui library for non-DESKTOP platforms, too. Handle fallout for !HAVE_FEATURE_DBCONNECTIVITY and !HAVE_FEATURE_AVMEDIA (both of which features we for now don't want to bother with in the iOS app). Make VclAbstractDialogFactory::Create() do its thing also on non-DESKTOP. This commit just causes more code to be compiled for the non-DESKTOP case, dialogs in general surely don't actually work yet in the iOS app. For instance: vcl/source/window/builder.cxx:2060: probably need to implement sfxlo-CustomPropertiesControl or add a makesfxlo-CustomPropertiesControl function Change-Id: I579efba605f519dcbf407b675be88c7c6ee0f19b Reviewed-on: https://gerrit.libreoffice.org/62865 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2018-11-02tdf#120807 check for valid ImplGetWindowImpl()Jan-Marek Glogowski1-1/+1
Change-Id: Ia1135d11990abc303849bd1b6a549c82008c79de Reviewed-on: https://gerrit.libreoffice.org/62260 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> (cherry picked from commit db0051744330d82986e8f2629a027bc4a5dc1b4a) Reviewed-on: https://gerrit.libreoffice.org/62280 Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> (cherry picked from commit 6720da69043a5ca206e9feac8396335e7b0af793)
2018-10-30iOS, correct DPIX calculationjan Iversen1-1/+1
Patch is thanks to Jon N. Change-Id: Idba9ec9b32b144523f0e7da5f7273f6af9fdfd31 (cherry picked from commit 1dd5f10c3c6e0189ada4ecd6d08beb4c5fd1d42d) Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30We shouldn't call DrawTextLayout() without a context on iOSTor Lillqvist1-0/+8
Change-Id: I3e72909ca1aa9f97721d982f16624f496152ae2d Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30iOS, removed read to pipesjan Iversen1-1/+6
needed to run iOS Change-Id: I1176ce24023cde21846c71ffadb1bf01cb2c8399 (cherry picked from commit 9c8cc8e46c917042ca85d392f175b320205c0f7e) Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30We do want to initialise m_MainThread on iOS, tooTor Lillqvist1-1/+1
(Original commit message below, but note that the talk about LibreOfficeLight is irrelevant here in this branch.) This doesn't make the LibreOfficeLight app work much better, though. But at least it doesn't hang its event loop completely, some 10 s timer keeps firing. (But nothing sane shows up in the app UI, even if some welcome.odt document apparently does get loaded. Clearly something is waiting for something else that never happens...) (cherry picked from commit 31703196388b455edda1c40fd2b3b536b315848f) Change-Id: Ieba22a5e1418d48a7dd6cacda526aca69cced4c3 Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30LibreOfficeKit wants the tile pixmap bytes to be in BGRA order in memoryTor Lillqvist1-1/+1
To get that with CoreGraphics on iOS we need to use also kCGImageByteOrder32Little in the CGBitmapContextCreate() call, otherwise the bytes will be in ARGB order in memory. (Not touching the macOS code here.) Change-Id: I3c2dd94feb1c6bf46c5b335f5901b29e5fe1e7fb Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30Bin some no longer needed dbgutil codeTor Lillqvist1-6/+0
It was used to initialize a virtual device pixel buffer to an "interesting" pattern, in case actual rendering to it failed. Change-Id: Iacdd86382dfa8c9ed1ea9d213fa489515b2b217d Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30Bin horribly verbose image saving on iOS for debug purposesTor Lillqvist1-42/+0
Not really that useful any longer. Change-Id: Idf29b9c3eeafd1b1cc7a2baa87205f7064681a23 (cherry picked from commit 1ab835e0fae20118971a349811ae28712c41fbc0) Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30Bin some ancient debug tracing stuff from TiledLibreOffice daysTor Lillqvist1-157/+0
Change-Id: I3928c6e9240ad28a65aeb4fecb07268f789faf67 Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30Re-think cppu::throwException() and the C++/UNO bridge on iOSTor Lillqvist1-0/+83
It seems that on iOS, where we don't have any Java, Python, BASIC, or other scripting, the only thing that would use the C++/UNO bridge functionality that invokes codeSnippet() was cppu::throwException(). codeSnippet() is part of what corresponds to the code that uses run-time-generated machine code on other platforms. We can't generate code at run-time on iOS, that has been known forever. Instead we have used some manually written assembler to handle it instead. We used to have a Perl script to generate a set of code snippets for different cases, different numbers of parameters of the called function and whatnot, but that went away at some stage some year ago. (It is unclear whether that broke the C++/UNO bridge on iOS, or whether the stuff continued to work even after that.) Anyway, this handwritten assembly, or the manual construction of internal data structures for exceptions, or something else, seemed to have bit-rotten. Exceptions thrown with cppu::throwException() were not catchable properly any longer. Instead of digging in and trying to understand what is wrong, I chose another solution. It turns out that the number of types of exception objects thrown by cppu::throwException() is fairly small. During startup of the LibreOffice code, and loading of an .odt document, only one kind of exception is thrown this way... (The lovely css::ucb:InteractiveAugmentedIOException.) So we can simply have code that checks what the type of object being thrown is, and explicitgly throws such an object then with a normal C++ throw statement. Seems to work. Sadly the cppu::getCaughtException() API still needs some inline assembly in the C++/UNO brige. That seems to work though, knock on wood. This commit also adds a small "unit test" for iOS, copied from cppuhelperm to ImplSVMain(). Ideally we should not copy code around of course, but have a separate unit test app for iOS that would somehow include relevant unit tests from source files all over the place. Later. Change-Id: Ib6d9d5b6fb8cc684ec15c97a312ca2f720e87069 Reviewed-on: https://gerrit.libreoffice.org/60506 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com> (cherry picked from commit 7d6be61a62ca3724c67ab3fb93e60a2748d8a67e) Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30vcl, solve iOS compile failure.jan Iversen1-1/+3
"voided" new formal parameter Change-Id: I7d8849765eb6a2642f48159bae34c3b8bec3a8cd (cherry picked from commit 7c30bf05ec891b0d8cba117838ff20e9d0b6d63e) Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-10-30Fix build in the !HAVE_FEATURE_PDFIUM caseTor Lillqvist1-1/+1
Change-Id: Ia9263e67c3a4094a58141a8140de66a22accb768 Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2018-09-21tdf#119881: Check if Unity/Gnome is separated by colon in XDG_CURRENT_DESKTOPXisco Fauli1-5/+16
Change-Id: Ie29c2213d8efccd7750396325ce05b4909c09d02 Reviewed-on: https://gerrit.libreoffice.org/60592 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com> (cherry picked from commit 79093cce6c3a65f84bbafd172b1e9e6702d3ce75) Reviewed-on: https://gerrit.libreoffice.org/60678 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com> Tested-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com> (cherry picked from commit 0ed572e46a14078c3e96eae063226fcb8823f758)
2018-08-20tdf#118994 JAWS has no access to accessibility objectsIlhan Yesil1-3/+6
According to the MSDN, lParam must be cast to DWORD when examining WM_GETOBJECT messages on 64-bit Windows. The MSDN example also casts wParam, so in this solution, lParam and wParam are cast to the appropriate types sal_Int32 and sal_uInt32. Change-Id: I1edc00778c7da91d2baf5784e4c3f8c441e42eab Reviewed-on: https://gerrit.libreoffice.org/58312 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com> (cherry picked from commit 200fafc341c9ac5cedb0e3e8a38fcc4e88fce77c) Reviewed-on: https://gerrit.libreoffice.org/59342
2018-08-10forcepoint#66 make sure we don't get stuck endlessly reparsingCaolán McNamara1-3/+8
Change-Id: Ie2733e8d7f73e5f6a072604c477e949cd944189a Reviewed-on: https://gerrit.libreoffice.org/58466 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> (cherry picked from commit cc8140fe71becc92976167e2a96dbe1d727097dc)
2018-08-10forcepoint#66 protect against infinite parse recurseCaolán McNamara1-9/+12
Change-Id: I0313cc141469a00b7d6a5bd15400e9d5a8f686cf Reviewed-on: https://gerrit.libreoffice.org/58452 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> (cherry picked from commit 171657a1f675268839526b1a13e5f3549fb73516)
2018-08-10forcepoint#65 pdf page visiting revisits itselfCaolán McNamara1-4/+16
Change-Id: I6d9eb75f0850a94814fb4d69ea1442b826674496 Reviewed-on: https://gerrit.libreoffice.org/58418 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> (cherry picked from commit e6d5ef741c75895ed97801112823b8332557d79a)
2018-08-10tdf#118860 svx opengl: avoid SalBitmap creation without solar mutexMiklos Vajna1-0/+6
The bugdoc has 2 slides. When switching to the second slide, the graphic is loaded in the background, but OpenGLSalBitmap::Create() can't work correctly if the caller doesn't own the solar mutex. This already asserts in OpenGLContext::prepareForYield() in a less obvious way. Focus on the correctness, so just hold the solar mutex during the whole ImportGrpahic() call. If it turns out that the purpose of running this on a thread is to avoid synchronous network traffic, then the data could be first copied to a memory stream, and only then take the lock + import the graphic. (cherry picked from commit 919ccaba419531d689231b76a43ab29c6a9ec65a) Change-Id: I88203c12b4e7a5f2b689928c01e2ba953c5b13c5 Reviewed-on: https://gerrit.libreoffice.org/58126 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit 2038ab9d4cbb7282172a65352e4ed1a852404b29)
2018-08-10forcepoint#53 restrict to expected index rangeCaolán McNamara1-2/+7
Change-Id: I22f01e5a3e3cf51b014ac841cd14071dce5baf0f Reviewed-on: https://gerrit.libreoffice.org/57922 Tested-by: Jenkins Reviewed-by: Eike Rathke <erack@redhat.com> (cherry picked from commit fa82b6a5c74b527dc2aed9d3b63c997580cdb277)
2018-08-10Resolves: tdf#118302 drag n drop to same tab should cancel dndCaolán McNamara1-1/+17
dropComplete is used to do this, follow the mac pattern here to propogate this in the drag and drop from self to self case. Maybe this also affects tdf#105320 ? Change-Id: I2b8f8b0e0486f6ee45a65918fae2537750a75f2d Reviewed-on: https://gerrit.libreoffice.org/57591 Tested-by: Jenkins Reviewed-by: Xisco Faulí <xiscofauli@libreoffice.org> (cherry picked from commit e6e9bae8f3eefa1e4529886ea995cc4cf8e3d817)
2018-07-18lokdialog: Convert InfoReadonlyDialog -> execute asyncPranav Kant1-1/+12
Change-Id: I3f2e7fb676911570276f66d000c91ca3ef2bdeb0 Reviewed-on: https://gerrit.libreoffice.org/50096 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com> (cherry picked from commit c565a1a36dc6e75744df284edbb36ffd09edc42b) Reviewed-on: https://gerrit.libreoffice.org/57651
2018-07-18lokdialog: no invalidation when in init showPranav Kant1-1/+1
This improves LOK dialog opening time considerably. libreofficekit/tilebench results: Before: profile run: initialization - 346.5185(ms) load document - 2162.5881(ms) open dialog - 7077.8980(ms) wait for dialog - 52.7742(ms) render dialog - 256.9597(ms) post close dialog - 523.7811(ms) destroy document - 58.3723(ms) Total: 10.4789(s) After: profile run: initialization - 336.5867(ms) load document - 2155.5481(ms) open dialog - 1151.4130(ms) wait for dialog - 51.5332(ms) render dialog - 260.3197(ms) post close dialog - 519.8729(ms) destroy document - 56.7322(ms) Total: 4.5320(s) Change-Id: I6345aca33c5881aba33c8a5f74765b99fe098711 (cherry picked from commit f57856e9da44a13649b409aaadb9019b916fbb88) Reviewed-on: https://gerrit.libreoffice.org/57576 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2018-07-09tdf#117335 Fix displaying GIF imagesBartosz Kosiorek1-6/+6
To fix regression the sal_uInt16 was used instead of sal_uInt8. Verified on macOS High Sierra 10.13.5. I also checked if with this fix, there is no issue with displaying EMF (tdf#113197) Sample document from tdf#113197 is displaying correctly. Change-Id: I6504717d831a193b0a878ced2f335d34a993aed6 Reviewed-on: https://gerrit.libreoffice.org/56578 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@cib.de> Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl> (cherry picked from commit 054a3586bb4808728a5cd58ea8a867539c08e55c) Reviewed-on: https://gerrit.libreoffice.org/56668 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> (cherry picked from commit 34bba6eaa404f5a081dcc28f9cca7fd55a10fe0c)
2018-07-06Resolves: tdf#115816 second 'Insert' menu is pasteCaolán McNamara1-0/+1
reuse existing translation to be backportable wrt no new translations Change-Id: I1fb94f66d696f836e8f6a10ba2d6933f69cfac95 Reviewed-on: https://gerrit.libreoffice.org/56245 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> (cherry picked from commit 74b897f9c578cb0b64124ef9563f2355680c8d84)
2018-07-06tdf#117981 translate embedded video window mouse events to parent coordinatesCaolán McNamara1-6/+38
Change-Id: I0d8fb6c6adc44389332434f9f6a8396a4d1817cf Reviewed-on: https://gerrit.libreoffice.org/55339 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> (cherry picked from commit 89c8673755646e631469f8031a9785cdcc99ff75)
2018-07-06forcepoint#50 fix end detectionCaolán McNamara2-7/+8
rBuffer.size() of 26, nBytes of 25, rBuffer[25] is the first zero so aLine.getLength() of 25, nBytes reduced by aLine.getLength()+1 and nRun increased by same, so nBytes wraps and nRun is 26. contains... forcepoint: rework to explore loop Change-Id: I14f6a3269fc3347a9976d899519e74f58d5975c8 Reviewed-on: https://gerrit.libreoffice.org/56125 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit 6e5e83025c948b699bb65839ef810a45a98ba014) Change-Id: Ia9f4789e081e6b77a21321f37d71cabfc7c84550 Reviewed-on: https://gerrit.libreoffice.org/56481 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> (cherry picked from commit 0cefb4f0552a9d1ec3afd64e695596480a1c9757)
2018-07-02vcl: explicitly qualify ICU types with icu:: namespaceEike Rathke1-1/+1
It will be required by ICU 61 anyway, see https://ssl.icu-project.org/repos/icu/trunk/icu4c/readme.html#RecBuild Change-Id: Iecb30b903e9a67252147a8cc78c641621d763755 (cherry picked from commit f240332f8e965ea17b70b0ccaa9990ce0a53cfc6) Reviewed-on: https://gerrit.libreoffice.org/56735 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> (cherry picked from commit 4d06789a836f1a271399cd9955b2cb96030f393a)
2018-07-02tdf#116208 vcl opengl: fix lack of updates in status barMiklos Vajna1-0/+3
Commit f0821f9a347c7752a3c741c3451a2f1630173720 (Cache text layout of statusbar items, 2017-06-08) was a performance improvement of not laying out the text of status bar text during each & every paint. One of these places didn't work correctly with Chinese text, so commit a4ed3d9a1ffa1b51ba4352a955c950235f099fdc (tdf#115353 Status bar: no cache in settext, 2018-03-01) attempted to disable the caching at that particular place by removing the update of the cache. This resulted in lack of updates, e.g. during typing into Writer and checking the word count part of the status bar. Fix this (and at the same time keep the original problem fixed) by still not using the layout cache and that problematic place, but instead of just not updating the cache actually invalidate it -- probably that was the intention in the force place already. (cherry picked from commit 0ad7226aee21cc6dbb30d061d76491b01e39de66) Change-Id: Ib7b91e5f24bc68d2f8cae2efea64340585ad9bd5 Reviewed-on: https://gerrit.libreoffice.org/56437 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com> (cherry picked from commit bcfa971adb62bfdde14e8c328fb25e1d10acad9b)
2018-06-30lok: Always specify the invalidate rectangle explicitelyTamás Zolnai2-1/+9
It will be needed for a later change in online code. Change-Id: Ic8f898b78ccaaaec849a1894b5e70fb730d70d6d Reviewed-on: https://gerrit.libreoffice.org/54443 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit cee3840c01292dc3ef98d996d00f57f43eb35e9e) Reviewed-on: https://gerrit.libreoffice.org/54535 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2018-06-28lok: Use GetSizePixel() here which calculates also with borderTamás Zolnai1-1/+1
Fixes the bug that one pixel is not invalidated of a preview window on the dialogs. For example: Character properties dialog -> Highlighting preview or Character properties dialog -> Font preview Reviewed-on: https://gerrit.libreoffice.org/54494 Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit 7a77d927c88a04ee51ceb765c77e725a67a1d1a7) Change-Id: I6f96abdd4d85c8dfed8bf83e1b2a30192a54bd2d Reviewed-on: https://gerrit.libreoffice.org/54536 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2018-06-27tdf#103913 keep ".emf" file extension and mime typeLászló Németh1-0/+16
in documents, don't change them to wmf and image/x-wmf silently, resulting for example, dropping or rejecting modified documents by firewall packet filtering. Reviewed-on: https://gerrit.libreoffice.org/56045 Reviewed-by: László Németh <nemeth@numbertext.org> Tested-by: László Németh <nemeth@numbertext.org> Conflicts: svx/source/xml/xmlgrhlp.cxx (cherry-pick from commit 4cb1e86e5217f09e1d98e51e46803a06fb72f5ce) Change-Id: I3b8634ae022c7c026b0ed4ebc345c1c3b3f96337 Reviewed-on: https://gerrit.libreoffice.org/56084 Reviewed-by: László Németh <nemeth@numbertext.org> Tested-by: László Németh <nemeth@numbertext.org> Tested-by: Jenkins Reviewed-by: Gabor Kelemen <kelemeng@ubuntu.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit c959815d55919967c9697dc8862ddec6844b7796)
2018-06-27tdf#114736 no need to call AdjustLayout hereTamas Bunth1-5/+0
Reviewed-on: https://gerrit.libreoffice.org/48761 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Bunth <btomi96@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/49033 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> (cherry picked from commit 221234c0203d5b3caf6907bff110fc1a9b71a5ad) Change-Id: Iae8c953155d46e53cffdf3483e3b4b95157719f6
2018-06-27vcl: refresh font cache only on real changeAshod Nakashian4-7/+8
GTK3 emits way too many style-updated, which triggers font cache updates. The avoidance of unecessary font cache updates was first implemented in 29c55564. Unfortuantely, it seems that the current font-options was never set as last-seen font-options, so still to many fonts-changed were emitted Change-Id: I01a47d4d7fb033e335b1a49ffa6e1bb98f7fd28d Reviewed-on: https://gerrit.libreoffice.org/55423 Tested-by: Jenkins Reviewed-by: Eike Rathke <erack@redhat.com> (cherry picked from commit 5cdda2c5d62829e8bf5ebb6aa58f482182038342)
2018-06-27tdf#102928 PDF export: do recompress CMYK imagesMiklos Vajna3-6/+36
The export filter writes /DeviceRGB unconditionally, so for now don't optimize CMYK image handling here. Though the added GraphicDescriptor API allows supporting this natively in the export filter in the future. (cherry picked from commit 70537c8295f1b0a0c58b061dfca6cbc9def0d65b) Change-Id: I76b44b910948467aeb1f15e5ae765201d183c99d Reviewed-on: https://gerrit.libreoffice.org/55378 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit 4aaf958cdad2a19be49dbd5f9ca661753f8a94ab)
2018-06-27Fix build with GLM 0.9.9.0, tdf#118070Louis Sautier1-0/+6
One of the test files was forgotten in 953c4add8fd76d88f49a81ae4c21a1fdcc007e57 Change-Id: I0315433c688ff7edb2ba599bbef203cac9de3022 Reviewed-on: https://gerrit.libreoffice.org/55554 Reviewed-by: Rene Engelhard <rene@debian.org> Tested-by: Rene Engelhard <rene@debian.org> (cherry picked from commit 5f1bf6598b5725ad1e50ae9f7ec7524cc8a834fa) Reviewed-on: https://gerrit.libreoffice.org/55556 (cherry picked from commit 4731827db269a11b8f12e22076a2f3c297298450) Reviewed-on: https://gerrit.libreoffice.org/55557 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit 3a2505715f91cc871004aad064f11516d0027ed6)
2018-06-11tdf#117872: Never participate in the macOS system full-screen modeTor Lillqvist1-15/+21
There is just too much complexity involved, and the way LibreOffice works really isn't prepared for the concept of windows having the option from a system point of view to being full-screenable or not. This means that the green bubble in window title bars changes from being a (system) full-screen toggle to being a maximize/restore toggle. Sure, the "maximize" concept also probably can be confused with LibreOffice's own full-screen concept. For instance, the Start Centre window is not expecting to be made full-screen. Still, when you from the Start Centre open a Writer document, it is the *same* window that is re-used as the Writer window, and then suddenly should be prepared to handle going full-screen. Also, it is up to each separate kind of document window whether it can be made full-screen (from the LibreOffice point of view) or not. Writer windows can, but Impress windows can't, for example. The View>Full Screen menu entry is added separately each case. Change-Id: I6983481cbd30c0e5190c450483b1246006c80633 Reviewed-on: https://gerrit.libreoffice.org/55617 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2018-06-11Resolves: tdf#101798 ResetClipRegion needs to affect cairo drawing tooCaolán McNamara1-0/+3
regression since... commit cb382034b061b4acd4f0fd490f42af34517a7b8d Date: Fri Jul 1 14:00:00 2016 +0200 tdf#50613 speedup fat line drawing on linux using cairo Change-Id: I2f1a70f102786228d52199df9960336218c6f9f9 Reviewed-on: https://gerrit.libreoffice.org/55182 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> (cherry picked from commit 77230756187d8642f08e6b4bb937d279f3483533)
2018-06-01tdf#117850: Just call _Exit() in our applicationWillTerminate:Tor Lillqvist1-0/+3
Sure, it is just a workaround, but a very effective workaround. Change-Id: Id0daff048a27dae5cf8fb5e0e949c5b21e03fc86 Reviewed-on: https://gerrit.libreoffice.org/54924 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tor Lillqvist <tml@collabora.com> (cherry picked from commit aa81a086bd3dcd7d6b830951619f310bd0aff30c) Reviewed-on: https://gerrit.libreoffice.org/54995 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> (cherry picked from commit b1eeeaccc3337510df93b147f5905fca3416fc48)
2018-06-01tdf#113143 PDF export: fix mis-scaled JPGs on Impress note pagesMiklos Vajna3-65/+114
This is really similar to commit 4c2172a3e973bc6351107a3a1b554c77b40b75dd (tdf#106702 PDF export: fix missing images from Writer headers/footers, 2018-05-22) just this one is about the size of the output rectangle for JPG content, while the previous problem was about the position of them. Also extract PdfExportTest::exportAndParse() from the last two tests to avoid duplication. (cherry picked from commit 89dc667cebfec5315f0c0361e49d759e88458689) Change-Id: I9812924d505e9fdaca2a95b4990e7aaa5e44fd7f Reviewed-on: https://gerrit.libreoffice.org/54989 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> (cherry picked from commit 257014ce03dee29506e8e70c204e912c4ed33172)
2018-06-01tdf#117628 crash after closing media player with X11 backendCaolán McNamara2-7/+6
Change-Id: I812da5ddf7343573f93ea64e592442edb31cad2d Reviewed-on: https://gerrit.libreoffice.org/54912 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> (cherry picked from commit d9c5e7f4aef8da58b2b59e3259d1704296648cbf)
2018-06-01tdf#106702 PDF export: fix missing images from Writer headers/footersMiklos Vajna5-23/+95
Position of an image is determined by the relevant bitmap scale metafile action when recompressing images. The same position was determined by PDFExtOutDevData "meta" info when not recompressing images. This second rectangle was never correct for images repeated in Writer headers/footers on non-first pages: the position was relative to the page, while PDF export sets the map mode (origin) of the output device during export, so such positions are expected to be absolute ones. The root of the problem seems to be that header images in Writer are both repeated (as the user sees it) and unrepeated (as the doc model sees it), and by the time we want to get its position, we only see the unrepeated SdrObject. Fix the problem by using the correct position from the scale action and not from PDFExtOutDevData if possible. (Also give up on running CppunitTest_vcl_pdfexport in the non-pdfium case, most of the tests there do require pdfium anyway, and the growing ifdef forest in that file just made it hard to read the code.) (cherry picked from commit 4c2172a3e973bc6351107a3a1b554c77b40b75dd) Conflicts: vcl/Module_vcl.mk vcl/qa/cppunit/pdfexport/pdfexport.cxx Change-Id: I31c14d4bd223b2804859982542ebd6d5f9abd312 Reviewed-on: https://gerrit.libreoffice.org/54690 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit 327c7ee43fbe53df63693d020356ddf4df56d7f1)
2018-06-01vcl: fix pdf rendering regressionAshod Nakashian1-1/+3
Change-Id: I6c2c48c033facb317b4ca7ed2af07348d6386b98 Reviewed-on: https://gerrit.libreoffice.org/54921 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2018-06-01pdf: preserve the original page dimensions on importAshod Nakashian1-11/+15
Also allow for rendering PDFs to images at custom resolution, instead of hard-coded (old hard-coded value of 96 dpi is now default arguments). Change-Id: Ia5b52f72d6ce7130a2debc7c6f86504aa041bdc8 Reviewed-on: https://gerrit.libreoffice.org/54786 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2018-06-01sd: render the correct PDF page on swapping inAshod Nakashian1-2/+4
Change-Id: I81225e228d9cf2b9849110715dbfdeb59f2805dd Reviewed-on: https://gerrit.libreoffice.org/54746 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>