mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-26 13:41:07 +00:00
8ecd4e87e3
Add various tests for the change flag computation that we do in the css selector tree. test1: Just test the basic machinery of this test test2: Trigger every change flag at least once test3: Test that multiple states combine as expected test4: Test negations (known to produce wrong results) test5: Test a complex selector (not producing the expected output atm) widget-factory.ui: The real thing: widget-factory+Adwaita. Note that this expedts to be run with GSETTINGS_BACKEND=memory Note that test4 checks the wrong results that we currently produce for selectors involving :not. It will have to be updated when we fix the handling of :not. The widget-factory.ui testcase will certainly also be affected.
187 lines
1.9 KiB
CSS
187 lines
1.9 KiB
CSS
/* trigger all change flags at least once */
|
|
|
|
box {
|
|
color: green;
|
|
}
|
|
|
|
label {
|
|
color: green;
|
|
}
|
|
|
|
label.a:disabled {
|
|
color: blue;
|
|
}
|
|
|
|
label.b:selected {
|
|
color: blue;
|
|
}
|
|
|
|
label.c:backdrop {
|
|
color: blue;
|
|
}
|
|
|
|
label.d:focus {
|
|
color: blue;
|
|
}
|
|
|
|
label.e:first-child {
|
|
color: blue;
|
|
}
|
|
|
|
label.f:last-child {
|
|
color: blue;
|
|
}
|
|
|
|
label.g:nth-child(2) {
|
|
color: blue;
|
|
}
|
|
|
|
label.h:nth-last-child(2) {
|
|
color: blue;
|
|
}
|
|
|
|
label.i:hover {
|
|
color: blue;
|
|
}
|
|
|
|
label ~ label.j {
|
|
color: blue;
|
|
}
|
|
|
|
#label ~ label.j1 {
|
|
color: blue;
|
|
}
|
|
|
|
label.test ~ label.k {
|
|
color: blue;
|
|
}
|
|
|
|
label:hover ~ label.l {
|
|
color: blue;
|
|
}
|
|
|
|
label:disabled ~ label.m {
|
|
color: blue;
|
|
}
|
|
|
|
label:backdrop ~ label.n {
|
|
color: blue;
|
|
}
|
|
|
|
label:selected ~ label.o {
|
|
color: blue;
|
|
}
|
|
|
|
label:focus ~ label.p {
|
|
color: blue;
|
|
}
|
|
|
|
label:first-child ~ label.q {
|
|
color: blue;
|
|
}
|
|
|
|
label:last-child ~ label.r {
|
|
color: blue;
|
|
}
|
|
|
|
label:nth-child(2n+5) ~ label.s {
|
|
color: blue;
|
|
}
|
|
|
|
label:nth-last-child(2n+5) ~ label.t {
|
|
color: blue;
|
|
}
|
|
|
|
box label.u {
|
|
color: blue;
|
|
}
|
|
|
|
#box label.u1 {
|
|
color: blue;
|
|
}
|
|
|
|
box.test label.v {
|
|
color: blue;
|
|
}
|
|
|
|
box:focus label.w {
|
|
color: blue;
|
|
}
|
|
|
|
box:hover label.x {
|
|
color: blue;
|
|
}
|
|
|
|
box:disabled label.y {
|
|
color: blue;
|
|
}
|
|
|
|
box:backdrop label.z {
|
|
color: blue;
|
|
}
|
|
|
|
box:selected label.aa {
|
|
color: blue;
|
|
}
|
|
|
|
box:first-child label.bb {
|
|
color: blue;
|
|
}
|
|
|
|
box:last-child label.cc {
|
|
color: blue;
|
|
}
|
|
|
|
box:nth-child(3) label.dd {
|
|
color: blue;
|
|
}
|
|
|
|
box:nth-last-child(3) label.ee {
|
|
color: blue;
|
|
}
|
|
|
|
box~box label.ff {
|
|
color: blue;
|
|
}
|
|
|
|
#box1~box label.gg {
|
|
color: blue;
|
|
}
|
|
|
|
box.test~box label.hh {
|
|
color: blue;
|
|
}
|
|
|
|
box:focus~box label.ii {
|
|
color: blue;
|
|
}
|
|
|
|
box:hover~box label.jj {
|
|
color: blue;
|
|
}
|
|
|
|
box:backdrop~box label.kk {
|
|
color: blue;
|
|
}
|
|
|
|
box:selected~box label.ll {
|
|
color: blue;
|
|
}
|
|
|
|
box:first-child~box label.mm {
|
|
color: blue;
|
|
}
|
|
|
|
box:last-child~box label.nn {
|
|
color: blue;
|
|
}
|
|
|
|
box:nth-child(2)~box label.oo {
|
|
color: blue;
|
|
}
|
|
|
|
box:nth-last-child(2)~box label.pp {
|
|
color: blue;
|
|
}
|
|
|