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

stylesheet css with number arguments fails with a conversion exception

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P1
    • Resolution: Fixed
    • Affects Version/s: fx1.1
    • Fix Version/s: fx1.1
    • Component/s: javafx
    • Environment:

      netbeans with latest franca SDK

      Description

      the following exception is thrown when using a "number" argument in a stylesheet. Attached sample is based on the customcontrol sample in baloo. attached sample project for ease of duplication.
      compile:
      jar:
      standard-run:
      java.lang.ClassCastException: java.lang.Double
              at com.sun.javafx.runtime.location.FloatVariable.set(FloatVariable.java:38)
              at javafx.reflect.FXLocal$VarMember.setValue(FXLocal.java:729)
              at com.sun.stylesheet.javafx.Attribute.setProperty(Attribute.java:153)
              at com.sun.stylesheet.javafx.FXObjectStyleSupport.setProperty(FXObjectStyleSupport.java:342)
              at com.sun.stylesheet.styleable.DefaultStyleable.setProperty(DefaultStyleable.java:168)
              at com.sun.stylesheet.PropertyManager.applyProperty(PropertyManager.java:594)
              at com.sun.stylesheet.PropertyManager.applyProperty(PropertyManager.java:555)
              at com.sun.stylesheet.Declaration.applyTo(Declaration.java:91)
              at com.sun.stylesheet.Rule.applyTo(Rule.java:221)
              at com.sun.stylesheet.Stylesheet.applyTo(Stylesheet.java:277)
              at com.sun.stylesheet.Stylesheet.applyTo(Stylesheet.java:282)
              at com.sun.stylesheet.Stylesheet.applyTo(Stylesheet.java:257)
              at javafx.scene.Scene.applyStylesheets$impl(Scene.fx:235)
              at javafx.scene.Scene.applyStylesheets(Scene.fx:43)
              at javafx.scene.Scene.userInit$(Scene.fx:220)
              at javafx.scene.Scene.initialize$(Scene.fx:43)
              at customcontrol.Main.javafx$run$(Main.fx:21)
              at customcontrol.Main.javafx$run$(Main.fx:21)
      browser-run:

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              rbair Richard Bair (Inactive)
              Reporter:
              mburtonjfx Mark M Burton (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported: