nsCSSPropLogicalGroupList.h 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. /* This Source Code Form is subject to the terms of the Mozilla Public
  2. * License, v. 2.0. If a copy of the MPL was not distributed with this
  3. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  4. /*
  5. * a list of groups of logical properties, for preprocessing
  6. */
  7. // A logical property group is one that defines the corresponding physical
  8. // longhand properties that could be set by a given set of logical longhand
  9. // properties. For example, the logical property group for margin-block-start
  10. // (and the other three logical margin properties) is one that contains
  11. // margin-top, margin-right, margin-bottom and margin-left.
  12. //
  13. // Logical property groups are defined below using one of the following
  14. // macros, where the name_ argument must be capitalized LikeThis and
  15. // must not collide with the name of a property's DOM method (its
  16. // method_ in nsCSSPropList.h):
  17. //
  18. // CSS_PROP_LOGICAL_GROUP_SHORTHAND(name_)
  19. // Defines a logical property group whose corresponding physical
  20. // properties are those in a given shorthand. For example, the
  21. // logical property group for margin-{block,inline}-{start,end}
  22. // is defined by the margin shorthand. The name_ argument must
  23. // be the method_ name of the shorthand (so Margin rather than
  24. // margin).
  25. //
  26. // CSS_PROP_LOGICAL_GROUP_BOX(name_)
  27. // Defines a logical property group whose corresponding physical
  28. // properties are a set of four box properties which are not
  29. // already represented by an existing shorthand property. For
  30. // example, the logical property group for
  31. // offset-{block,inline}-{start,end} contains the top, right,
  32. // bottom and left physical properties, but there is no shorthand
  33. // that sets those four properties. A table must be defined in
  34. // nsCSSProps.cpp named g<name_>LogicalGroupTable containing the
  35. // four physical properties in top/right/bottom/left order.
  36. //
  37. // CSS_PROP_LOGICAL_GROUP_AXIS(name_)
  38. // Defines a logical property group whose corresponding physical
  39. // properties are a set of two axis-related properties. For
  40. // example, the logical property group for {block,inline}-size
  41. // contains the width and height properties. A table must be
  42. // defined in nCSSProps.cpp named g<name_>LogicalGroupTable
  43. // containing the two physical properties in vertical/horizontal
  44. // order, followed by an nsCSSProperty_UNKNOWN entry.
  45. CSS_PROP_LOGICAL_GROUP_SHORTHAND(BorderColor)
  46. CSS_PROP_LOGICAL_GROUP_SHORTHAND(BorderStyle)
  47. CSS_PROP_LOGICAL_GROUP_SHORTHAND(BorderWidth)
  48. CSS_PROP_LOGICAL_GROUP_SHORTHAND(Margin)
  49. CSS_PROP_LOGICAL_GROUP_AXIS(MaxSize)
  50. CSS_PROP_LOGICAL_GROUP_BOX(Offset)
  51. CSS_PROP_LOGICAL_GROUP_SHORTHAND(Padding)
  52. CSS_PROP_LOGICAL_GROUP_AXIS(MinSize)
  53. CSS_PROP_LOGICAL_GROUP_AXIS(Size)