JackCody :
I'm working on JavaFx
trying to round the corner of Textarea just like the area of typing message on the WhatsApp
I did try with setStyle for all focus and background; border color, faint
TextArea area=new TextArea();
area.setStyle( "-fx-region-background: null;"
+ "-fx-text-box-border: transparent;"
+ "-fx-text-fill:black;"
+ "-fx-border-color:#c6c6c6;"
+ " -fx-border-width: 2;"
+ "-fx-border-radius: 30;"
+ "-fx-control-inner-background: transparent;"
+ "-fx-focus-color: transparent;"
+ "-fx-faint-focus-color: transparent;");
this a snap of what I get if i run the code i did succeed to rounded the textarea but sound like still there is a box on the front if you notice the four angles
sound like there is triangle box on front how to remove the border of that triangle
Matt :
This is what worked for me give it a shot let me know if thats not what your looking for
Here is how to do it with a CSS file
.text-area {
-fx-background-color: transparent;
-fx-background-radius: 15;
-fx-border-radius: 15;
-fx-border-width: 2;
-fx-border-color: #c6c6c6;
}
.text-area {
-fx-background-color: transparent;
}
.text-area .viewport{
-fx-background-color: transparent;
}
.text-area .content{
-fx-background-color: transparent;
}