Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8120457

Possible CSS style propagation anamoly

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: P4 P4
    • 8
    • 7-pool
    • javafx

      In the following FXML example, the style set on the foo label is propagated to the bar label. Is this the expected result, given that the scene graph containment path is the same for both labels? [VBox->HBox>Label]

      The issue does not occur when the scene graph containment path is different (e.g. the "foo" label is in a VBox)


      <?xml version="1.0" encoding="UTF-8"?>

      <?import java.lang.*?>
      <?import javafx.scene.*?>
      <?import javafx.scene.control.*?>
      <?import javafx.scene.layout.*?>

      <VBox fx:controller="stylepropagationissue.Sample"
        xmlns:fx="http://javafx.com/fxml">
        <children>
          <HBox>
            <children>
              <Label text="Foo" style="-fx-font-size: 40pt;"/>
            </children>
          </HBox>
          <HBox>
            <children>
              <Label text="Bar" />
            </children>
          </HBox>
        </children>
      </VBox>

        1. Screen Shot 2013-12-11 at 11.30.40 AM.png
          11 kB
          David Grieve

            dgrieve David Grieve
            jweaver Jim Weaver (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: