summaryrefslogtreecommitdiff
path: root/vcl
AgeCommit message (Collapse)AuthorFilesLines
2016-03-23vcl: idle timer update method currently unused.Michael Meeks1-15/+3
Change-Id: I4bc36592240dd3639e10e6b7c39400b5f52d932d Reviewed-on: https://gerrit.libreoffice.org/23471 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-03-23trying to get a GL context after GL de-initialization - fixedMarco Cecchetti1-14/+25
Change-Id: I5f38f72b0e2c0204875d0dfbb759d6b13415560a Reviewed-on: https://gerrit.libreoffice.org/23434 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org>
2016-03-23tdf#98600 and tdf#98622 fix metafile parsing (part2)Noel Grandin3-1/+7
more regressions from commit db17d3c1 "new loplugin: memoryvar" Change-Id: I611697f2bc818f2f42a704bfb5297637c30060c9
2016-03-22These functions are defined only when ENABLE_CAIRO_CANVASKorrawit Pruegsanusak1-0/+3
Class X11SalGraphics are derived from class SalGraphics, which is defined in vcl/inc/salgdi.hxx. So these override functions should be defined in the same condition as the base class. Change-Id: I5af0ee9c89c74e66b8f2dbd44890606fc5e41b14 Reviewed-on: https://gerrit.libreoffice.org/23373 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-03-22tdf#84323: Make osl::Thread::wait more readableGurkaran2-14/+6
It is to improve the readability of calls to osl::Thread::wait. Change-Id: I025d89abf8e84ca73ba08f001be3f45b86c89957 Signed-off-by: Gurkaran <gurkran@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/23416 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-21fix windows 64bit build on vs2015Tomofumi Yagi1-1/+3
Visual Studio 2015 will report as follows at the time of 64bit build. /core/vcl/win/gdi/winlayout.cxx(3972): error C2397: conversion from 'long' to 'FLOAT' requires a narrowing. Change-Id: I1a96bd9244c693a3d41b4bf4c2df80ad3b106adc Reviewed-on: https://gerrit.libreoffice.org/23367 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org>
2016-03-21Just use plain bool hereStephan Bergmann2-7/+7
Change-Id: I82c19f2f0e0ef88497db54f426c91af2aee0bc99
2016-03-21Revert "tdf#96393: reuse layout if available"Eike Rathke1-16/+5
This reverts commit 9fdd671fb276a419089f26e47739c4a783d15e93. Not only introduced it the regression of https://bugs.documentfoundation.org/show_bug.cgi?id=98437 in that dialogs with options shown closed in a different size than they would be opened with options not shown now open in the previous closed size, but it also introduces regressions for dialogs with nested windows where if the initial layout is skipped for the remembered outer window size the inner windows are not initialized anymore. One example is the Calc Manage Names dialog, where the table is a nested window that now has an initial width 0 and thus the column headers that should be equally sized distributed are lumped together at the top left and only two are displayed instead of three and the table content is messed up. Change-Id: I319d931cde2b7b87261e4c04122b91cd0f64b117 Reviewed-on: https://gerrit.libreoffice.org/23402 Reviewed-by: pepp <pelloux@gmail.com> Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com>
2016-03-21Need to get the shortcut of the real commandMaxim Monastirsky1-1/+4
... as command alias can't have one by itself. That's the same we do for menus. Change-Id: I555a41282001300fa9aa0e585c073656789c4ebd
2016-03-21tdf#98324 - PNG prints as black block with OpenGL - fixedMarco Cecchetti2-1/+10
Now the correct color palette is used. Change-Id: If26c7cb149d1d6c24ae78137ff54669b3091fdb2 Reviewed-on: https://gerrit.libreoffice.org/23378 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-03-19Remove commented-out codeGurkaran1-2/+0
Follow-up to 2f7815ab6b3f93f7f9712d403846f1874b8e3a2b Change-Id: Ifd2dca4105caf5693a8ae17d26f950a3aef418bd
2016-03-19tdf#97973 - cleanup spinbuttons theming logic.Gurkaran3-25/+1
vcl/unx/kde4/KDESalGraphics.cxx had a special case to build the widgetRect for spin-buttons which is cleaned up. vcl/unx/gtk/salnativewidgets-gtk.cxx had a wrong comment and special case regarding CTRL_SPINBUTTONS which is cleaned up. vcl/win/gdi/salnativewidgets-luna.cxx had a wrong comment regarding spinbutton which is cleaned up. Change-Id: I3c2797800221e150be165666bf71b65302724444 Signed-off-by: Gurkaran Singh <gurkran@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/23345 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-03-19Fix failure to print when using the D2DWrite pathTim Eves1-7/+5
It seems that D2D1DCRenderrTarget cannot bind to a DC on a printer device. Now whenever that attempt to bind the DC fails we run the legacy API path as a fallback. Change-Id: I6ad8d82e5280fd2dcf669310bab0f5bfc23a138a Reviewed-on: https://gerrit.libreoffice.org/23366 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Martin Hosken <martin_hosken@sil.org>
2016-03-17Resolves: tdf#98726 sneaky transparent clearlooks-phenix scrollbarsCaolán McNamara1-14/+18
Change-Id: Idc05d7b6c2b42086eafa9ad8ab8e63116d6f676c
2016-03-17too many configurations, too many platforms variantsCaolán McNamara1-1/+1
Change-Id: I10a284b7c27b145b003ff01a77dc5c0d51f418ad
2016-03-17Add a humble wishTor Lillqvist1-1/+3
Change-Id: Ie94f991acebda4e9074dba46d7bd65b433e0ce9b
2016-03-17loplugin:constantparam in toolsNoel Grandin3-4/+4
Change-Id: I3774661799c074561c694515baba42a375d0a077 Reviewed-on: https://gerrit.libreoffice.org/23301 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-16WaE: loplugin:nullptrCaolán McNamara1-2/+2
Change-Id: I279d0021e7cdfd7e2d73ec6542e9ba27f300606c
2016-03-16tdf#97319: Give up on caching non-BMP glyphsTor Lillqvist1-0/+7
I can't figure out why successive non-BMP glyphs in the bugdoc get drawn on top of each others. So bail out... Change-Id: I9c6241916347ec31d616e5cbf00bf3b1869edba2
2016-03-16tdf#98607 - fix drag and drop regression.Michael Meeks2-2/+5
regressed in: f2f1f52d8b84ac088496a4964d799bb84007fc45 Added belt and braces fix. Thanks to Maxim for the bisect. Change-Id: I5b263870d76f44ef8833b27f0d8d391210216459 Reviewed-on: https://gerrit.libreoffice.org/23307 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-03-16attempt to address reported loplugin:vclwidgets warningCaolán McNamara1-3/+3
Change-Id: I6ccefa2d5d1c57cf9f1c4041d14c92d03ded1333
2016-03-16loplugin:constantparam in unotools/Noel Grandin4-12/+11
Change-Id: I016cf96af3a93c8f2114657a7e59599f68446ddc Reviewed-on: https://gerrit.libreoffice.org/23296 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-16vcl: fix loplugin:defaultparamsMiklos Vajna2-7/+6
Change-Id: Ic947d1a4a341a778c88d1225b1a2ea66df697084
2016-03-16coverity#1355505 Uninitialized scalar fieldCaolán McNamara1-0/+5
Change-Id: I95d76b6c06d194b762ecd0534c51314744eb42ae
2016-03-16match types for legibilityCaolán McNamara1-2/+2
Change-Id: Ifd84a9a9dc54772a56d3bf0e345782f7f77562bd
2016-03-16Related: tdf#98637 make this a tractable problemCaolán McNamara11-31/+48
This is just too hard, it would all be much easier if the ActionGroup existed right from the start of the entire process. So smuggle in to the ctor the toplevel frame that the menubar will be inserted into so we can use its ActionGroup from the start. That would suggest that we could then just keep the hierarchy in sync as it is created rather than finding opportune moments to update /generate it. Change-Id: I550f94a994210423ab9cea1986e643056cb5bd29 Reviewed-on: https://gerrit.libreoffice.org/23287 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2016-03-16loplugin:constantparams in vcl/Noel Grandin54-782/+333
also some improvements to the plugin Change-Id: I0e3a519d70756e577fcb1bd47dd66864b5b4c871 Reviewed-on: https://gerrit.libreoffice.org/23289 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-16loplugin:implicitboolconversionTor Lillqvist1-1/+1
Change-Id: I9edc0d2e478f83e39e93e70e6c05c77b0125aad0
2016-03-15fix windows buildChristian Lohmaier1-2/+2
34a7b51ea482d4487d4fb8e61cde18aa1ff9b8ff (for 5-1) auto → size_t made 32bit happy, but win64bit still failed with: error C2784: ´_Ty std::min(std::initializer_list<_Elem>,_Pr)´ : could not deduce template argument for ´std::initializer_list<_Elem>´ from ´__int64´ Change-Id: Ib44840f692f1bcdea90decfe443c6eb72806002a
2016-03-15Resolves: tdf#98636Caolán McNamara3-5/+22
On changing a menu item from a non-submenu to a submenu then update the newly created menu as if it was the first full update of the entire menu hierarchy. On changing a menu item from a submenu to a non-submenu its evidentially not sufficient to unset the G_LO_MENU_ATTRIBUTE_SUBMENU_ACTION attribute so remove the submenu-item and add a new non-submenu item to force its new type Change-Id: I2030d9198d6849643a5991ddfffc1cc3425ba72e
2016-03-15vcl: improve opengl glyph cache debugging.Michael Meeks1-7/+23
Show cutting rectangles, base-lines, and count box widths. Change-Id: Ic6a08c4c029d6b576ea55479bbf6293accae6f15 Reviewed-on: https://gerrit.libreoffice.org/23251 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-03-15tdf#98600 and tdf#98622 fix metafile parsingNoel Grandin1-0/+2
regression from commit db17d3c1 "new loplugin: memoryvar" Change-Id: I8b11871cadcf50649533680be51c767d6bb98350
2016-03-15tdf#97319: Handle surrogate pairs in glyph caching for SimpleWinLayoutTor Lillqvist1-12/+37
(For UniscribeLayout we use glyph indices.) Change-Id: Id1907cb766b9285d32e484049bec1b99159c5768
2016-03-15s/SEP/SMPTor Lillqvist1-1/+1
See https://bugs.documentfoundation.org/show_bug.cgi?id=97319#c8 . Change-Id: I66f5ea5ddd2a98de1d6445f3c6a91f1943dd7ca4
2016-03-15We use strlen() on these char arrays so better terminate them with 0Tor Lillqvist1-9/+9
Avoids an assertion failure for me. Change-Id: I811a3702baf76465acc580bc0e05db8a3c7f5364
2016-03-15remove unnecessary parentheses in case labelsNoel Grandin14-331/+331
Change-Id: I987bf68c767709080c67c8b183c036a4109c6caa
2016-03-15loplugin:constantparamNoel Grandin5-10/+9
Change-Id: I270e068b3c83e966e741b0a072fecce9d92d53f5
2016-03-14Bin a few pointless static const integersTor Lillqvist1-10/+8
Change-Id: I59f2547523129155b9d17699cc985fe0bd78f7e6
2016-03-14Bin leftover #if 0 snippetTor Lillqvist1-22/+0
Change-Id: I848a5dca6d18c3df57f563bb137efaed2e000461
2016-03-14fix memory leak in headless backendMarkus Mohrhard1-1/+5
Change-Id: I90282c86b45845fc35b23b275301be24a2f18a4d Reviewed-on: https://gerrit.libreoffice.org/23248 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-03-14tdf#95845 Use CommandInfoProvider to receive UNO command labelsSusobhan Ghosh1-0/+33
Added GetCommandPropertyFromModule to CommandInfoProvider. Removed GetCommandText. Change-Id: Ie987984b6465d540029196df371c0c0467999a59 Reviewed-on: https://gerrit.libreoffice.org/22918 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2016-03-14Resolves: tdf#98638 sometimes menu grab doesn't takeCaolán McNamara1-4/+4
due to older timestamp vs earlier grab. Which suggests we should probably use GDK_CURRENT_TIME everywhere or (probably better) use gtk_get_current_event_time everywhere Change-Id: Ie04ab254b9fea423143cc9a129d2eecb683ed300
2016-03-14remove some unused Java codeNoel Grandin1-2/+0
found by UCDetector Change-Id: Ic0295a24b26e206eb53eda2da540755477df86df
2016-03-14tdf#95616 - fix flickering issueMarco Cecchetti1-0/+1
Change-Id: I0d5bfdf44dde2cd06c193f34e81c6ce71291bba1 Reviewed-on: https://gerrit.libreoffice.org/23238 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-03-14Fix what seems to have been off-by-one errors in glyph bounds calculationTor Lillqvist1-2/+2
For some reason the error had a visible impact (as far as I an see, anyway) only for Graphite fonts. The bottommost pixels were cut off. (Also leftmost, but that was not so easily visible.) <tools/gen.hxx> Rectangle type, I love you. Change-Id: I6f7438ec21d2bc1b9bef31cd70e649856f7ec7d5
2016-03-14tdf#97171: Use DirectWrite for OpenGL glyph cachingTim Eves1-283/+415
This is a squash of several separate intermediate commits, the most relevant log messages of which are repeated here: Refactor some previously private methods into public ones and reimplement parts of D2DWriteTextOutRenderer to user them. Also apply them to rendering the OpenGL glyph atlas, in an effort to workaround some bugs in legacy Windows text rendering APIs. I assume we want to initialise the rectangle with zero left/right/top/bottom and not using the default constructor, which sets the right and bottom coordinates to the magic value -32767. That made the 'bound' rectangle end up with rather amusing boundaries, like left=-32766, top=-16, right=-32576, bottom=6. Try calculating a chunks ascent & height from the inkboxes rather than using the font metrics which might not alway be correct when glyphs inkboxes are tall than the ascent or lower than the descent. Mark the mnAscent in the chunk bitmap debug output. Fix several miscalulations in positioning glyph to be rendered into that atlas. Fix vertical alignment problems. Inkboxes are returned with all co-ordinates relative to the glyphs not the fonts ascent. Therefor bounds.Top() is not the vertical overhang but the -ve height of the inkbox above the baseline. This fixes the calulation of the per Chunk ascent. Fix horizontal occsional alingment issues in OpenGL cached glyphs. The left edge of the src location rectangle for the first glyph in a cache chunk would set to extraspace and not zero, but all other rectangles in the chunk would be set from the aEnds array. This produced a bug where only certain letters would be mispositioned, proportional to the fonts point size. Rename OpenGLGlyphChunk::mnAscent to mnBaselineOffset to reflect curr use. Changed at Tor's stuggestion to better describe to it's use as it's value would be per chunk and based on the maximum ink box bounds of the glyphs in the chunk, rather than having anything to do with the font's real ascent value.
2016-03-14GetEnglishSearchFontName is what is supposed to use hereDouglas Mencken1-3/+5
Change-Id: I210359c28b5e66b64627cb49cdf388ee35015a92
2016-03-13coverity#1355505 Uninitialized pointer fieldCaolán McNamara1-6/+17
Change-Id: I95259c8a572529f47ef4fddf59f9ca29d078b6f4
2016-03-13add assert preventing memory leakMarkus Mohrhard1-0/+1
Change-Id: I0c659bf4fab2319f06df09dd11a768a295e95722
2016-03-13fix strange memory leak in VclBuilderMarkus Mohrhard1-1/+1
Change-Id: Iba34c25b19a94a8d4c147f8ccaef95f34183414b