[gtk+] Another grid spacing reftest



commit 7b6e3be4a7165722d88f3c69f151d6969c01276b
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed May 11 19:51:26 2011 -0400

    Another grid spacing reftest
    
    This one checks that empty rows/columns don't affect layout.

 tests/reftests/Makefile.am          |    5 ++-
 tests/reftests/grid-spacing3.css    |    8 ++++
 tests/reftests/grid-spacing3.ref.ui |   76 ++++++++++++++++++++++++++++++++++
 tests/reftests/grid-spacing3.ui     |   77 +++++++++++++++++++++++++++++++++++
 4 files changed, 165 insertions(+), 1 deletions(-)
---
diff --git a/tests/reftests/Makefile.am b/tests/reftests/Makefile.am
index cf8a661..89b7a40 100644
--- a/tests/reftests/Makefile.am
+++ b/tests/reftests/Makefile.am
@@ -61,4 +61,7 @@ EXTRA_DIST += \
 	grid-spacing1.ref.ui \
 	grid-spacing1.ui \
 	grid-spacing2.ref.ui \
-	grid-spacing2.ui
+	grid-spacing2.ui \
+	grid-spacing3.ref.ui \
+	grid-spacing3.ui \
+	grid-spacing3.css
diff --git a/tests/reftests/grid-spacing3.css b/tests/reftests/grid-spacing3.css
new file mode 100644
index 0000000..9313662
--- /dev/null
+++ b/tests/reftests/grid-spacing3.css
@@ -0,0 +1,8 @@
+#red {
+  background-color: red;
+}
+
+#green {
+  background-color: green;
+}
+
diff --git a/tests/reftests/grid-spacing3.ref.ui b/tests/reftests/grid-spacing3.ref.ui
new file mode 100644
index 0000000..3576353
--- /dev/null
+++ b/tests/reftests/grid-spacing3.ref.ui
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkWindow" id="window1">
+    <property name="type">popup</property>
+    <property name="can_focus">False</property>
+    <child>
+      <object class="GtkGrid" id="grid1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="row-spacing">10</property>
+        <property name="column-spacing">5</property>
+        <child>
+          <object class="GtkEventBox" id="eventbox1">
+            <property name="name">red</property>
+            <property name="width_request">30</property>
+            <property name="height_request">30</property>
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">0</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkEventBox" id="eventbox2">
+            <property name="name">green</property>
+            <property name="width_request">30</property>
+            <property name="height_request">30</property>
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">0</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkEventBox" id="eventbox3">
+            <property name="name">green</property>
+            <property name="width_request">30</property>
+            <property name="height_request">30</property>
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">1</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkEventBox" id="eventbox4">
+            <property name="name">red</property>
+            <property name="width_request">30</property>
+            <property name="height_request">30</property>
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">1</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+      </object>
+    </child>
+  </object>
+</interface>
diff --git a/tests/reftests/grid-spacing3.ui b/tests/reftests/grid-spacing3.ui
new file mode 100644
index 0000000..6fc6ce4
--- /dev/null
+++ b/tests/reftests/grid-spacing3.ui
@@ -0,0 +1,77 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkWindow" id="window1">
+    <property name="type">popup</property>
+    <property name="can_focus">False</property>
+    <child>
+      <!-- test that empty extra rows/columns don't affect layout -->
+      <object class="GtkGrid" id="grid1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="row-spacing">10</property>
+        <property name="column-spacing">5</property>
+        <child>
+          <object class="GtkEventBox" id="eventbox1">
+            <property name="name">red</property>
+            <property name="width_request">30</property>
+            <property name="height_request">30</property>
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">0</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkEventBox" id="eventbox2">
+            <property name="name">green</property>
+            <property name="width_request">30</property>
+            <property name="height_request">30</property>
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">10</property>
+            <property name="top_attach">0</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkEventBox" id="eventbox3">
+            <property name="name">green</property>
+            <property name="width_request">30</property>
+            <property name="height_request">30</property>
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">10</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkEventBox" id="eventbox4">
+            <property name="name">red</property>
+            <property name="width_request">30</property>
+            <property name="height_request">30</property>
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">10</property>
+            <property name="top_attach">10</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+      </object>
+    </child>
+  </object>
+</interface>



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]