summaryrefslogtreecommitdiffstats
path: root/layout/style/nsStyleStruct.h
diff options
context:
space:
mode:
authorMoonchild <moonchild@palemoon.org>2020-10-03 14:52:47 +0000
committerMoonchild <moonchild@palemoon.org>2020-10-06 09:31:51 +0000
commit17b4d049f487c412ed319e81de6d49a7d07d0f44 (patch)
tree7320ebee8b132eecc73644021aa8e6b09c6ab5ef /layout/style/nsStyleStruct.h
parentabf1d5a099ea8c3fbd6912ff7b199791994cb932 (diff)
downloadUXP-17b4d049f487c412ed319e81de6d49a7d07d0f44.tar
UXP-17b4d049f487c412ed319e81de6d49a7d07d0f44.tar.gz
UXP-17b4d049f487c412ed319e81de6d49a7d07d0f44.tar.lz
UXP-17b4d049f487c412ed319e81de6d49a7d07d0f44.tar.xz
UXP-17b4d049f487c412ed319e81de6d49a7d07d0f44.zip
Issue #1666 - Implement overflow-wrap: anywhere
This aligns with the current spec regarding overflow-wrap: break-word and overflow-wrap: anywhere in if it affects intrinsic sized due to considering soft-wrap opportunities or not. See CSS Text Module Level 3, Editor’s Draft, 1 October 2020, Section 5.5
Diffstat (limited to 'layout/style/nsStyleStruct.h')
-rw-r--r--layout/style/nsStyleStruct.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/layout/style/nsStyleStruct.h b/layout/style/nsStyleStruct.h
index f49cdc43e..cca7bb8d4 100644
--- a/layout/style/nsStyleStruct.h
+++ b/layout/style/nsStyleStruct.h
@@ -2134,8 +2134,11 @@ struct MOZ_NEEDS_MEMMOVABLE_MEMBERS nsStyleText
}
bool WordCanWrapStyle() const {
- return WhiteSpaceCanWrapStyle() &&
- mOverflowWrap == NS_STYLE_OVERFLOWWRAP_BREAK_WORD;
+ if (!WhiteSpaceCanWrapStyle()) {
+ return false;
+ }
+ return (mOverflowWrap == NS_STYLE_OVERFLOWWRAP_BREAK_WORD ||
+ mOverflowWrap == NS_STYLE_OVERFLOWWRAP_ANYWHERE);
}
bool HasTextEmphasis() const {