summaryrefslogtreecommitdiffstats
path: root/servo/components/style/properties/longhands/xul.mako.rs
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
commit26a029d407be480d791972afb5975cf62c9360a6 (patch)
treef435a8308119effd964b339f76abb83a57c29483 /servo/components/style/properties/longhands/xul.mako.rs
parentInitial commit. (diff)
downloadfirefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz
firefox-26a029d407be480d791972afb5975cf62c9360a6.zip
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'servo/components/style/properties/longhands/xul.mako.rs')
-rw-r--r--servo/components/style/properties/longhands/xul.mako.rs85
1 files changed, 85 insertions, 0 deletions
diff --git a/servo/components/style/properties/longhands/xul.mako.rs b/servo/components/style/properties/longhands/xul.mako.rs
new file mode 100644
index 0000000000..8974ac30dc
--- /dev/null
+++ b/servo/components/style/properties/longhands/xul.mako.rs
@@ -0,0 +1,85 @@
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at https://mozilla.org/MPL/2.0/. */
+
+<%namespace name="helpers" file="/helpers.mako.rs" />
+<% from data import Method %>
+
+// Non-standard properties that Gecko uses for XUL elements.
+<% data.new_style_struct("XUL", inherited=False) %>
+
+${helpers.single_keyword(
+ "-moz-box-align",
+ "stretch start center baseline end",
+ engines="gecko",
+ gecko_ffi_name="mBoxAlign",
+ gecko_enum_prefix="StyleBoxAlign",
+ animation_value_type="discrete",
+ aliases="-webkit-box-align",
+ spec="Nonstandard (https://developer.mozilla.org/en-US/docs/Web/CSS/box-align)",
+ affects="layout",
+)}
+
+${helpers.single_keyword(
+ "-moz-box-direction",
+ "normal reverse",
+ engines="gecko",
+ gecko_ffi_name="mBoxDirection",
+ gecko_enum_prefix="StyleBoxDirection",
+ animation_value_type="discrete",
+ aliases="-webkit-box-direction",
+ spec="Nonstandard (https://developer.mozilla.org/en-US/docs/Web/CSS/box-direction)",
+ affects="layout",
+)}
+
+${helpers.predefined_type(
+ "-moz-box-flex",
+ "NonNegativeNumber",
+ "From::from(0.)",
+ engines="gecko",
+ gecko_ffi_name="mBoxFlex",
+ animation_value_type="NonNegativeNumber",
+ aliases="-webkit-box-flex",
+ spec="Nonstandard (https://developer.mozilla.org/en-US/docs/Web/CSS/box-flex)",
+ affects="layout",
+)}
+
+${helpers.single_keyword(
+ "-moz-box-orient",
+ "horizontal vertical",
+ engines="gecko",
+ gecko_ffi_name="mBoxOrient",
+ gecko_aliases="inline-axis=horizontal block-axis=vertical",
+ gecko_enum_prefix="StyleBoxOrient",
+ animation_value_type="discrete",
+ aliases="-webkit-box-orient",
+ spec="Nonstandard (https://developer.mozilla.org/en-US/docs/Web/CSS/box-orient)",
+ affects="layout",
+)}
+
+${helpers.single_keyword(
+ "-moz-box-pack",
+ "start center end justify",
+ engines="gecko",
+ gecko_ffi_name="mBoxPack",
+ gecko_enum_prefix="StyleBoxPack",
+ animation_value_type="discrete",
+ aliases="-webkit-box-pack",
+ spec="Nonstandard (https://developer.mozilla.org/en-US/docs/Web/CSS/box-pack)",
+ affects="layout",
+)}
+
+// NOTE(heycam): Odd that the initial value is 1 yet 0 is a valid value. There
+// are uses of `-moz-box-ordinal-group: 0` in the tree, too.
+${helpers.predefined_type(
+ "-moz-box-ordinal-group",
+ "Integer",
+ "1",
+ engines="gecko",
+ parse_method="parse_non_negative",
+ aliases="-webkit-box-ordinal-group",
+ gecko_ffi_name="mBoxOrdinal",
+ animation_value_type="discrete",
+ spec="Nonstandard (https://developer.mozilla.org/en-US/docs/Web/CSS/-moz-box-ordinal-group)",
+ affects="layout",
+)}