]> Pileus Git - ~andy/gtk/commitdiff
reftests: Add a CSS file to reset properties to default values
authorBenjamin Otte <otte@redhat.com>
Fri, 6 Jan 2012 22:27:46 +0000 (23:27 +0100)
committerBenjamin Otte <otte@redhat.com>
Mon, 9 Jan 2012 17:37:59 +0000 (18:37 +0100)
We can use this to be independant of themes. See the comment at the top
of the file

tests/reftests/Makefile.am
tests/reftests/reset-to-defaults.css [new file with mode: 0644]

index 058529d921290de8d20482b9d833829acd2d3795..27f0cf58dceda797b70e33c47090206634bd28cd 100644 (file)
@@ -163,6 +163,7 @@ EXTRA_DIST += \
        paned-undersized.ui \
        quit-mnemonic.ref.ui \
        quit-mnemonic.ui \
+       reset-to-defaults.css \
        rotated-layout.ref.ui \
        rotated-layout.ui \
        shorthand-entry-border.css \
diff --git a/tests/reftests/reset-to-defaults.css b/tests/reftests/reset-to-defaults.css
new file mode 100644 (file)
index 0000000..8af2a1f
--- /dev/null
@@ -0,0 +1,55 @@
+/* @import this colorsheet to get the default values for every property.
+ * This is useful when writing special CSS tests that should not be
+ * inluenced by themes - not even the default ones.
+ * Keep in mind that the output will be very ugly and not look like
+ * anything GTK.
+ * Also, when adding new style properties, please add them here.
+ */
+
+* {
+  color: inherit;
+  font-size: inherit;
+  background-color: initial;
+  font-family: inherit;
+  font-style: inherit;
+  font-variant: inherit;
+  font-weight: inherit;
+  text-shadow: inherit;
+  icon-shadow: inherit;
+  box-shadow: initial;
+  margin-top: initial;
+  margin-left: initial;
+  margin-bottom: initial;
+  margin-right: initial;
+  padding-top: initial;
+  padding-left: initial;
+  padding-bottom: initial;
+  padding-right: initial;
+  border-top-width: initial;
+  border-left-width: initial;
+  border-bottom-width: initial;
+  border-right-width: initial;
+  border-top-left-radius: initial;
+  border-top-right-radius: initial;
+  border-bottom-right-radius: initial;
+  border-bottom-left-radius: initial;
+  border-top-style: initial;
+  border-left-style: initial;
+  border-bottom-style: initial;
+  border-right-style: initial;
+  background-clip: initial;
+  background-origin: initial;
+  border-top-color: initial;
+  border-right-color: initial;
+  border-bottom-color: initial;
+  border-left-color: initial;
+  background-repeat: initial;
+  background-image: initial;
+  border-image-source: initial;
+  border-image-repeat: initial;
+  border-image-slice: initial;
+  border-image-width: initial;
+  engine: initial;
+  transition: initial;
+  gtk-key-bindings: initial;
+}