* SOLVED *
Since the day I initialy posted this, I kept doing my research and found the problem, along with a solution...
Please see Post #23
******************************************************
Hi guys...
I guess this one is straight to @Erel !
I am "Theming" my app using an external css file. I have managed to style every components I targeted by setting the view's ID value, and then refering to it in the css file.
But Panes.... are very peculiar....
In JavaFX there are a few Pane types/definitions.
Please correct me if I am wrong, but this is what I found so far...
B4J AchorPane - JFX AnchorPane this is our form "root", it makes sense since views can be anchored (?)
B4J ScrollPane - JFX ScrollPane
B4J SplitPane - JFX SplitPane
B4J TabPane - JFX TabPane
and....
B4J Pane - anyweresoftware.b4j.controls.PaneWrapper$ConcretePaneWrapper$NonResizePane (......) What ??????? (I found this info using Scenic View.)
Why is this important to me?
I am trying a very trivial thing, using my external css file... create a border on a pane... It just doesn't work!!!
-fx-border-color: red ;
-fx-border-width: 5 ;
HOWEVER.... the same css lines, used directly in the visual designer. extra css field... They work!! My guess is that by putting then there, either they are used directly by a setStyle issued when initializing the view, either they are targeting the JFX class directly.
The only difference I see in behaviour between all these Panes, in relation to B4J Pane, is that in the visual designer, none of then can have children, while B4J Pane can.
I also found that the border settings seem to be the only ones not working as they should.
If I set a Pane's ID and use it in my css file, all other properties seem to be correctly applied.
So.... This is weird to classify... it's a bug... but... or is it actually just a missing parameter/feature?
[EDIT]
I continued testing... all results point to a StyleSheet wide class atribuition BUG....
It seems that, when using an external stylesheet file, not all properties are correctly parsed, specially the Border related ones.
However, the exact same lines when used in the extra css visual designer field or used in code by setting the inline style string, they work perfectly.
It is possible to work around this, if you don't want any degree of transparency on your views background, as I was trying to achieve, by using the background color along with insets.
Since the day I initialy posted this, I kept doing my research and found the problem, along with a solution...
Please see Post #23
******************************************************
Hi guys...
I guess this one is straight to @Erel !
I am "Theming" my app using an external css file. I have managed to style every components I targeted by setting the view's ID value, and then refering to it in the css file.
But Panes.... are very peculiar....
In JavaFX there are a few Pane types/definitions.
Please correct me if I am wrong, but this is what I found so far...
B4J AchorPane - JFX AnchorPane this is our form "root", it makes sense since views can be anchored (?)
B4J ScrollPane - JFX ScrollPane
B4J SplitPane - JFX SplitPane
B4J TabPane - JFX TabPane
and....
B4J Pane - anyweresoftware.b4j.controls.PaneWrapper$ConcretePaneWrapper$NonResizePane (......) What ??????? (I found this info using Scenic View.)
Why is this important to me?
I am trying a very trivial thing, using my external css file... create a border on a pane... It just doesn't work!!!
-fx-border-color: red ;
-fx-border-width: 5 ;
HOWEVER.... the same css lines, used directly in the visual designer. extra css field... They work!! My guess is that by putting then there, either they are used directly by a setStyle issued when initializing the view, either they are targeting the JFX class directly.
The only difference I see in behaviour between all these Panes, in relation to B4J Pane, is that in the visual designer, none of then can have children, while B4J Pane can.
I also found that the border settings seem to be the only ones not working as they should.
If I set a Pane's ID and use it in my css file, all other properties seem to be correctly applied.
So.... This is weird to classify... it's a bug... but... or is it actually just a missing parameter/feature?
[EDIT]
I continued testing... all results point to a StyleSheet wide class atribuition BUG....
It seems that, when using an external stylesheet file, not all properties are correctly parsed, specially the Border related ones.
However, the exact same lines when used in the extra css visual designer field or used in code by setting the inline style string, they work perfectly.
It is possible to work around this, if you don't want any degree of transparency on your views background, as I was trying to achieve, by using the background color along with insets.
Last edited: