[Libreoffice-commits] core.git: Changes to 'feature/sw_redlinehide_4b_for_libreoffice-6-2'

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Tue Dec 18 17:37:37 UTC 2018


New branch 'feature/sw_redlinehide_4b_for_libreoffice-6-2' available with the following commits:
commit ebe6d382fae5d4f3b3705f8bf1ff38ec8baa24f0
Author: Thorsten Behrens <Thorsten.Behrens at CIB.de>
Date:   Tue Dec 18 00:36:24 2018 +0100

    sw_redlinehide: fix tdf#113479 by removing nag dialog
    
    No need to suggest showing redlines beyond 250 changes anymore.
    
    Change-Id: Ia219a4eb3af64079979538b8ab4aaf2a94ec19c8

commit ef484241b75fdf642ae8f6d350b72c35e3a630fc
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Tue Dec 18 15:26:07 2018 +0100

    sw_redlinehide_4b: tdf#113479 SetRedlineFlags() calls no longer...
    
    ...able to be triggered by the UI, so the performance problem should be
    gone.
    
    The SwXTextDocument "ShowChanges" property allows API clients to call
    SetRedlineFlags() and change the model; this API should be retained
    as-is for now, because there is no way currently (outside of the rather
    specialised a11y API) to get a "merged view" of the paragraphs in the
    document, so API clients may want to (temporarily) toggle this property
    to then retrieve properties from the model.  In case we later find that
    there are no API clients that want to do such things, the property can
    be removed.
    
    A run with assert() instead of SAL_WARN_IF() found only 2 tests that
    explicitly call SetRedlineFlags() to clear ShowDelete.
    
    Change-Id: I44aee90f7727948ca0bbaaff9d04f8dd6b97cbd1

commit 794e08991577d3297d3de4bd11ea7895e9602af8
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Fri Nov 30 17:54:41 2018 +0100

    sw_redlinehide: make layout based Show/Hide mode the default
    
    remove ExperimentalMode checks
    
    Change-Id: Ie098eda0840bbd3231696cae43cc572ad61379fc
    (cherry picked from commit 32902f66e7749b2d06d13f50416be5323a0c0ea9)

commit 46d9e54203adc173bd5a0bbd16be0a8db1777458
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Wed Dec 5 16:37:18 2018 +0100

    sw_redlinehide_4b: temporarily add an assert that is wrong
    
    This assert is wrong, because there may be a legimate need to query
    a position that is currently hidden.
    
    However, oddly enough, we haven't found a legitimate document yet that
    triggers this, and it has pointed us to several interesting functions
    that needed adapting to merged frames... so keep it a little while and
    remove it (and return something other than COMPLETE_STRING from mapping
    functions) later...
    
    Change-Id: Ide2abf0c2ce054b75c917063a5d5aa8d13430426
    (cherry picked from commit b310378e874bc8fa7005352fcd85fa64eb075f54)

commit 0823b71bd6e5a488596c56593f39e9a05f3f3e51
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Mon Dec 17 21:46:13 2018 +0100

    sw_redlinehide_4b: ODF export: restore previous redline show flags
    
    There's a test for that, testRedlineFlags() in sw_globalfilter
    
    Change-Id: I9c821732910298d74271d95f0bfd0e902af84dbd
    (cherry picked from commit 7f42b4de3a5a72e695da0705ddc7db8bce576901)

commit 432b4f9977b4929e2a15c9d5bd33e463062eae86
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Mon Dec 17 19:39:22 2018 +0100

    sw_redlinehide_4b: export flag to flat-ODF
    
    Change-Id: Ief227f3f5b03ec186178f4d68c3a415969d65507
    (cherry picked from commit 5bc7fb209c0e6d7c6a46499d8c2e4d7abaa87bd7)

commit cd389f2f48f4e869cfb00361d7763518eb8b90f8
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Mon Dec 17 19:16:05 2018 +0100

    sw_redlinehide_4b: xmloff: destroy TextImportHelper before Model
    
    nullpointer in ~XMLRedlineImportHelper in
    SwUiWriterTest::testThreadedException()
    
    Change-Id: Ic4a79ceffa831aced4db47836333a15a13773887
    (cherry picked from commit 68d77adb2d8242588b416240e6f7d47940099aaa)

commit 32faa766ca3346126c87a8a8e1aeea3479051483
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Mon Dec 17 14:10:26 2018 +0100

    sw_redlinehide_4b: adapt FindFormat()
    
    Change-Id: I78cfca1cd629bf518f8294450a34ee228a360ef9
    (cherry picked from commit 87514172c1924492c33a8aa261b082f0ae7f9b48)

commit 8080861682088caf841ee761b031c20086e928af
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Mon Dec 17 13:13:46 2018 +0100

    sw_redlinehide_4b: adapt FindAttrImpl()
    
    * rename the only user, some UpdateFields() overload, to UpateOneField()
    * restrict it to search for non-formatting hints; the FindAttrsImpl()
      should be used for formatting hints instead
    
    Change-Id: I15002610a287fcdcd76777733a277d2ce64904bc
    (cherry picked from commit 1199902fc9cbf2cf51733f7bc4205d6c32d781d1)

commit 563a1f72fdb87d3a659149e1d3ffa0587194d6a7
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Thu Dec 13 15:49:10 2018 +0100

    sw_redlinehide_4b: adapt FindAttrs()
    
    Iterate over merged nodes, and iterate over extents in them, so the
    complex attribute-finding logic doesn't need to be changed.
    
    Change-Id: Id72ca9247165a0c93f0cf2a38b7a0249771ca2eb
    (cherry picked from commit 4caef398af256be5f0c2a159129b528ee3702e5c)

commit 22b480fc99d57752b43db89f40287e70777d4362
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Mon Dec 10 15:25:37 2018 +0100

    sw_redlinehide_4b: FindText() adapt the replace part as well
    
    When redlining is enabled, the result will be a delete redline for the
    existing text, and an insert redline for the new text; that much is
    obious (and ReplaceRange can deal with a selection larger than one
    SwTextNode easily, since it mostly adds redlines).
    
    For the case when redlining is disabled, there are 2 options,
    and i don't really know which is preferrable from UX point of view:
    
    One approach is to reuse GetRanges() to ignore delete redlines in
    the replace range; move its declaration to different header.
    
    Another approach is to DeleteAndJoin() the existing delete redlines,
    which is the same as the previous model based Hide mode,
    which calls DeleteRedline() to remove the hidden redlines.
    
    Also change ChgAutoCorrWord() to call DeleteSelImpl() directly.
    
    Change-Id: I5974409d09eb39e04cc0b5dfc20d4db510e1cf58
    (cherry picked from commit 5e81b966778d82692b4763d892b457186a7f269d)

commit 8abae4c68ab183add61332fc1d4c25fae4c269fd
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Tue Dec 4 15:57:47 2018 +0100

    sw_redlinehide_4b: adapt FindText()
    
    Generally speaking, the find functions should find the strings that are
    visible in the document view.  However, they may also be called from
    SwXTextDocument functions, where they ought to find the strings that are
    actually in the document model.
    
    So concoct some funny helper types and adapt this so it can handle both
    cases; it's not pretty but maybe it even works.
    
    Change-Id: I1917398ff928e922673353e75e8fb724dc042031
    (cherry picked from commit 77e67e7cd2baeca13c357fbda4c44a90db23de11)

commit 22703e9d63bf394fc561a705556d56891ede01f8
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Tue Dec 4 14:20:02 2018 +0100

    sw: refactor a confusing thicket of overloads, all named Find()
    
    Also, some of these don't really make much sense as member functions of
    SwPaM, so make them plain functions instead.
    
    Also, some pointer parameters are never null, but there is code to
    handle that case in MakeRegion(); simplify that.
    
    Change-Id: I822e814b0cab14f7f31cfa33478ed15774405a61
    (cherry picked from commit 92560b2d0149397ac5417522a37ce995691c7050)

commit a9ee8a09a353617061a376e10c56746813f06a6b
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Tue Dec 11 14:45:01 2018 +0100

    sw_redlinehide_4b: FrameMode::Existing is not idempotent
    
    ... so use it only once.  The problem is that the second time it will
    call DelFrames() on every non-first node, which then empties the first
    frame's newly created MergedPara instance.
    
    This can be reproduced by toggling Edit->Tracked Changes->Show in
    tdf99766-2.odt.
    
    Also change some function parameters on e.g. SwTextFootnote::DelFrames()
    to SwRootFrame to make it obvious that these don't actually need a
    particular SwTextFrame.
    
    Change-Id: I129be5db4a30546905c24c5e8820a5f105a33109
    (cherry picked from commit 1b4fdcf1b13c0be54cd4c4423122580948445069)

commit 3f831e1ad98f965fb03834d65014dbf878b2e480
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Tue Dec 11 13:18:56 2018 +0100

    sw_redlinehide_4b: SwRootFrame::SetHideRedlines() disable early return
    
    ... for now, because this is the only thing that deletes existing
    sw::MergedPara instances.
    
    Change-Id: If092df52e63de28de38129f0aa11ad08156855c4
    (cherry picked from commit 87cf3bcccf9ba72caf97b3e4c37120ab8fca305c)

commit 3ff270e79f522670df0573fb05bf6792a67b114c
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Tue Dec 11 13:16:10 2018 +0100

    sw_redlinehide_4b: fix wrong nTFIndex in UpdateMergedParaForInsert()
    
    The nTFIndex is used to insert into the merged string; the correct index
    is at the position corresponding to itInsert in the extents array.
    
    Once the itInsert is found, the nTFIndex is no longer used inside the
    loop, so just stop updating it.
    
    Change-Id: Idc073cc758bad42b0d8b44d15f0f8e732eeb2a25
    (cherry picked from commit bba571995d30967a74d67b7f2f3f4b65491a248a)

commit b93f5ad9fdeadd1941f416c56f6858a02f84d0bc
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Mon Dec 17 17:42:31 2018 +0100

    sw_redlinehide_4b: surprising discoveries
    
    It turns out that there was a small problem in the interpretation of
    sw_JoinText(), or rather, its caller,
    SwRangeRedline::DelCopyOfSection(), which, since about OOo 3.2 and
    i#100466, passes in bForceJoinNext, so the result is that the first node
    wins always, not just for RES_BREAK/RES_PAGEDESC items.
    
    This means that pParaPropsNode and pFirstNode are the same thing really.
    
    Another little problem is that the SwAttrIter was initing the font
    wrongly: the relevant items are the items in the *current* node's item
    set on top of the item set of the paragraph style, i.e. the *first*
    node's style.
    
    Simple reproducer: ooo79457-1.odt
    
    Change-Id: I06ef3c1695b8f3cdbded238864a60d5eb9ce4c44
    (cherry picked from commit c20308f1b919ca5ce61233068946e5fddb7eadb3)

commit 4093e9a3553111363258d8bdd06b42bc391b0a07
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Thu Dec 13 13:09:06 2018 +0100

    sw_redlinehide_4b: fix InsertCnt_() iteration of hidden tables
    
    The iteration was stopped as soon as the first start-node of a table
    cell was reached, because the SwTableNode case didn't skip over the
    table section in the nodes-array.  As seen in ooo67621-1.odt.
    
    It looks like the same problem can't happen with sections or flys
    because only tables have nested SwStartNodes and the Fly's nodes
    can hardly all be in a delete redline.
    
    Change-Id: Ib21a758c588d5dc8193ba171353f872de71bd65a
    (cherry picked from commit 8c708b6b1a7f0ee3ba97c0f2270b7f88f0495a15)

commit 9a3717df6861c068ca80af61f907ad24f64c63df
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Wed Dec 12 15:58:17 2018 +0100

    sw_redlinehide_4b: SwCursorShell::GotoRefMark() check visibility too
    
    As seen in ooo50225-1.sxw.
    
    Change-Id: I9f0bc0838cbf216b9a73e3ce6bc06b4340064077
    (cherry picked from commit c2d87f9f1b078271367d9afc9403a13087e79f5c)

commit 8114c6bd568d963282ffe272bb774c0080690caa
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Tue Dec 11 18:43:35 2018 +0100

    sw_redlinehide_4b: visibility checks for bookmarks too
    
    SwCursorShell::GotoMark(), GoNextBookmark(), GoPrevBookmark() check
    visibility of mark in layout.
    
    SwWrtShell::GotoMark() returns whether it was successful.
    
    EnhancedPDFExport skips marks that are not visible when creating links.
    
    Change-Id: I36c0706c18a5f861b15eaf451a97daec04104056
    (cherry picked from commit 943d9be770e550d20ca72274fa5e914d1f61e605)

commit 6fe4a41fa21cdd4fcf5e9ce6393975def6e6a6f0
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Tue Dec 11 17:29:44 2018 +0100

    sw_redlinehide_4b: visibility checks for EnhancedPDFExport links
    
    SwEnhancedPDFExportHelper should not create links to things that are
    hidden by the layout:
    
    * SwCursorShell::GotoFormatField() skips deleted fields
      (this triggers an assert in GetCharRect() with ooo69593-1.odt)
    
    * SwEditShell::GetINetAttrs() skips deleted INet attributes
      (which, as an additional bonus, hides then in the Navigator too)
    
    * SwDoc::GotoOutline() skips outline nodes where we know they have
      been deleted (as seen in ooo66088-9.odt)
    
    * SwFlyFrameFormats are skipped by EnhancedPDFExportHelper itself
    
    * footnotes dito
    
    Change-Id: Ife77dc7724688631d20cbaf8531b3c826a8ece94
    (cherry picked from commit 7d481f7ac1971be622520258a4b13ada29282844)

commit b82dcaabc5784181ecf297edb81fc7ef486e7b40
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Mon Dec 10 13:04:09 2018 +0100

    sw_redlinehide_4b: ODF import: drop empty delete redlines
    
    moz55970-4.odt has a delete redline containing
     <text:p text:style-name="Standard">
</text:p>
    which the silly whitespace normalisation of course imports as an empty
    SwTextNode.
    
    A delete redline containing no text (or at least a fly?) appears quite
    useless as the user can't do anything with it, so just delete it on import.
    
    Change-Id: I657eeb627235adf90d7d7c1e44f505e2c6eacd46
    (cherry picked from commit 59bdf21f4d933835e158b1f94f29d7b273a4b154)

commit 6d4397d4a7ed819ab9901efc127636414bd9d925
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Thu Dec 6 18:56:11 2018 +0100

    sw_redlinehide_4b: fix CanSkipOverRedline() using wrong start position
    
    It must use the start position that GetNextRedln() returned, not the
    start of the end redline that GetNextRedln() returned, obviously.
    
    This triggers an assert in CanSkipOverRedline() in ooo31961-27.odt.
    
    Change-Id: I40b9647e0b8be9768e49047d309dd22470e658bd
    (cherry picked from commit 4edc484b5fd76ba552923756d8c4e795dde6258d)

commit c9222f0788d64801471a0ac9005935bf64c1e782
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Thu Dec 6 18:39:10 2018 +0100

    sw_redlinehide_4b: fix pointer compares in SwRedlineItr::GetNextRedln()
    
    This is really stupid...
    
    Change-Id: I487ded0c0268ee9b7426e08109a9e8d447a0dfac
    (cherry picked from commit de551f0fca5cf25b0bdf62a7c373197332ce58be)

commit 986acf4f1337959206b2cbf789896a91e33ee346
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Thu Dec 6 12:32:20 2018 +0100

    sw_redlinehide_4b: fix some problems with pathological table redlines
    
    As seen in ooo95711-1.odt, the ODF import may create a redline that
    starts on a SwTableNode - though i haven't been able to figure out how
    such an odd creature might arise from UI actions.
    
    Try to fix the obvious places so we don't crash easily; there might be
    more trouble elsewhere though with code that assumes that a redline
    starts on a SwTextNode.
    
    Change-Id: I8431c1416ac4503ff0209a946398656f1c28366d
    (cherry picked from commit 63dba5203e8bc7fc390943cb8208ae904f18e3bb)

commit 9e3eececd5d828b0248ef3db863c30f4dc8910ae
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Wed Dec 5 16:49:34 2018 +0100

    sw_redlinehide_4b: fix crash in CanSkipOverRedline()
    
    This was another IsDelLastPara() redline in ooo27109-1.sxw.
    
    Change-Id: I1f4198a4bcbed7bdd52991af3cb3322ebacc65fe
    (cherry picked from commit 6364180490d350b95410693c170d3031a8aebede)

commit 1826ce088cd17c58d308aeebb51ebd5bda54ffb4
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Wed Dec 5 16:26:22 2018 +0100

    sw_redlinehide_4b: fix wrong handling of IsDelLastPara() redlines
    
    CheckParaRedlineMerge(): Fully deleted SwTextNode followed by a table,
    as seen in ooo81405-1.odt and ooo31961-16.sxw.
    
    Also avoid creating an extent for the node in which it starts,
    e.g. ooo31961-27.odt.
    
    Change-Id: I2a7d935a9cedcb66aeaa9dce418b1fab758f1784
    (cherry picked from commit 8af496c93328e4fee3972957e27b953fdb325bac)

commit cd2e94b49760a9b248764db25b0cfcc6aa7f44e4
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Wed Dec 5 15:24:55 2018 +0100

    sw_redlinehide_4b: consider the comments in the margin
    
    SwPostItMgr needs to hide the comments that are in delete redlines.
    
    Also notify SwPostItMgr when redlines are created/removed.
    
    SwPostItMgr is owned by the ViewShell but there is currently only one
    layout so SwRootFrame still needs to broadcast to all of them.
    
    Also an EndListening call was missing in
    SwPostItMgr::CheckForRemovedPostIts() which caused asserts.
    
    (cherry picked from commit 9b67b6a6d4b912f1e515d3884fa02c1be8aa6921)
    
    Change-Id: Ic0fccde50f6fdaa449afb535476c00c41ba94287

commit cb43cb2d075cc7e3aa9e93da3acb1caf93798606
Author: Michael Stahl <Michael.Stahl at cib.de>
Date:   Wed Dec 5 12:45:24 2018 +0100

    sw_redlinehide_4b: fix wrong assert in AppendObjs()
    
    Clearly this is wrong, the first node might be deleted; triggered e.g.
    by ooo69593-1.odt.
    
    Change-Id: I8f491372fcc375e68f2f7611924d8d4c7f673f17
    (cherry picked from commit e41374f64daf7b513842866cc2dcdfa3a9d3c0a5)



More information about the Libreoffice-commits mailing list