Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

What happened to <?scenebuilder-stylesheet ... > in Scene Builder 2?

ryanjaebNov 21 2014 — edited Nov 30 2014

Hi,

Did the way <?scenebuilder-stylesheet some-style.css?> works get changed in Scene Builder 2?  When I use Preview -- Scene Style Sheets -- Add a Style Sheet, I can't figure out where Scene Builder 2 is storing the info for the previewed style sheet.  When I commit the FXML file and check it out on another machine, all that information is lost.

What's the recommended way to deal with CSS for for files that are going to be included in other files using fx:include?  For example, assume I have 2 FXML files:

1) Main.fxml - A StackPane that includes Sub.fxml via fx:include.  Specifies main.css as a style sheet.

2) Sub.fxml - Uses styles from main.css, but no style sheet is attached directly.

It doesn't seem right to add main.css to both files.  If I remember correctly, Scene Builder 1 would use <?scenebuilder-stylesheet some-style.css?> to make this work, but it seems to be ignored in Scene Builder 2.  Can anyone suggest another way of doing what I want?

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 28 2014
Added on Nov 21 2014
3 comments
1,450 views