]> git.lyx.org Git - features.git/commit
Implement Row::Element::row_flags
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Sun, 11 Jul 2021 22:07:59 +0000 (00:07 +0200)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Tue, 23 Nov 2021 15:31:29 +0000 (16:31 +0100)
commita9858f70128acb253b7152204f44b395ab9d8370
tree9850f279ea87ed495503de54528fce631349632f
parente162d9179921594b5f45e57b80ae61596548eab1
Implement Row::Element::row_flags

Move the enum definition RowFlags in its own include file, to avoid
loading Inset.h. Document it more thoroughly.

Rename RowAfter to AlwaysBreakAfter.

Add CanBreakInside (rows that can be themselves broken). This allow to
differentiate elements before bodyPos() and allows to remove a
parameter to shortenIfNeeded().

Make the Inset::rowFlags() method return int instead of RowFlags, as
should be done for all the bitwise flags. Remove the hand-made bitwise
operators.

Set R::E::row_flags when creating elements.
* INSET elements use the inset's rowFLags();
* virtual element forbid breaking before them, and inherit the *After
  flags from the previous element of the row;
* STRING elements usr CanBreakInside, except before bodyPos.

More stuff may be added later.
28 files changed:
src/Makefile.am
src/Row.cpp
src/Row.h
src/RowFlags.h [new file with mode: 0644]
src/TextMetrics.cpp
src/insets/Inset.h
src/insets/InsetBibtex.h
src/insets/InsetCaption.h
src/insets/InsetFloatList.h
src/insets/InsetInclude.cpp
src/insets/InsetInclude.h
src/insets/InsetIndex.h
src/insets/InsetListings.cpp
src/insets/InsetListings.h
src/insets/InsetNewline.h
src/insets/InsetNewpage.h
src/insets/InsetNomencl.h
src/insets/InsetSeparator.h
src/insets/InsetSpace.cpp
src/insets/InsetSpace.h
src/insets/InsetSpecialChar.cpp
src/insets/InsetSpecialChar.h
src/insets/InsetTOC.h
src/insets/InsetTabular.cpp
src/insets/InsetTabular.h
src/insets/InsetVSpace.h
src/mathed/InsetMathHull.cpp
src/mathed/InsetMathHull.h