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

label.setStyle does not honor colors

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Not an Issue
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: javafx
    • Labels:

      Description

      If you invoke
      label.setStyle("color:rgb(100%,0%,0%);-fx-font: 80px \"Serif\"");
      the font changes as expected, but the red color setting has no effect. I have tried a large number of ways to do this, including using rgba values and using integer values instead of percentages - it just does not seem to work.

      As mentioned in another issue, this bug is problematic because Label does not support a setColor method either, so there is no way I can calculate a color for a weather forecast headline based on todays temperature.

        Attachments

          Activity

            People

            • Assignee:
              leifs Leif Samuelsson (Inactive)
              Reporter:
              risaksen Randahl Isaksen
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Imported: