summaryrefslogtreecommitdiff
path: root/svx/source/xoutdev
AgeCommit message (Collapse)Author
2014-10-29remove unnecessary 'using namespace rtl' declarationsNoel Grandin
It turns out that almost none of them were necessary. Change-Id: I1311ed28409c682b57ea8d149bcbaf2c49133e83 Reviewed-on: https://gerrit.libreoffice.org/12133 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2014-10-20loplugin: cstylecastNoel Grandin
Change-Id: Idb6337bed1c32444f9644d54eba5240f09c13ef6
2014-10-20coverity#735639 Division or modulo by float zeroCaolán McNamara
Change-Id: I2ba45c49fb00fdd53b8e388e25df503e82c2332e
2014-09-26remove unnecessary casts in calls to SvStream.WriteUInt32Noel Grandin
left over from our conversion of the SvStream output operators to more specific methods Change-Id: I1d848f19f82783e6eabf2da37dbde78fe36ea1e0
2014-09-26remove unnecessary casts in calls to SvStream.WriteInt32Noel Grandin
left over from our conversion of the SvStream output operators to more specific methods Change-Id: I0c0172519479be0535a447e41a592fbf782751bd
2014-09-26remove unnecessary casts in calls to SvStream.WriteInt16Noel Grandin
left over from our conversion of the SvStream output operators to more specific methods Change-Id: Ie44bec6b988f3e46fe78d14b740818c9141f5df0
2014-09-12Turn SfxItemState into a C++11 scoped enumerationStephan Bergmann
...to gain further confidence in the claim "that none of the existing code tries to uses combinations of these enum values" (d92602c5b13d0a60439d86c5a033d124178726ca "more fixes for SfxItemState") Change-Id: I987922d945e8738e38adfde83b869adf3ff35b13 Reviewed-on: https://gerrit.libreoffice.org/11384 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2014-08-19svx: Cleanup ASCII art and useless commentsChris Laplante
Change-Id: I5399362056276f324fd43eda05d3f606dc6f8c71 Reviewed-on: https://gerrit.libreoffice.org/11011 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2014-08-04prevent memory leakMarkus Mohrhard
Found by Lsan. Returning this or a heap allocated object asks for trouble. Let the caller handle it and return null instead of this. Change-Id: I7586e103bef5a8c2727adfe214b052d6962d4467 Reviewed-on: https://gerrit.libreoffice.org/10716 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2014-07-29drop use of SFX_ITEM_PRESENTATION_NONENoel Grandin
since none of the call sites specify it Change-Id: I9c15f0e042e21f6f78560c1962a533112d588c90
2014-07-29simplify return argument of SfxPoolItem::GetPresentationNoel Grandin
since all two of the actual call-sites only care about whether it is a valid presentation or not, not what kind of presentation it is. Change-Id: I75717c88878d37b2897741b0c833ff283b3fee59
2014-07-19XFillStyle -> css::drawing::FillStyleMiklos Vajna
Change-Id: I6b2fabd72fd34f4ac1b3a18f386c90794bc39ce4
2014-07-03Avoid null this pointers in member function callsStephan Bergmann
Change-Id: Iada6d8fcd261ddfb02b4dbc2f628ef0738c4ea01
2014-06-26check for self-assignCaolán McNamara
Change-Id: I6ffaaa36f2e594a2e8155589a4d7000db21ab30b
2014-06-23Avoid possible memory leaks in case of exceptionsTakeshi Abe
Change-Id: I0cea121c8a8dbbc7b9f44ab712ff692243889816
2014-06-17improve the inlinesimplememberfunctions clang pluginNoel Grandin
Change-Id: I6d5a952901648e01904ef5c37f953c517304d31e
2014-05-20Prefer cppu::UnoType<T>::get() to ::getCppuType((T*)0) part18Julien Nabet
Change-Id: Ibf958dbfbf7cdbe6ad31d390138be8d4d468c225
2014-05-16unused XGradient::VclGradientMiklos Vajna
Change-Id: Ia0c416ce7c1323f9c0c20b969bd57e9a2174a3dc
2014-05-13unused XFillStyleItem ctorMiklos Vajna
Change-Id: I28497670242a98fba0f5f507a6f634a6fe59c20e
2014-05-10coverity#984153 Uninitialized scalar fieldCaolán McNamara
Change-Id: I25581ff4471d8a7f50849335dd7bd0ccad7b0742
2014-04-15svx: sal_Bool->boolNoel Grandin
Change-Id: I464eba5fd5521c31868c6fc8a2137f17428d421e
2014-04-11Introduce twip/mm100 conversion functions instead of duplicated macrosTor Lillqvist
Change-Id: Ib689e35b417e0e9016cd6a239c986e0603a99d62 Reviewed-on: https://gerrit.libreoffice.org/8837 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2014-04-01coverity#708395 Uninitialized pointer fieldCaolán McNamara
Change-Id: If7c1d6e628e50bb0be2e1218d4f1d798744a53a1
2014-03-14svx: sal_Bool->boolNoel Grandin
Change-Id: I673d022c01b7d076120c026b236a37735b5043b0
2014-03-07Do not convert SVGs to JPEGs when editing with external toolAlex Henrie
This patch adds support for opening SVGs in the user's default SVG viewer/editor. If the image cannot be exported to SVG directly, it is exported as PNG instead. In no case will an SVG or an unrecognized format be lossy-converted to JPEG. Change-Id: I46dc8548c3cfb4d24a4a0078d4e3d7eee8367b1c
2014-03-06n#821567: Use BitmapURL only if its valid.Muthu Subramanian
2014-03-03SVX : Remove usage of DBG_CTOR and DBG_DTOR.Arnaud Versini
Valgrind is capable of detecting such bugs. No need for extra macros. Change-Id: I9f2ab3703feb5c49a831da124e161f98cb1bb3ab Reviewed-on: https://gerrit.libreoffice.org/8419 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-27Resolves: #i15508# Added support for BMP file typeArmin Le Grand
(cherry picked from commit 9956ed1303545cd61901e33b110698c4e5e224c4) Conflicts: filter/source/msfilter/escherex.cxx include/vcl/gfxlink.hxx svx/source/xml/xmlgrhlp.cxx sw/source/ui/docvw/romenu.cxx vcl/source/filter/graphicfilter.cxx Change-Id: Ibcbb69b9c57cd8a438788e9a9c95744e99b6fcdd
2014-02-20Remove vcl/settings.hxx from vcl/svapp.hxx and vcl/outdev.hxxTobias Lippert
Added vcl/settings.hxx to all cxx files which require it. This helps to speed up compilation after changes to the settings. Conflicts: sc/source/ui/dbgui/pvlaydlg.cxx Change-Id: I211a0735c47f72d6879f6f15339355abfe0e3cf4 Reviewed-on: https://gerrit.libreoffice.org/7933 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-20svl: sal_Bool -> boolStephan Bergmann
Change-Id: Ic31455a1f5ffffa35d4fdde901dd70734207b6f4
2014-02-12convert SvStream::operator>> methods to ReadXXX methodsNoel Grandin
First, I updated the clang rewriter to do the conversion. Then I lightly hand-tweaked the output for the few places where the rewriter messed up, mostly when dealing with calls on "this". Change-Id: I40a6a977959cd97415c678eafc8507de8aa3b1a9 Reviewed-on: https://gerrit.libreoffice.org/7879 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2014-02-04convert specialised SvStream::operator>> methods to ReadXXX methodsNoel Grandin
as preparation for converting the SvStream::operator>> methods on primitive types Change-Id: I62f134bced15c687d6e0d46924f56e8d1c3d95b9 Reviewed-on: https://gerrit.libreoffice.org/7798 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2014-01-28bool improvementsStephan Bergmann
Change-Id: Ic32faa81bfbb66a9d8632fb3db187e33c31188ed
2014-01-22convert more SvStream::operator<< callsNoel Grandin
.. to more explicit SvStream::Write* calls This was done using another run of the clang rewriter, and then a lot of hand tweaking to fix all the places where the rewriter did not play nice with various macros. Change-Id: I7bcab93851c8dfb59cde6bc76290c6484d88fb18 Reviewed-on: https://gerrit.libreoffice.org/7494 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2014-01-20Related: #i56998# use locale rules to format percentageCaolán McNamara
Change-Id: I4b744cf10165383153d2a71c05df0c0ed327c641
2014-01-20Resolves: #i56998# add a space separater between value and unit...Tsutomu Uchino
and remove separator between value and percent to match with ISO 31-0 (cherry picked from commit 0cea884e3f417e4b58d2fdcfc7b0111f3bfc6f30) Conflicts: chart2/source/controller/dialogs/tp_SeriesToAxis.src cui/source/dialogs/colorpicker.cxx cui/source/dialogs/colorpicker.src cui/source/dialogs/grfflt.src cui/source/dialogs/zoom.src cui/source/tabpages/tabline.src editeng/source/items/frmitems.cxx editeng/source/items/textitem.cxx sd/source/ui/animations/CustomAnimationDialog.src sd/source/ui/animations/SlideTransitionPane.src svx/source/dialog/bmpmask.src svx/source/engine3d/float3d.src svx/source/items/algitem.cxx svx/source/sidebar/text/TextCharacterSpacingControl.cxx svx/source/xoutdev/xattr.cxx sw/source/ui/utlui/attrdesc.cxx sw/source/ui/utlui/uiitems.cxx Change-Id: I554309cb72dd8956077c5ca6866a982cdd6529aa
2014-01-16convert SvStream::operator<< overloads to more explicit methodsNoel Grandin
This is in preparation for more conversion of SvStream::operator<< calls to use more explicit method names. This converts the subclasses that have their own convenience overloads of operator<< to use normal methods. Change-Id: I5efd5d9a24c264cb86d2471303dd5849bf91ba80
2014-01-10SfxPoolItem::operator ==, != should return boolStephan Bergmann
...and SfxEnumItemInterface::HasBoolValue, too. Change-Id: Ia032e3d35a4c3b4c1efdc515ca36e466be03fc0a
2014-01-10re-write SvStream operator<< to non-overloaded methodsNoel Grandin
This is the actual re-write. Use a clang rewriter to rewrite SvStream::operator<< to methods like WriteuInt32. Note that the rewriter is not perfect, and I hand-tweaked the output. In particular, I had to adjust places doing things like (*this) << 1; Change-Id: I5923eda3f4ebaa8b452b6ef109e726e116235a2a Reviewed-on: https://gerrit.libreoffice.org/7342 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2013-12-09fix equalsAscii conversion. Noticed in fdo#72391Noel Grandin
In commit 363cc397172f2b0a94d9c4dc44fc8d95072795a3 "convert equalsAsciiL calls to startWith calls where possible" I incorrectly converted equalsAsciiL calls to startsWith calls. This commit fixes those places to use the == OUString operator. Change-Id: If76993baf73e3d8fb3bbcf6e8314e59fdc1207b6
2013-11-19convert equalsAsciiL calls to startWith calls where possibleNoel Grandin
Simplify code like: aStr.equalsAsciiL( "%", 1 ) to aStr.startsWith( "%" ) Change-Id: Iee0e4e60b0ae6d567fa8f72db5d616fffbec3c00
2013-11-19remove unnecessary use of OUString constructor when assigningNoel Grandin
change code like aStr = OUString("xxxx"); to aStr = "xxxx"; Change-Id: Ib981a5cc735677ec5dba76ef9279a107d22e99d4
2013-11-19remove most use of RTL_CONSTASCII_USTRINGPARAM macroNoel Grandin
This is largely unnecessary when working with OUString Change-Id: I3cf4d68357a43665d01162ef4a2d5346a45da9be
2013-11-14rhbz#887420 Implement "block untrusted referer links" featureStephan Bergmann
For now, this checks for a trusted referer (if the BlockUntrustedRefererLinks configuration prop is set) in utl::MediaDescriptor::impl_openStreamWithURL and SvxBrushItem::GetGraphicObject. Checking in additional places will probably be necessary to block /all/ unwanted communication. Also, some places marked /*TODO?*/ currently pass in an empty referer (which is always considered trusted) and will probably need to be adapted. Ideally, Referer URIs would never be empty (and consistently use something like <private:user> for cases where access is explicitly initiated by the user and should never be blocked), but that's a very daunting task, so start small by identifying the places that potentially need blocking and adding appropriate Referer URIs there. Also, Referer information should always be computed as freshly as possible from the context in which an access attempt is made, but, again, always carrying the information from the context all the way to the relevant functions is a very daunting task, so for now store the information upon object instantiation in some cases (SvxBrushItem, SdrGrafObj, ...). The Referer URI (css.document.MediaDescriptor property; SID_REFERER) was already used to track macro execution, and there is one place in SfxApplication::OpenDocExec_Impl where opening of hyperlinks (explicitly clicked by the user) is done that needs the current document's URI as Referer to check execution of macro URIs but needs an empty (or <private:user>, see above) Referer to not block non-macro URIs. Special code has been added there to handle that. Change-Id: Iafbdc07a9fe925d9ee580d4f5778448f18f2ebd9
2013-11-05Resolves: i123564 corrected some aspects when working with bitmaps...Armin Le Grand
with low color depth or small size (cherry picked from commit ba54ce4fc788605fc96235f432b455311faee406) Conflicts: cui/source/tabpages/tpbitmap.cxx Change-Id: I10677414ab7d1904dbb29cd395a0c0334e0faa03
2013-10-01convert remnants of String in SVX to StringNoel Grandin
Change-Id: I66fd6387c3fcd33c6ae0b431810abf6679345767
2013-09-29fix undefined behavior with out-of-bounds substring accessMarkus Mohrhard
Change-Id: Ie40d3dd2947d41b62eae84f20cfe457d69cc4bfe
2013-09-25Related: fdo#38838 remove UniString::EqualsIgnoreCaseAsciiCaolán McNamara
Change-Id: Ib5c3a2daa4a48bc286b14fa2cebb3306ea0012bc
2013-09-05convert svx/* from XubString to OUStringNoel Grandin
Change-Id: Ifa063924d95bfe397bd512411a44247d4c016018
2013-09-05convert svx/source/xoutdev/*.cxx from String to OUStringNoel Grandin
Change-Id: I77e122f5558a246575c68d1759bb9a07b4ce23bb