summaryrefslogtreecommitdiff
path: root/sw/source/core/text/txthyph.cxx
AgeCommit message (Collapse)AuthorFilesLines
2020-12-29loplugin:stringviewparam: operator +Stephan Bergmann1-1/+1
Change-Id: I044dd21b63d7eb03224675584fa143009c6b6008 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108418 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-07-31loplugin:flatten in sw/core/textNoel Grandin1-21/+21
Change-Id: I086860cefe9f26c3728fe0d8266c35dae37b9570 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99887 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-12-02tdf#42949 Fix IWYU warnings in sw/source/core/[o-t]*/*cxxGabor Kelemen1-2/+0
Also drop a duplicated blacklist rule found with: grep :$ sw/IwyuFilter_sw.yaml | sort | uniq -cd Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ied72f3f086ed4c1eb7ff4bcdbcf8aee73ddd4f7c Reviewed-on: https://gerrit.libreoffice.org/83250 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-05-20tdf#42949 Fix IWYU warnings in sw/source/core/*/*hxxGabor Kelemen1-0/+1
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Idbd13674578be9d4edce5d2a5f45df145474d86d Reviewed-on: https://gerrit.libreoffice.org/72579 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2019-04-14loplugin:sequentialassign in swNoel Grandin1-2/+1
Change-Id: Iec56b41dba502e438dfdc7a99385545b3efdf8c7 Reviewed-on: https://gerrit.libreoffice.org/70720 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-01-18convert POR constants to scoped enumNoel Grandin1-8/+8
Change-Id: Ia146f1f932cf4437e2e7e20722b0957a458979fd Reviewed-on: https://gerrit.libreoffice.org/66514 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-01-17rename SwLinePortion::GetPortion -> GetNextPortionNoel Grandin1-9/+9
to make it obvious when reading the code that we have a linked list here Change-Id: Ia7b8592af36a87723e7ef7b301331dc71357002b Reviewed-on: https://gerrit.libreoffice.org/66513 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-24clang-tidy performance-unnecessary-copy-init in swNoel Grandin1-1/+1
Change-Id: I515e3e8ddaee3e3ddc4bf3827fb85f3489e84539 Reviewed-on: https://gerrit.libreoffice.org/62253 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-15fix callgrind crashNoel Grandin1-1/+1
after commit 96ef1973d0309cc8a6aa9482f2fe35804f49c414 loplugin:useuniqueptr in SwTextPortion::CreateHyphen Change-Id: Idb3b652c328ca20d049a1002088ded797f8ed098 Reviewed-on: https://gerrit.libreoffice.org/60517 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-14loplugin:useuniqueptr in SwTextPortion::CreateHyphenNoel Grandin1-6/+6
Change-Id: I9ab88f5d15a2d98285ac4c1ffce8750c16830d56 Reviewed-on: https://gerrit.libreoffice.org/60453 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-03use less magic in sw/Noel Grandin1-5/+5
rename the "magic" members and fields that are actually a font-cache-id, to more useful names Change-Id: Ie787b0939115c576e979c7e27a21a68c138c32f6 Reviewed-on: https://gerrit.libreoffice.org/59868 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-06-27sw: prefix members of SwInterHyphInfoTextFrameMiklos Vajna1-7/+7
Change-Id: Idc99dfd6e5ee7bc999088f4657d77613d0029b97 Reviewed-on: https://gerrit.libreoffice.org/56489 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-06-08sw_redlinehide: hyphenationMichael Stahl1-19/+21
There's a loop over nodes, calling SwTextNode::Hyphenate() each time. Introduce a new class SwInterHyphInfoTextFrame that is used in the SwTextFrame functions, and SwTextNode::Hyphenate() converts between the 2 types. Not sure if this will hyphenate a word that is split across nodes in the model, but perhaps this is good enough in practice. Change-Id: I78dec370e15c372284c934d9658b2dd5b3b97ae0
2018-06-08sw_redlinehide: trivial conversions in txthyph.cxxMichael Stahl1-15/+15
Change-Id: I6300ff1e6618f80c59bd97deeb4e850c5d2b1244
2018-04-12sw: fix some IWYU warningsMiklos Vajna1-0/+1
Change-Id: I0241707fcdf1d22131ce35fb64488fcf6d669675 Reviewed-on: https://gerrit.libreoffice.org/52750 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2017-10-07sw: always use "" for includes in current source's directoryMike Kaganski1-4/+4
Change-Id: Ida715fad0c4587a9566184180bf159da12470dd7 Reviewed-on: https://gerrit.libreoffice.org/43207 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2017-08-04loplugin:constparams in sw part4Noel Grandin1-1/+1
Change-Id: Ic42b2691869b61ba906222db893e284d8b9c39c1 Reviewed-on: https://gerrit.libreoffice.org/40767 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-25loplugin:unusedmethodsNoel Grandin1-1/+0
Change-Id: Ia874baf21257e5fe41e104211068a2bcc50446eb Reviewed-on: https://gerrit.libreoffice.org/40391 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-22loplugin:unusedfields in sw part4Noel Grandin1-3/+1
Change-Id: I1ffd51ab74b2ca809153f07f8de85e9c490749fd Reviewed-on: https://gerrit.libreoffice.org/39042 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-21loplugin:unusedfields in sw part5Noel Grandin1-4/+0
Change-Id: I4111ed1dcb04e010ecfb93df3a7e7bf715abf585 Reviewed-on: https://gerrit.libreoffice.org/39044 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-05Improved loplugin:cstylecast to reference types: swStephan Bergmann1-2/+2
Change-Id: I7206d3325b4bfedb852d559b68dc1678da524b41
2017-05-02tdf#39468: Translate German comments in sw/source/core/text/txthyph.cxxJens Carl1-19/+16
Change-Id: I55df1deaf3a44bb8be0225756761da2f7d2667aa Reviewed-on: https://gerrit.libreoffice.org/37095 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2017-04-25tdf#39468 Translate German comments sw/source/core/text/txthyph.cxxAlexey Vlasov1-3/+3
Change-Id: I2c818def66dcb04fabbffeb4c2ef1bdd1d2aa055 Reviewed-on: https://gerrit.libreoffice.org/36488 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2017-04-19SwBreakIt::m_xBreak is always availableCaolán McNamara1-2/+1
this all is a hold over from the initial tentitive changeover to using it in the first place Change-Id: I70e28023798d8ea637c61f9fac252bc698e8100d Reviewed-on: https://gerrit.libreoffice.org/36683 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-01-19tdf#105417 sw hyphenation: avoid infinite loop on zero-length last lineMiklos Vajna1-0/+5
This hang happened when the user executed Tools -> Language -> Hyphenation -> Hyphenate All. This problem is visible only if all of these conditions are met: - a line in a paragraph has a word that already contains a soft-hyphen, but not at the position where the automatic hyphenation would insert it - the last line ends with a word that can be hyphenated - there is a fly frame in the document In this case it happens during hyphenation that the layout has an additional empty line at the end (which is removed by the time the layout finishes), so we hit the case when SwTextFormatter::Hyphenate() skips the "if( m_pCurr->PrtWidth() && m_pCurr->GetLen() )" block. Normally hyphenation terminates when it iterates over the portions of the line and no overrun nor any existing hyphen portion are seen, but in this case that never happened. Fix the problem by terminating not only when we reach the end of the portion iteration, but also when the portion list is non-existing (has zero length). Change-Id: I71d4b040a2d4692ae6eb92807dbbbb42b077a0f8 Reviewed-on: https://gerrit.libreoffice.org/33303 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-04-30Fix typosAndrea Gelmini1-1/+1
Change-Id: Id81b16ff26283611f0b84929d831c827f847ab73 Reviewed-on: https://gerrit.libreoffice.org/24317 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2015-11-25bin/rename-sw-abbreviations.shlibreoffice-5-1-branch-pointRobinson Tryon1-9/+9
This commit renames the most annoying abbreviations in Writer (and partially in the shared code too). Change-Id: I77e5134f42f25e3786afa36b7a505c7e3237a9e8
2015-11-13sw: prefix members of SwTextIterMiklos Vajna1-10/+10
Kendy says this helps his latest changes to the bin/rename-sw-abbreviations.sh script. Change-Id: I95d82c5e8d69360e82154fa0390a6b2d1b9bf5d4
2015-11-10loplugin:nullptr (automatic rewrite)Stephan Bergmann1-2/+2
Change-Id: I01e11fa956a249974e77dce9deebe79311f098d0
2015-11-04loplugin:stringconstantNoel Grandin1-1/+1
Change-Id: Ic135382652966e80c288f3407508bdaf0c60316e
2015-06-29SwFrm::Calc: use vcl::RenderContextMiklos Vajna1-1/+2
Change-Id: I98de3f5413756c494c677d592ea921155e4c08be
2015-06-25SwTextFormatInfo::SwTextFormatInfo: use vcl::RenderContextMiklos Vajna1-1/+2
Change-Id: I8ff1647bdf8c46d395c398c97b97066d7b128cdb
2015-06-16Fix typosAndrea Gelmini1-1/+1
Change-Id: I528752dfabeb31d14c350f79819b521537ab9b56 Reviewed-on: https://gerrit.libreoffice.org/16300 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2015-05-20bin/rename-sw-abbreviations.shlibreoffice-5-0-branch-pointChristian Lohmaier1-52/+52
renames the most annoying abbreviations in Writer (and partially in the shared code too). Change-Id: I9a62759138126c1537cc5c985ba05cf54d6132d9
2015-05-12sw: let's try without a SwHyphPortion copy ctorMichael Stahl1-9/+8
It looks like it can be easily avoided. Change-Id: Ied8a047871c431b809569e1bbf232ce769d498ec
2015-05-08rename these scope lock guards, no logic changeCaolán McNamara1-1/+1
Change-Id: Ib1ec9c07ef38e22d739e80693eeb2d52e8e3b5f7
2015-01-27fdo#39468 Translate German comments - sw/source/core/textPhilipp Weissenbacher1-34/+40
Change-Id: Idee941019e87f4e132110adf566e432f99df79ce Reviewed-on: https://gerrit.libreoffice.org/14174 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-11-25loplugin: cstylecastNoel Grandin1-2/+2
Change-Id: I49d14ec4247984e78aafe90528c2919488233fe7
2014-11-24loplugin: cstylecastNoel Grandin1-2/+2
Change-Id: Ia3dc8efc8c8803597cbf226780bdb7e1c9681ee0
2014-10-29sw: prefix members of SwTxtInfoMichael Stahl1-1/+1
Change-Id: Ifd3a4e5f4b84b6f8a74e59a7bcdf8ddc35dfe408
2014-10-21fdo#39468 Translate German comments - sw/source/core/{unocore|text}Philipp Weissenbacher1-24/+28
Change-Id: Ib68eb94b296b002a8cd4e73dd6fd72a4f9d2f7d3 Reviewed-on: https://gerrit.libreoffice.org/12058 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-09-06sal_uInt16 to sal_Int32Matteo Casalin1-4/+2
Change-Id: Ib254f645718e461648a28ef0a9e0875a077b32f6
2014-09-06Avoid temporary OUStringsMatteo Casalin1-4/+2
Change-Id: If178bdbf13bbea3eb810267f207855bf6e2a6bda
2014-07-22Massive KSHORT/MSHORT to sal_uInt16Matteo Casalin1-5/+5
Change-Id: I82a899ef0cad19d62c41753ffdce07d8e33d6c9d
2014-06-24new compilerplugin returnbyrefNoel Grandin1-1/+1
Find places where we are returning a pointer to something, where we can be returning a reference. e.g. class A { struct X x; public X* getX() { return &x; } } which can be: public X& getX() { return x; } Change-Id: I796fd23fd36a18aedf6e36bc28f8fab4f518c6c7
2014-04-19Finish removing ASCII art from sw/source/core/textChris Laplante1-69/+7
Change-Id: If845234120236f35edb57c767b5debc046e85864 Reviewed-on: https://gerrit.libreoffice.org/9101 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2014-03-11"underflow" is one wordTor Lillqvist1-4/+4
Change-Id: I31db021b916b64e9fc0c02f62bdfe7e7f6aa7b9e
2014-02-27Remove visual noise from swAlexander Wilms1-3/+0
Conflicts: sw/inc/unodraw.hxx sw/inc/unoframe.hxx sw/sdi/swriter.sdi sw/source/core/unocore/unoframe.cxx sw/source/core/unocore/unoparagraph.cxx sw/source/filter/ww8/rtfexportfilter.cxx sw/source/ui/inc/unotxvw.hxx sw/source/ui/lingu/hyp.cxx sw/source/ui/lingu/sdrhhcwrap.cxx sw/source/ui/uno/swdetect.hxx Change-Id: Ic0a3fb2392187c277c9b36915ffb10dcf0317908 Reviewed-on: https://gerrit.libreoffice.org/8322 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-16sal_Bool to boolMatteo Casalin1-6/+6
Change-Id: I98da667e406aef18e0f8b8bdb9b380cf76b36952
2014-02-16sal_Bool to boolMatteo Casalin1-4/+4
Change-Id: I1a752ffcf023411bdbb8c983623cb93757fe9824