#ifndef RenderStyleConstants_h
#define RenderStyleConstants_h
-namespace WebCore {
+namespace blink {
enum StyleRecalcChange {
NoChange,
PrintColorAdjustExact
};
-// When some style properties change, different amounts of work have to be done depending on
-// context (e.g. whether the property is changing on an element which has a compositing layer).
-// A simple StyleDifference does not provide enough information so we return a bit mask of
-// StyleDifferenceContextSensitiveProperties from RenderStyle::visualInvalidationDiff() too.
-enum StyleDifferenceContextSensitiveProperty {
- ContextSensitivePropertyNone = 0,
- ContextSensitivePropertyTransform = (1 << 0),
- ContextSensitivePropertyOpacity = (1 << 1),
- ContextSensitivePropertyZIndex = (1 << 2),
- ContextSensitivePropertyFilter = (1 << 3),
- // The object needs to be repainted if it contains text or properties dependent on color (e.g., border or outline).
- ContextSensitivePropertyTextOrColor = (1 << 4)
-};
-
// Static pseudo styles. Dynamic ones are produced on the fly.
enum PseudoId {
// The order must be NOP ID, public IDs, and then internal IDs.
StaticPosition = 0,
RelativePosition = 1,
AbsolutePosition = 2,
- StickyPosition = 3,
// This value is required to pack our bits efficiently in RenderObject.
+ // FIXME: Is this still true now that we've remove position: sticky.
FixedPosition = 6
};
enum TextUnderlinePosition {
// FIXME: Implement support for 'under left' and 'under right' values.
- TextUnderlinePositionAuto = 0x1,
- TextUnderlinePositionUnder = 0x2
+ TextUnderlinePositionAuto,
+ TextUnderlinePositionUnder
};
enum EPageBreak {
enum TextOverflow { TextOverflowClip = 0, TextOverflowEllipsis };
-enum EImageRendering { ImageRenderingAuto, ImageRenderingOptimizeSpeed, ImageRenderingOptimizeQuality, ImageRenderingOptimizeContrast };
+enum EImageRendering { ImageRenderingAuto, ImageRenderingOptimizeSpeed, ImageRenderingOptimizeQuality, ImageRenderingOptimizeContrast, ImageRenderingPixelated };
enum ImageResolutionSource { ImageResolutionSpecified = 0, ImageResolutionFromImage };
enum RubyPosition { RubyPositionBefore, RubyPositionAfter };
-enum GridAutoFlow { AutoFlowNone, AutoFlowColumn, AutoFlowRow };
+static const size_t GridAutoFlowBits = 5;
+enum InternalGridAutoFlowAlgorithm {
+ InternalAutoFlowAlgorithmSparse = 0x1,
+ InternalAutoFlowAlgorithmDense = 0x2,
+ InternalAutoFlowAlgorithmStack = 0x4
+};
+
+enum InternalGridAutoFlowDirection {
+ InternalAutoFlowDirectionRow = 0x8,
+ InternalAutoFlowDirectionColumn = 0x10
+};
+
+enum GridAutoFlow {
+ AutoFlowRow = InternalAutoFlowAlgorithmSparse | InternalAutoFlowDirectionRow,
+ AutoFlowColumn = InternalAutoFlowAlgorithmSparse | InternalAutoFlowDirectionColumn,
+ AutoFlowRowDense = InternalAutoFlowAlgorithmDense | InternalAutoFlowDirectionRow,
+ AutoFlowColumnDense = InternalAutoFlowAlgorithmDense | InternalAutoFlowDirectionColumn,
+ AutoFlowStackRow = InternalAutoFlowAlgorithmStack | InternalAutoFlowDirectionRow,
+ AutoFlowStackColumn = InternalAutoFlowAlgorithmStack | InternalAutoFlowDirectionColumn
+};
enum DraggableRegionMode { DraggableRegionNone, DraggableRegionDrag, DraggableRegionNoDrag };
ItemPositionAuto,
ItemPositionStretch,
ItemPositionBaseline,
+ ItemPositionLastBaseline,
ItemPositionCenter,
ItemPositionStart,
ItemPositionEnd,
OverflowAlignmentSafe
};
+enum ItemPositionType {
+ NonLegacyPosition,
+ LegacyPosition
+};
+
// Reasonable maximum to prevent insane font sizes from causing crashes on some platforms (such as Windows).
static const float maximumAllowedFontSize = 1000000.0f;
enum CSSBoxType { BoxMissing = 0, MarginBox, BorderBox, PaddingBox, ContentBox };
-} // namespace WebCore
+} // namespace blink
#endif // RenderStyleConstants_h