]> git.lyx.org Git - features.git/commit
Remove 'premature optimization' that proved buggy
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Wed, 3 Jan 2018 17:28:55 +0000 (18:28 +0100)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 5 Jan 2018 18:15:40 +0000 (19:15 +0100)
commit76f0a3dd4ee5c7958c6dea79628ef8c2ac2c59bd
tree1c0d215b968a279b1d4f2ee781b39f3ea62e6862
parent016393a0dd0a259655e0b3a44e8950f931d01486
Remove 'premature optimization' that proved buggy

At some time it seemed like a good idea in breakRow() to return early
when the row was bound to be empty. It turns out that this creates two
symptoms:

* empty paragraphs will not have an end of paragraph marker

* since row width is not correctly computed in this case, caret ghosts
  can appear in master.

This commit removes the oprimization and replace the do {} while()
construct to a straightforward while() {}.

Related to bug #10952.
src/TextMetrics.cpp