Age | Commit message (Collapse) | Author |
|
Unused ever since it got introduced in 62b337a3d6650b8b3045dd98f59a8c0188f0a6fa
"Unit test for removeTextContext."
(Found with an experimental Clang build supporting __attribute__((warn_unused))
on individual ctors rather than just whole class types, and the corresponding
css::uno::Reference ctor marked accordingly.)
Change-Id: Id80b031625134ea6b4d679bfb774fc253206ae18
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150374
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Specifically in sd/source/core/annotations/Annotation.cxx
We seem to end up fixing leaks here often.
The current tools::JsonWriter API is just very hard to use correctly.
So rather return an OString, which is cheap to copy,
and push that down into the LOK code.
AFAIK that seems to end up requiring less code and less adhoc copying
of data (specifically the queueing code in init.cxx was creating
copies when converting to std::string).
Ideally, we could have some special API to avoid the new strdup()
calls in init.cxx, but not sure how to prevent other people
from accidentally using that.
Change-Id: Ia33437c1bfd9cc2d54dfb99914d1b72db20335f2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149963
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Being able to trigger some more aggressive memory saving is
useful in for both online and mobile.
Change-Id: I9b91c9fe9eecec06c75112595deac0bfeb94c144
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148624
Tested-by: Jenkins
|
|
It turns out that Mert's original idea is actually the simplest and it
is known to work. And in that, the separate paintThumbnail() is rather
pointless, as all paintThumbnail() did was to call paintTile(). The
caller (in Collabora Online) knows when a file is opened specifically
for thumbnailing, and can call paintTile() itself with the appropriate
parameters.
My misguided idea would have had paintThumbnail() somehow figure out
the physical Twip coordinates of the current location (for text
documents, the insertion caret location) in the document. (Or, as
LibreOfficeKit for some reason calls them, "logical" coordinates, even
if a Twip is a very physical length unit.) Then it would have called
paintTile() with those coordinates. But it turned out to be rather
hard to figure out the Twip coordinates of the current location in
the document.
Mert's idea was that when a document is opened for thumbnailing, only
Online actually needs to know that. From LibreOfficeKit's and core's
point of view it is a normal document load operation. Then Online
performs the .uno:OpenHyperlink magic, which makes core move the
current position to the requested "target" or "mark" (the terminology
varies) location. And then a "cursor" callback is used by Online to
get the Twip coordinates of the target. It is a bit unclear to me
whether .uno:HyperLink causes the document to be opened an extra time,
but whatever, this way is said to work. So let's do it like that.
This reverts the paintThumbnail part of
1aa37ca99112c0760552600d7774ba7224581c5b.
Change-Id: I8f3d9917ee362c1518834fc10a57c57ebc4a6edb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148390
Tested-by: Tor Lillqvist <tml@collabora.com>
Reviewed-by: Tor Lillqvist <tml@collabora.com>
|
|
Original author was Mert Tümer.
Change-Id: I181a9955bcce1d5ee4c81e2a52445ef318dc4823
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147396
Tested-by: Jenkins
Reviewed-by: Tor Lillqvist <tml@collabora.com>
|
|
Change-Id: I909e6f334f4a659282141a97ccb3ffdea6ecc364
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147397
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
|
|
Change-Id: I135bdcf6b93a38d7ee746234462736b0868c9017
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147395
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
|
|
various null checks can be seen to be redundant and removed
Change-Id: Icf49c1de4b0302795d2769a370af3abceaad0221
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147147
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
This adds support for user-specific timezone.
When none is provided during loading, the
system default is used.
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
Change-Id: Ie863450687eb82bc475268a09c9112e9fd50020f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144816
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit abaf8c0af1c6c7fe01276fdf2ae62419c7b0f654)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146211
Tested-by: Jenkins
Reviewed-by: Andras Timar <andras.timar@collabora.com>
|
|
Change-Id: Ibc88d9f32ae86f7137c24e2fe1d581ff1cd64497
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145746
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
on modern hardware, these are less efficient than regular alpha
channels.
Also, this greatly simplies the range of stuff that vcl needs to deal
with, which will make the upcoming transparency->alpha patch easier to
deal with.
Enhance vcl::CreateFromData to convert incoming 1-bit data to 8-bit
image.
Change-Id: I35829da750029fe373d0d2911a669d10bab6ad23
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145321
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I6d04185f14c3ec72b40426bd881cac80528cc736
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143244
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
|
|
This is needed for Impress which can have slides in
two Edit Modes: Master Page and Page.
Change-Id: I3eca0f51ba7970e793026d1ac6aa09b19b7a904b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137869
Reviewed-by: Ashod Nakashian <ash@collabora.com>
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142969
Tested-by: Jenkins
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
|
|
It will share information about real size of a data inside
spreadsheet so we can easily check where data ends in online
side.
Change-Id: I376187a33c5c82d409f559d5cc826a4f36d4252e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139472
Reviewed-by: Gökay ŞATIR <gokaysatir@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142503
Tested-by: Jenkins
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
|
|
Change-Id: I3905fc9e6376ca1cef3e438e7a5f229d3720b1f5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138961
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142501
Tested-by: Jenkins
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
|
|
Change-Id: I1d84d8c1e371016a4f4f068af1e9c76635f28cf4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142490
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
|
|
Change-Id: Ia8874d65ea8d7eb26d10b18e37ba2bac1a7d756b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141730
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
|
|
Change-Id: I24ec4c2c1c6d83865ef78a6460cde68cef84fdb2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141638
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
|
|
which makes it easier to know what each variant requires
to stay on it's happy path
Change-Id: I3275a2543573367714bc78092e882f6535507285
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140469
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Ib35b1ce171e655e2dfbca2ed996b7e212813b8f0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140622
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
Change-Id: I5393bba647aa4667643262e77acc6b6873afb571
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139729
Reviewed-by: Ashod Nakashian <ash@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140580
Tested-by: Jenkins
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
|
|
Also change some integer by std::size_t
Change-Id: Ia51b27bb99b8adda576394f9331345cb11149d6c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137274
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
|
|
Change-Id: I33867397cd5783adb90e9dc2c62b037ced131e26
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138081
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Regression from commit 78e25558e86188314b9b72048b8ddca18697cb86
(tdf#106059 PDF export: create a reference XObject for JPG images with
PDF data, 2017-02-23), once a PDF image was inserted to a document, an
encrypted PDF export lost those images.
The reason for this is that we started to preserve PDF images as vector
data with the above commit, but this means we copied over PDF objects
from PDF images to the export result as-is, so encryption was not
performed for them.
Fix this by separating the write of the PDF object headers, stream
content and object footer and then calling
checkAndEnableStreamEncryption() / disableStreamEncryption() for each
object, even if it's not something our PDF export created but comes from
a PDF image.
Note that when existing PDF files are signed, PDF objects are also
copied into a vcl::filter::PDFDocument, but such PDF images are never
encrypted, so it's fine to have stub implementations in
vcl::filter::PDFDocument.
Change-Id: I2f74b9f51cd35b4319221532ca890e197bab9cf3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137242
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
|
|
Change-Id: I9f73b316521bcacb9042375adef3a3339ab2166f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137115
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
The getSelectionType() function usually needs to be followed by a call
to getTextSelection(), which means having them as two functions
leads to duplicating to a number of calls, some of which may be
somewhat expensive (pDoc->getSelection() e.g. for Calc builds
another ScDocument for the selection, and then getFromTransferrable()
converts that to the given format).
Change-Id: Ib0a8844701d80eaaff4834dcd3633c09d6b921b1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134603
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
|
|
- expose the available list items in a new "items" key of the
LOK_CALLBACK_CONTENT_CONTROL callback
- add a new lok::Document::sendContentControlEvent() function to be able
to select a list item from the current drop-down
- add a new listbox to the gtktiledviewer toolbar to select a content
control list item when the cursor is inside a dropdown
- add tests for the array API of tools::JsonWriter
Change-Id: I47f1333a7815d67952f7c20a9cba1b248886f6dd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134256
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
|
|
Change-Id: Idcf537a838bb0e47cfa31db8bc09e477b277ee37
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133875
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
where we can convert that to
o3tl::toInt32(o3tl::getToken(
and avoid the heap allocation of a temporary string
Change-Id: Ib11c19c6e6cdc0de3e551affd3578d181e292de4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132810
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
..
Change-Id: I774ece93e5c439c65df50e6a67d1447a062708b3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121898
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129470
Tested-by: Jenkins
Reviewed-by: Henry Castro <hcastro@collabora.com>
|
|
The unit test is selecting again range,
it will conflict with the drag & drop
because it will drop to new cell address.
The unit test will fail, the removed code
will be used to a new unit test for drag & drop.
Change-Id: I896f5cd7e6b671f3fac95c8ae76e7558fa8dd1d2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123062
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129468
Tested-by: Jenkins
Reviewed-by: Henry Castro <hcastro@collabora.com>
|
|
setFormatSpecificFilterData() sets useful defaults, but the PDF export
code has the (sane) behavior of preferring FilterData over
FilterOptions, so in case we explicitly got a JSON string in
FilterOptions to in fact set FilterData, then leave FilterData empty.
Change-Id: I20e8094bf431782fe0f5d68e3ec630e1274e30c7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128970
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
|
|
See tdf#42949 for motivation
Change-Id: I916f42c46efa1b6cfd7744a189b79659b2867431
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128196
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
No need to recompile most of LibreOffice, because the --with-fonts
configure flag changed. This preprocessor define is just used by
unit tests anyway.
Change-Id: Ia2eae7d0c74e59e034fdd8513504a34e51ab428e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128197
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
The LOK_CALLBACK_INVALIDATE_TILES documentation says that
invalidate-all message should say "EMPTY", which wasn't converted
properly from the MaxTwips rectangle representation. Doing that
now needs also changing the testTileInvalidationCompression() test,
but that should be a fix of the test, and conceptually it should
be the same.
Change-Id: I58fcc56ee56d9f6fcdb9298938e8aa7e3609d6db
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126651
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
|
|
Change-Id: Ia64ae3445a4aea3be3044e2345e432e839d9a0f7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125027
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
|
|
Change-Id: I76959f62d46e12d984fe4c7be74e5857399e9126
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124358
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
|
|
Make LOK_CALLBACK_TEXT_SELECTION, LOK_CALLBACK_TEXT_SELECTION_START,
LOK_CALLBACK_TEXT_SELECTION_END and LOK_CALLBACK_TEXT_VIEW_SELECTION
also use pull model, i.e. LO core will only set a flag and when
CallbackFlushHandler needs the actual data it'll use getLOKPayload().
This again avoids a large number of messages passed to
CallbackFlushHandler only for them to be sooner or later discarded.
Change-Id: Ia7528039be996a6e9e8491b4eba3f4133582fa56
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124146
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
|
|
Conflicts:
include/LibreOfficeKit/LibreOfficeKitEnums.h
include/sfx2/viewsh.hxx
libreofficekit/source/gtk/lokdocview.cxx
sfx2/source/view/viewsh.cxx
Change-Id: I7c621accd84f49447ab3e08a4bb662a9b91b834a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124049
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
Conflicts:
include/LibreOfficeKit/LibreOfficeKit.hxx
sfx2/source/control/unoctitm.cxx
Change-Id: I3badb038822331ab5cb30df6a66ce9a0640cf340
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124047
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
With this new API we can define which uno commands to restrict their functionality
Conflicts:
desktop/qa/desktop_lib/test_desktop_lib.cxx
include/LibreOfficeKit/LibreOfficeKit.h
include/LibreOfficeKit/LibreOfficeKit.hxx
include/sfx2/viewsh.hxx
Change-Id: I9f3fd659d373e56542c5323922a53564f1cfb27b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124046
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
CallbackFlushHandler post-processes LOK messages, but for things
like dropping useless invalidations it needs to know the rectangle
or the view id, and since the only data it gets are string messages,
it needs to convert those back to binary form. Which is slow
with large numbers of messages.
Add internal LOK callback variant that allows also passing
specific data in the original binary form. And then use directly
the binary data in CallbackFlushHandler.
Change-Id: I8dd30d2ff9c09feadebc31a44d8e6a8ccc306504
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123589
Tested-by: Jenkins
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
|
|
In the process, it turned out that there was unnecessary conversion
of OStringBuffer to OString and back to OStringBuffer when using
putRaw, which is avoided now.
Change-Id: I1e3ee685679df0b025bee8f4430624ee5bc9ccb3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123547
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
|
|
Change-Id: I01c46b864e296d4094f0a1579fdc64066eacc386
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122496
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
|
|
Conflicts:
desktop/qa/desktop_lib/test_desktop_lib.cxx
Change-Id: I4e07ffc6f8eebbbee284d19cd9c77df13dddff3a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118945
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Dennis Francis <dennis.francis@collabora.com>
(cherry picked from commit 56795f50abad3de960f23e85b2ccfa1ba0181370)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122415
Tested-by: Jenkins
|
|
Determining the position and size of the shapes (SdrObjects) was
wrong as the assumption was the values are in Hmm but were in
twips. Added some more tests that check rendering of SdrObjects.
Change-Id: I6ef9287892d1774a1243118a5c97f58384bcfd68
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121801
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
They are conflicting, so rename the one for paragraphs to
"node_type and the one for objects to "object_type". This needs
adusting all the tests. Also change the node_type from numerical
value (correcponding to a enum) to string based - "writer" or
"commom" values.
Change-Id: I0465cd4c2c6989e436d5a675db20c87066d19208
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121743
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
The change allowed to simplify many places where previously this API was
used, to avoid inefficient calculations (e.g., moving rectangle keeping
its size, and then immediately changing the size).
Change-Id: Ica2dc594d91cae83e2c2740c1f4fb23f44998916
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120461
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
|
|
also block the uno commands from deny list
Change-Id: Iee994411891b73b865e6496403682f996d5e9321
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116384
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Pranam Lashkari <lpranam@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120482
Tested-by: Jenkins
|
|
Change-Id: I2242b4bd77220b55e67c2e0f0fe54f008759d282
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120194
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|