Skip to content

Commit aa5f25c

Browse files
BlackEgoistiText-CI
authored andcommitted
Add properties and default values for orphans and widows css support
DEVSIX-3664 Autoported commit. Original commit hash: [a9b9306d6]
1 parent 0a0530d commit aa5f25c

File tree

4 files changed

+10
-2
lines changed

4 files changed

+10
-2
lines changed

itext/itext.styledxmlparser/itext/styledxmlparser/css/CommonCssConstants.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,9 @@ static CommonCssConstants() {
300300
/// <summary>The Constant OPACITY.</summary>
301301
public const String OPACITY = "opacity";
302302

303+
/// <summary>The Constant OPRPHANS.</summary>
304+
public const String ORPHANS = "orphans";
305+
303306
/// <summary>The Constant OUTLINE.</summary>
304307
public const String OUTLINE = "outline";
305308

@@ -393,6 +396,9 @@ static CommonCssConstants() {
393396
/// <summary>The Constant WHITE_SPACE.</summary>
394397
public const String WHITE_SPACE = "white-space";
395398

399+
/// <summary>The Constant WIDOWS.</summary>
400+
public const String WIDOWS = "widows";
401+
396402
/// <summary>The Constant WIDTH.</summary>
397403
public const String WIDTH = "width";
398404

itext/itext.styledxmlparser/itext/styledxmlparser/css/resolve/CssDefaults.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,8 @@ static CssDefaults() {
119119
defaultValues.Put(CommonCssConstants.TEXT_DECORATION, CommonCssConstants.NONE);
120120
defaultValues.Put(CommonCssConstants.WHITE_SPACE, CommonCssConstants.NORMAL);
121121
defaultValues.Put(CommonCssConstants.WIDTH, CommonCssConstants.AUTO);
122+
defaultValues.Put(CommonCssConstants.ORPHANS, "2");
123+
defaultValues.Put(CommonCssConstants.WIDOWS, "2");
122124
}
123125

124126
// TODO not complete

itext/itext.styledxmlparser/itext/styledxmlparser/css/resolve/CssInheritance.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public class CssInheritance : IStyleInheritance {
7070
, CommonCssConstants.WRITING_MODE, CommonCssConstants.BORDER_COLLAPSE, CommonCssConstants.BORDER_SPACING
7171
, CommonCssConstants.CAPTION_SIDE, CommonCssConstants.EMPTY_CELLS, CommonCssConstants.LIST_STYLE, CommonCssConstants
7272
.LIST_STYLE_IMAGE, CommonCssConstants.LIST_STYLE_POSITION, CommonCssConstants.LIST_STYLE_TYPE, CommonCssConstants
73-
.QUOTES));
73+
.QUOTES, CommonCssConstants.ORPHANS, CommonCssConstants.WIDOWS));
7474

7575
// Color Properties
7676
// Basic Box Properties

port-hash

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
45100439dfb627839aaacaa874862cae01f84dda
1+
a9b9306d604b441a28373b83f8ea0e377e867b18

0 commit comments

Comments
 (0)