summaryrefslogtreecommitdiff
path: root/vcl/source
AgeCommit message (Collapse)AuthorFilesLines
2014-04-03remove unnecessary scope qualifier from sal_Bool usesNoel Grandin1-1/+1
i.e. convert "::sal_Bool" to "sal_Bool" Change-Id: Ie5943aee4fee617bf2670655558927ed25b7e067
2014-04-03vcl: apply font height if defined as "size" attribute in .uiTomaž Vajngerl1-0/+7
Change-Id: I28719b16fb47a618420195640f4f75a79ca889ea
2014-04-03vcl: sal_Bool->bool and cleanupNoel Grandin3-31/+29
- remove unused PFilterDlgCall typedef - remove bool parameter from PFilterCall typedef - it was always being called with false, and nothing was reading it Change-Id: Ic56127e7d55254a7b9b65849a21cb286f52344d1
2014-04-02Related: fdo#75307 use the unique auto help id to identify tabpagesCaolán McNamara1-0/+8
and dialogs that are loaded from the .ui format Change-Id: Id8abff6d89818ca7384d9691a05eacd378a5905c
2014-04-02coverity#708642 Uninitialized pointer fieldCaolán McNamara1-1/+4
Change-Id: I30b61ed5b383f4acb5d29cb1c898015b28b1431c
2014-04-02coverity#708600 Uninitialized pointer fieldCaolán McNamara1-0/+2
Change-Id: I50da1da601981d55f413e03b063cda60b10893e6
2014-04-02coverity#708589 Uninitialized pointer fieldCaolán McNamara1-1/+3
Change-Id: Ifc584276b32e517cb3105133de731e068851254b
2014-04-02coverity#708314 Uninitialized pointer fieldCaolán McNamara1-18/+24
Change-Id: Ifdd607c8bb1859af907ba2d6bbe6e9824681bc57
2014-04-02Resolves: #i124580# corrected some conversions of scale values...Armin Le Grand1-3/+12
to integer positions (cherry picked from commit d3c4a0c2a87504007a30e6944f52da4654cfa784) Change-Id: Iae4c16250e95938999d60d1c60e1163dfba243cf
2014-04-02Kill superfluous vertical whitespaceTor Lillqvist195-4076/+0
Change-Id: I81ce8fd7022bf283db668705efdfb0666f87bde9
2014-04-02fdo#63786 rhbz#1081968: fix PDF export of cropped SVGMichael Stahl2-10/+13
When a META_FLOATTRANSPARENT_ACTION is exported, the beginTransparencyGroup()/endTransparencyGroup() will write something like "Q 0 0 0 rg" where the Q clears the previously set clipping region, which is then not restored. bdf75c7d9bce985ed10a9c41d03420f33ce82142 appears to be a fix for a previous related problem; this essentially reverts it since it introduced the current cropping problem. (Particularly funny is the comment "force reemitting clip region" since the commit does the opposite.) It does not really make sense to me to write something to the page content stream from beginRedirect()/endRedirect(), because that does not actually have any effect on the _content_ of the substream, because the referencing of the substream is only written _after_ endRedirect() returns, so basically what is written can in the best case cancel itself out and in the worst case introduce bugs; the state manipulations there are just to modify the m_aCurrentPDFState following the push()/pop() (it is necessary to clear the clip region before starting the substream to avoid spurious "Q" at the beginning of the stream). Change-Id: I4a5f57b784068bd7d3ba187115444574f7418195
2014-04-02init a few more stream-read svm elementsCaolán McNamara1-35/+42
Change-Id: I3dfa2485afbe66131b86764374d53181b55c2346
2014-04-02GraphicFilter::LoadGraphic: SAL_WARN -> SAL_INFOMiklos Vajna1-1/+1
Only the caller can decide if trying to load a graphic is really a problem, e.g. in case no persona is configured, then loading its header is OK. Change-Id: I7286b7d907940fa3a80f6256cd5264cbd5718fb8
2014-04-01Explicitly mark overriding destructors as "virtual"Stephan Bergmann10-16/+16
It appears that the C++ standard allows overriding destructors to be marked "override," but at least some MSVC versions complain about it, so at least make sure such destructors are explicitly marked "virtual." Change-Id: I0e1cafa7584fd16ebdce61f569eae2373a71b0a1
2014-04-01valgrind: Conditional jump or move depends on uninitialised valueCaolán McNamara1-1/+1
Change-Id: Ia0b22f7c394d1c2387d1cad7e3d99c79eaeca81a
2014-04-02fdo#74702 update bad advise in comment in DrawTransparentNatively()Chris Sherlock1-4/+5
We really do *not* want to introduce the horror that is meOutDevType into our code. If we need to stop the Printer class from drawing a PolyPolygon then we should let Printer do this, not make OutputDevice make this decision on Printer's behalf! Change-Id: If74eccdf34688ce1164da2bb705ea48eefc18800
2014-04-01fdo#74702 Refactor code to use ClipToPaintRegion()Chris Sherlock2-21/+3
There is a fair amount of code that should use ClipToPaintRegion(). Not only does this remove meOutDevType and decouples classes, but we are using code, so code reuse FTW. Change-Id: I05a2623b73f4a523230dc01d02db33a6df9911ab Reviewed-on: https://gerrit.libreoffice.org/8810 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2014-04-01vcl: FixedHyper - take into account text alignmentTomaž Vajngerl1-3/+26
Change-Id: Icc9b4d73cd2e4945299cbaaa1b55eebc3e1e3922
2014-04-01Resolves: #i124555# restore stream position after Seek to end of streamOliver-Rainer Wittmann1-6/+7
(cherry picked from commit 61efddf5ab8cd318e022ca1ac817ba0879a55e23) Conflicts: vcl/source/gdi/dibtools.cxx Change-Id: Ie6c0aeab5988b68954a0bdd460317ac9539d8a5f
2014-04-01Improved coding style as shown in examples fdo#75240Milan Zelenka1-64/+71
Change-Id: I6a19453637ea6de8e8c834ad14d7cdf712671e46
2014-03-31fdo#74702 New abstract function UsePolyPolygonForComplexGradient()Chris Sherlock4-2/+19
A new protected abstract function has been introduced only for complex gradients. As it stands, we currently need to work out if we should use a PolyPolygon or a Polygon because, as the comments say: // Determine if we output via Polygon or PolyPolygon // For all rasteroperations other then Overpaint always use // PolyPolygon, as we will get wrong results if we output multiple // times on top of each other. // Also for printers always use PolyPolygon, as not all printers // can print polygons on top of each other. Interestingly, the next line is either wrong or expressed badly, because the check uses PolyPolygons when a VirtualDevice is in use: // Also virtual devices are excluded, as some drivers are too slow. Therefore, I've removed that comment as it seems rather misleading. Change-Id: Ic496284cb2be8e7e2d348eae76aeeec994e1029c Reviewed-on: https://gerrit.libreoffice.org/8802 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2014-03-31error: unused variable 'aReturnString'Matúš Kukan1-1/+1
Change-Id: I53241eb41a07546fe4af010246d8ca373b0b1945
2014-03-31Resolves: fdo#43049 basic PPD custom options supportCaolán McNamara1-0/+5
because this is another way seen in the wild to transmit a fax number through cups as an alternative to using fax4CUPS Change-Id: I32db38aa05213e469442136eb46d0028098a8b7e
2014-03-31fdo#74702 OutputDevice::ImplInitFontList() fails if no fonts on deviceChris Sherlock1-17/+23
It makes no sense that ImplInitFontList() only fails for Window instances. I have carefully checked all the functions that use this function, and there are no good cases when no fonts won't cause problems. In fact, we have a number of functions that specifically rely on the fact that ImplInitFontList will populate OutputDevice::mpFontCollection with at least one font. Therefore, I'm making this abort if it can't populate the collection, regardless of whether it is a Window, Printer or VirtualDevice. I have also refactored GetDefaultDevice - I now check the default pOutDev parameter to see if it is NULL (the default), in which case it is referring to the default window, so I call on Application::GetDefaultDevice() instead of going straight to the pimpl data structure used by the Application class. Change-Id: I2861521d876d776d7862fc4a7ec56b7acf818789 Reviewed-on: https://gerrit.libreoffice.org/8741 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2014-03-31Remove now unused obsolete tools/debug.hxx functionalityStephan Bergmann4-490/+9
Change-Id: I1bc585af8f0189dfa219bd42a5f09871a006c6ea
2014-03-31use toBoolCaolán McNamara1-1/+1
Change-Id: I334570bac6f0ab8fbd606610f0dcd812041c72b1
2014-03-31vcl builder: FixedText support for underline text via attributesTomaž Vajngerl1-0/+6
Change-Id: I9dbe4979c1440ee0cb6a4649de05805b891f3760
2014-03-30Encase graphicsfilter warning in an #ifdefChris Sherlock1-0/+2
Change-Id: Ib91edb520c4edbbf63e034f174d21c6a74d03929
2014-03-30Clarify warning in graphicsfilterChris Sherlock1-1/+31
In GraphicFilter::LoadGraphic() it reports an error code, but that's particularly unhelpful. Change the warning to actually make sense: I decode the error code to English. Change-Id: I3ead54295eda63a8808bb24732d23aa95db0f5fb
2014-03-29typo: optimisation -> optimizationThomas Arnhold2-3/+3
2014-03-29fdo#74702 Refactor OutputDevice::DrawTransparent()Chris Sherlock2-240/+281
I have refactored OutputDevice::DrawTransparent() - functionality is now in the functions DrawInvisiblePolygon(), DrawTransparentNatively() and EmulateDrawTransparent(). DrawTransparentNatively() will return true if it is successful, otherwise it will return false if it isn't possible to draw the transparency natively. This allows us to fall back to a VCL based emulation. The function EmulateDrawTransparent() is virtual because Printer handles transparencies differently to pixel based devices. Change-Id: I300850ccea03c17673666dadd287bcddd40ec5ef Reviewed-on: https://gerrit.libreoffice.org/8779 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2014-03-29Fix another typo in a commentChris Sherlock1-1/+1
Change-Id: Ic998270701d2e8d2b562ccc869bca0a8d0aac728 Reviewed-on: https://gerrit.libreoffice.org/8778 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2014-03-29Fix comment typos in OutputDevice::DrawTransparent()Chris Sherlock1-1/+1
Change-Id: I52e9d505719b3f3b985cd5300ebacb5caa57873f Reviewed-on: https://gerrit.libreoffice.org/8777 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2014-03-28DbgOutTypef -> SAL_WARNStephan Bergmann1-54/+45
Change-Id: I837643b2c12bf70585dce128dad114cc65f7f0a1
2014-03-28Remove now unused DBG_CTOR etc. featureStephan Bergmann1-155/+11
Change-Id: Id5e3191ea1a505bd7d46af355edb99e184b5fcb1
2014-03-28Resolves: #i124467# add check for image data offset...Jürgen Schmidt1-1/+23
against stream length, some further checks (cherry picked from commit 9ceda6fa56d31af717cc2c0c7572cf53cdc47af1) Conflicts: vcl/source/gdi/dibtools.cxx Change-Id: I8993b91ef4fa951e7bae702b0d056996015245ba
2014-03-28Bin rest of DBG_WARNING[123]Tor Lillqvist1-38/+12
Change-Id: Iaaf36d012e353f73f083c9c0ebbbb6d0953b16c8
2014-03-28Use SAL_WARN_IF instead of DBG_WARNING2 and don't pass UTF-16 for %sTor Lillqvist1-4/+1
For lolz, I kept the useful German word "GrafikFehler" in the message, though. Change-Id: Ib714e27eef986cacfc979f132f1b2c29e603d9b0
2014-03-28Merge back branch alg_writerframes to trunkArmin Le Grand1-11/+11
(cherry picked from commit b635b4fa4e42053d30ab639643d2236a20243f62) Conflicts: comphelper/inc/comphelper/TypeGeneration.hxx comphelper/source/property/TypeGeneration.cxx cui/source/factory/dlgfact.hxx cui/source/inc/cuitabarea.hxx cui/source/tabpages/tabarea.cxx cui/source/tabpages/tabarea.hrc cui/source/tabpages/tabarea.src cui/source/tabpages/tparea.cxx drawinglayer/source/primitive2d/polypolygonprimitive2d.cxx drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx drawinglayer/source/texture/texture.cxx editeng/inc/editeng/unotext.hxx editeng/source/items/frmitems.cxx include/drawinglayer/texture/texture.hxx include/editeng/brushitem.hxx include/svx/sdr/primitive2d/sdrdecompositiontools.hxx include/svx/svxids.hrc include/xmloff/xmltypes.hxx reportdesign/source/ui/misc/UITools.cxx sc/source/ui/drawfunc/drawsh.cxx sfx2/source/dialog/tabdlg.cxx svl/source/undo/undo.cxx svx/inc/svx/unoshprp.hxx sw/Library_sw.mk sw/inc/doc.hxx sw/inc/format.hxx sw/inc/frmfmt.hxx sw/inc/swatrset.hxx sw/inc/unomap.hxx sw/inc/unoprnms.hxx sw/source/core/access/accpara.cxx sw/source/core/attr/format.cxx sw/source/core/attr/swatrset.cxx sw/source/core/doc/docdraw.cxx sw/source/core/doc/docfly.cxx sw/source/core/doc/notxtfrm.cxx sw/source/core/inc/frame.hxx sw/source/core/inc/frmtool.hxx sw/source/core/layout/atrfrm.cxx sw/source/core/layout/paintfrm.cxx sw/source/core/text/inftxt.cxx sw/source/core/text/porfld.cxx sw/source/core/text/txtfly.cxx sw/source/core/txtnode/fntcache.cxx sw/source/core/uibase/app/docst.cxx sw/source/core/uibase/app/docstyle.cxx sw/source/core/uibase/shells/drawdlg.cxx sw/source/core/uibase/shells/frmsh.cxx sw/source/core/unocore/unoframe.cxx sw/source/core/unocore/unomap.cxx sw/source/core/unocore/unoprnms.cxx sw/source/core/unocore/unostyle.cxx sw/source/ui/fmtui/tmpdlg.cxx sw/source/ui/fmtui/tmpdlg.src sw/source/ui/frmdlg/frmdlg.cxx sw/source/ui/frmdlg/frmpage.src sw/source/ui/inc/frmsh.hxx xmloff/source/text/txtprhdl.cxx xmloff/source/text/txtprmap.cxx Change-Id: Id3ffaa83bb5594d287f1ac8f2c1c9cf55c70946d
2014-03-28coverity#736161 Dereference null return valueCaolán McNamara1-0/+3
Change-Id: I6ce18d8446944e6b491ccd3973c5fa7e1413f073
2014-03-28coverity#736162 Dereference null return valueCaolán McNamara1-1/+1
Change-Id: If2a8f2ba79f3efa557cacb29553ba70e233f88f5
2014-03-28fdo#68546 Update style settings before changing layoutIsamu Mogi1-1/+1
Currently, ImplInitStyleSettings()'s effect isn't be reflect to UI. Because it is called after refreshing UI by ImplLayoutChanged(). This fixes these order. Change-Id: I4cfe0115bc32551cecc70cf4b33921fb8ee7ea5a Reviewed-on: https://gerrit.libreoffice.org/8714 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-03-28fdo#68546 Add menubar's text color of persona to StyleSettingsIsamu Mogi1-5/+15
Change-Id: I376e0b71b71fdbc2eaf2b10adb7792a841cf9098 Reviewed-on: https://gerrit.libreoffice.org/8711 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-03-28fdo#68546 Update settings for MenuBarWindow in InitStyleSettingsIsamu Mogi1-4/+5
It updates menubar's text color settings in StyleSettings when user changes persona. Change-Id: Ic9c3e8073b9188a792823a84bf78b9b5976af50d Reviewed-on: https://gerrit.libreoffice.org/8713 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-03-26First batch of adding SAL_OVERRRIDE to overriding function declarationsStephan Bergmann23-179/+179
...mostly done with a rewriting Clang plugin, with just some manual tweaking necessary to fix poor macro usage. Change-Id: I71fa20213e86be10de332ece0aa273239df7b61a
2014-03-26fdo#74702 Move device specific bitmap drawing to its own functionChris Sherlock2-29/+36
Device specific drawing has been moved to its own function. VirtualDevice and Window draw in the same way, so can be shared in OutputDevice, however Printer has its only specific ways of drawing so it needs its own method. Change-Id: I051fee029a1ec022a131bb12588189178c4109b2 Reviewed-on: https://gerrit.libreoffice.org/8724 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2014-03-26Split TYPEINFO into plain and TYPEINFO_OVERRIDEStephan Bergmann2-7/+7
...where the latter contains SAL_OVERRIDE annotations Change-Id: Id64794b388d83dfe7026440e8b20a5b5efd412d1
2014-03-26Bin DestroyVirtualDevice(): Just use delete directly at call sitesTor Lillqvist1-4/+3
Change-Id: I47c67d3d89ab22b07b3ec6fe7ea6e035d21e85b6
2014-03-25Remove now unused tools/debug.hxx profiling functionalityStephan Bergmann2-22/+0
Change-Id: I13adca8c2f929c8a9226b26ef57b26363dfdf0b3
2014-03-25osl_setDetailedDebugMessageFunc is effectively doing nothingStephan Bergmann1-13/+0
...since the osl/diagnose.h macros got rebased onto sal/log.hxx, so remove the corresponding tools/debug.h functionality. Change-Id: Ife4b5b1a2608230d0dbfc3fa8852243c89ed292f