summaryrefslogtreecommitdiff
path: root/vcl
AgeCommit message (Collapse)Author
2018-04-23loplugin:useuniqueptr in MenuButtonNoel Grandin
Change-Id: I4e7a2ca5f8bb645e99414b1c99dc6261310c89bb Reviewed-on: https://gerrit.libreoffice.org/53237 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23loplugin:useuniqueptr in MoreButtonNoel Grandin
and remove unused mpItemList field in ImplMoreButtonData Change-Id: I1eee6958d0f064cec22028399de5fb28e8647617 Reviewed-on: https://gerrit.libreoffice.org/53236 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23loplugin:useuniqueptr in SplitWindowNoel Grandin
Change-Id: I04b45f02ce0dc98d11fb78982b8364fdd8333f9c Reviewed-on: https://gerrit.libreoffice.org/53233 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23loplugin:useuniqueptr in MenuNoel Grandin
Change-Id: I4de2081597ffc55a95fe5b482c37461811f323e6 Reviewed-on: https://gerrit.libreoffice.org/53232 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23loplugin:useuniqueptr in FloatingWindowNoel Grandin
Change-Id: I960417daea8a4f3d612278de7a78a8f80630a288 Reviewed-on: https://gerrit.libreoffice.org/53231 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23loplugin:useuniqueptr in ControlNoel Grandin
Change-Id: If445e1a8ae3a7e3988658c011f678ce1e603f4a9 Reviewed-on: https://gerrit.libreoffice.org/53230 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23loplugin:useuniqueptr in StatusBarNoel Grandin
and rename mpItemList->mvItemList Change-Id: Ib11dce91543fc4a6623795f3ff2820db5a3d7120 Reviewed-on: https://gerrit.libreoffice.org/53229 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23loplugin:useuniqueptr in ImplWheelWindowNoel Grandin
Change-Id: I064ebced6e7840c4f9a179c312743385892e552a Reviewed-on: https://gerrit.libreoffice.org/53228 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23loplugin:useuniqueptr in PopupMenuFloatingWindowNoel Grandin
Change-Id: If903f677db198978dcf455f06198437a26b6a311 Reviewed-on: https://gerrit.libreoffice.org/53227 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23loplugin:useuniqueptr in DockingWindowNoel Grandin
Change-Id: I7a0fec27f50c58f02378a69db5d17c6f5eb62ee2 Reviewed-on: https://gerrit.libreoffice.org/53222 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-23vcl: ImplDuoTone() -> BitmapDuoToneFilterChris Sherlock
Change-Id: If779cf4033948601997a932839eaa10a874de1b3 Reviewed-on: https://gerrit.libreoffice.org/53205 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22Fix typoAndrea Gelmini
Change-Id: I80ee9824473facdcb1c96f332773fcd79b266efe Reviewed-on: https://gerrit.libreoffice.org/53246 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-04-22place an intermediate class as parent for SfxTabPagesCaolán McNamara
so a SfxTabPage can be parented by a vcl::Window or a welded native notebook tabpage. That ways the same SfxTabPage can be used at the same time in both a native dialog or a vcl dialog. The impl can be changed to the weld api, and when hosted in a native dialog the vcl impl of that will be instantiated, while native otherwise. e.g. print options appearing in print options dialog and general options. This allows incremental changeover. Change-Id: I6f1fed1e8d0898b01853bb878757bad41cbf9bba Reviewed-on: https://gerrit.libreoffice.org/53193 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-04-22vcl: ImplEmbossGrey() -> BitmapEmbossGreyFilterChris Sherlock
Change-Id: I6e541e9ca9cf61dfa8df9638a4ba4b8bd1d3ad71 Reviewed-on: https://gerrit.libreoffice.org/53204 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22Rename GlyphItem::IsClusterStart() → IsInCluster()Khaled Hosny
The flag is called IS_IN_CLUSTER and the only place that uses it checks for !IsClusterStart(), so invert the condition and rename it accordingly. Change-Id: I0feaf27ee671883f111340bcd9ffcb4e3782005f Reviewed-on: https://gerrit.libreoffice.org/53276 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
2018-04-22sal_GlyphId can be 16 bit nowKhaled Hosny
OpenType glyph ids are 16 bit unsigned integers, but we were using 32 bit integer and abusing the higher bits to set glyph flags. All such abuses are now gone and we can make it a simple 16 bit integer. Change-Id: I594068675f239fd525376fd9ea752462ec3edd9d Reviewed-on: https://gerrit.libreoffice.org/53270 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
2018-04-22Glyph flags is now an int not longKhaled Hosny
Change-Id: Ica262bf1f1d36ae731647ee0a0345901aa7265ec Reviewed-on: https://gerrit.libreoffice.org/53267 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
2018-04-22Don’t abuse glyph id for flagging dropped glyphsKhaled Hosny
Use a bitflag instead. Change-Id: I7833a37578112b5326f4a30578596e53085ff3c0 Reviewed-on: https://gerrit.libreoffice.org/53269 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
2018-04-22vcl: ImplMosaic() -> BitmapMosaicFilterChris Sherlock
Change-Id: Ia0910ae9166c4eb6b870ab25db761bc1703fec68 Reviewed-on: https://gerrit.libreoffice.org/53203 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22vcl: ImplSepia -> BitmapSepiaFilterChris Sherlock
Change-Id: I96a4072bf919bd37b30c01ab16d98779c76717ab Reviewed-on: https://gerrit.libreoffice.org/53202 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22vcl: ImplSolarize() to BitmapSolarizeFilterChris Sherlock
Change-Id: I3d615bcce851cb0f0140e2a1542a4073727a51be Reviewed-on: https://gerrit.libreoffice.org/53201 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22vcl: ImplPopArt() -> BitmapPopArtFilterChris Sherlock
Change-Id: I7b81d0441b5ffdc322a19ca1fea7c7ca63e9e499 Reviewed-on: https://gerrit.libreoffice.org/53151 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22vcl: ImplSobelGrey() -> BitmapSobelGreyFilterChris Sherlock
Change-Id: I2082d7e3b90172b4517ad0f4be75f85006eb5891 Reviewed-on: https://gerrit.libreoffice.org/53150 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22vcl: ImplMedianFilter() -> BitmapMedianFilterChris Sherlock
Change-Id: I72a0546c11d6ef8a8a4eb467d566d639c88dc8b9 Reviewed-on: https://gerrit.libreoffice.org/53130 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22vcl: introduce BitmapSharpenFilterChris Sherlock
Change-Id: Ib503efa3634b3a000261d2398d04f779079bfe3f Reviewed-on: https://gerrit.libreoffice.org/53129 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22vcl: create BitmapSmoothenFilterChris Sherlock
Change-Id: I5259035e18daada3cd8963f045731a0a65150718 Reviewed-on: https://gerrit.libreoffice.org/53099 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22vcl: ImplConvolute3() -> BitmapConvolutionMatrixFilterChris Sherlock
Change-Id: I0203e98d29192ef098719c0a297b967710b8729a Reviewed-on: https://gerrit.libreoffice.org/53097 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-22Drop header that had just one typedefKhaled Hosny
Move the typedef elsewhere. Change-Id: I7a91ffd5ed4d1f182d6d57c80eb5188892fa5ccd Reviewed-on: https://gerrit.libreoffice.org/53268 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
2018-04-22tdf#86399 Correctly set cluster start for RTL runsKhaled Hosny
A followup for the fix in b1030f75d3e47719ca63ec518f1da75196bead1a (from 2015) that didn’t work for Arabic because we were setting cluster start for RTL runs incorrectly. I’ve been suffering from this for so long but too lazy to debug it, until I saw this pace of code by pure chance and it looked dubious, finding where this flag is used and then seeing the comment referring to tdf#86399, then WOW I know what is going on! Change-Id: Ib7850e5a90ed3184738e995885f7f8b459ea2bb9 Reviewed-on: https://gerrit.libreoffice.org/53261 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
2018-04-21Drop GlyphItem constructor that is used only onceKhaled Hosny
Change-Id: I36aed033ea811daf2dfae89a89cf0ff5fc86b270 Reviewed-on: https://gerrit.libreoffice.org/53257 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
2018-04-21Tweak unit test for 1bpp images a bit for robustnessThorsten Behrens
Seems we're suffering gamma correction issue on a number of target platforms, so let's compare colors a bit more fuzzily. Fixup for eb5c0ccd47330fc726f4b4f854cf4cc518ac21cd Change-Id: Ieace78d1054efa6f49d42f1878774604e85c1965 Reviewed-on: https://gerrit.libreoffice.org/53259 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2018-04-21vcl: Bitmap::ImplSeparableUnsharpenFilter() -> BitmapSeparableUnsharpenFilterChris Sherlock
Change-Id: I62d95cc8bbf7b9349b1abc3e58bf0a202e3afec5 Reviewed-on: https://gerrit.libreoffice.org/53091 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-21cppcheck: identicalInnerConditionJochen Nitschke
renamed temporary list in EnhancedCustomShape2d.cxx to avoid shadow of a local variable Change-Id: I17a2261dafd2067480fcc5314af4f48765d6b690 Reviewed-on: https://gerrit.libreoffice.org/53244 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
2018-04-21loplugin:unusedmethodsNoel Grandin
Change-Id: I9dc6e81149eae3ba2284fa7fe608dd9252503dce Reviewed-on: https://gerrit.libreoffice.org/53197 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-21vcl: get rid of tabs in vcl/Library_vcl.mkChris Sherlock
Change-Id: I2c48efdf82e6433847f90ac0309935cb442b01b5 Reviewed-on: https://gerrit.libreoffice.org/53207 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-20Unittests for bugs with 1bit images rendering problemsVasily Melenchuk
Fix was done in 25cd843664919974f0d21ca7a0b02cc43e9eeabb and has impact on tdf104141, tdf113918, tdf115297 and some others. Change-Id: I8868dc1463b6f30b871a4f1b3129657f5bcb38f3 Reviewed-on: https://gerrit.libreoffice.org/51855 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2018-04-20DOC import: lazy-read imagesMiklos Vajna
At least JPEG files are now only loaded when the user scrolls to the relevant page. Also fix the root cause of the EMF lazy-read problem and remove the previous workarounds. Change-Id: I9699927282b99bcb71a0d271a20bbfd56a361ee8 Reviewed-on: https://gerrit.libreoffice.org/53219 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-04-20DOCX import: lazy-read images without external headersMiklos Vajna
So that similar to ODT, images are not loaded on file open, only when the user scrolls there. Notes: 1) GraphicDescriptor::ImpDetectJPG() would try to calculate the logic size before the pixel size is available, so the logic size would be 0x0. Also, ImpGraphic::ImplSetPrepared() would always work with a pixel map mode. Any of these two would result in a failure of testDMLShapeFillBitmapCrop in CppunitTest_sw_ooxmlexport6. 2) Lazy-loading seems to (at the moment) not recognize EMF files, so don't lazy-load in case an external header is provided. This probably has to be revisited, since the ODF import doesn't go via GraphicProvider::queryGraphic(). Change-Id: I44754e659effebca8339715df114dbaadb9b5e9f Reviewed-on: https://gerrit.libreoffice.org/53215 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-04-20towards solving tdf#112323: Allow multiple separators in listboxesMuhammet Kara
Change-Id: I40e2d9faa4121ad99e28cbae0d8eea8e46bc1e9a Reviewed-on: https://gerrit.libreoffice.org/53174 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Muhammet Kara <muhammet.kara@pardus.org.tr>
2018-04-20Function to load graphic swapped out (loaded on demand)Tomaž Vajngerl
When a document is loaded it takes a lot of time and memory to load the graphic that are in the documet, so avoid that and just store the compressed graphic into a temporary file (handeled by GfxLink) and load when we really need to show the graphic. GraphicObject cached some attributes from Graphic, but this attributes now aren't available immediately so this attributes are removed form GraphicObject and now delegate to the Graphic itself. GetSizeBytes attribute however was removed as it is only used in some tests. GfxLink initial values were moved to the constructor and are not set in the header file anymore (as it is the recommended way to do it). The SdImportTest::testDocumentLayout failed as it looks like the dump sometimes didn't include the width and height of the null bitmap (which is set to 32x32) of the FillBitmap in some situations, but then in other situations it did include this attributes. With this change the width and height are always included for the FillBitmap which looks like it is more correct. Change-Id: Ia1218f93b1735402b7828404f65660e2d4acf32f Reviewed-on: https://gerrit.libreoffice.org/53016 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-20loplugin:simplifybool (clang-cl)Stephan Bergmann
Change-Id: Ic63ebe497d9b9598be389d58cff294df2136ce2f
2018-04-20loplugin:cstylecast (clang-cl)Stephan Bergmann
Change-Id: Ica7c080e08d74443687069df42216e0f0c4f2153
2018-04-20vcl: move Bitmap{Ex}::ReduceColors() to BitmapColorQuantizationFilter classChris Sherlock
Change-Id: I32b58e8d451e7303e94788a546a5b5f9a5bb4590 Reviewed-on: https://gerrit.libreoffice.org/53037 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-20vcl: ImplSeparableBlurFilter() -> BitmapGaussianSeparableBlurFilterChris Sherlock
Change-Id: I996c9fcb0524e14e0093142be0749f0e5836426b Reviewed-on: https://gerrit.libreoffice.org/53071 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-19Related: tdf#116951 rhbz#1569331 end should be in terms of unicode charsCaolán McNamara
not bytes Change-Id: I05114019abb6c283586cd5c23ed1d148c9cf71d3 Reviewed-on: https://gerrit.libreoffice.org/53175 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-04-19tdf#95843: Wait for fire_glxtest_process also in --headless modeStephan Bergmann
Discussed with mmeeks on IRC that fire_glxtest_process is probably called as early as possible so that its reuslt is ready by the time it is needed in the non-headless case. So best fix for headless is probably to just wait for the sub-process at an opportune point, instead of redesigning the whole mess so that fire_glxtest_process would only be called once its result is actually needed. Change-Id: I4ea9c9d54b83c9695a3b72317e68fed0c410da0e Reviewed-on: https://gerrit.libreoffice.org/53154 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-04-19weld CompressGraphicsDialogCaolán McNamara
Change-Id: I593e6f0fe2e002c75ecd367a38dda96e7e6552f9 Reviewed-on: https://gerrit.libreoffice.org/53125 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-04-18weld SwCreateAuthEntryDlg_ImplCaolán McNamara
Change-Id: Ib654539cca64efe479cf3c9b8b585ab17019edeb Reviewed-on: https://gerrit.libreoffice.org/53117 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-04-18vcl: WNT: *really* avoid calling SHAddToRecentDocs() from unit testsMichael Stahl
At least in sw unit tests, AddToRecentDocumentList is apparently called too early so the variable isn't set yet. It's much better to check IsHeadlessMode anyway because that is set in more situations, and if you run soffice --headless you probably don't want the corresponding files to show up in Explorer's Recently list. Change-Id: I8ada3659d05c94d072ba30859090e835a595e9ea Reviewed-on: https://gerrit.libreoffice.org/53100 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2018-04-18vcl: WNT: avoid calling SHAddToRecentDocs() from unit testsMichael Stahl
On Windows 10, Explorer spends ridiculous amounts of CPU with updating its recent documents view while tests are running. Change-Id: I170306a392900fc4b911950e36f13f1af0e405ac Reviewed-on: https://gerrit.libreoffice.org/53058 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>