T ToolboxZX Member Licensed User Longtime User Jul 22, 2016 #1 How does one go about changing a textarea so that it has a black background and a white font? Can this be done using the designer and if so how?
How does one go about changing a textarea so that it has a black background and a white font? Can this be done using the designer and if so how?
Erel B4X founder Staff member Licensed User Longtime User Jul 24, 2016 #2 You can set the background color and then add this text to the extra CSS field: -fx-text-fill: white; Upvote 0
You can set the background color and then add this text to the extra CSS field: -fx-text-fill: white;
T ToolboxZX Member Licensed User Longtime User Jul 25, 2016 #3 Erel said: You can set the background color and then add this text to the extra CSS field: -fx-text-fill: white; Click to expand... Thanks! That took care of obtaining a white font and a black background However is there some additional code that needs to be added to the extra CSS line, so that when this field receives focus, the background stays black and doesn't turn blue? That seems to happen when I am just updating the field with text programmatically Upvote 0
Erel said: You can set the background color and then add this text to the extra CSS field: -fx-text-fill: white; Click to expand... Thanks! That took care of obtaining a white font and a black background However is there some additional code that needs to be added to the extra CSS line, so that when this field receives focus, the background stays black and doesn't turn blue? That seems to happen when I am just updating the field with text programmatically
Erel B4X founder Staff member Licensed User Longtime User Jul 26, 2016 #4 This will require using a CSS file. See the answer here: http://stackoverflow.com/questions/26651198/how-to-remove-this-gray-top-border-in-javafx-textarea Example of using CSS file: https://www.b4x.com/android/forum/threads/css-example.35854/#content Upvote 0
This will require using a CSS file. See the answer here: http://stackoverflow.com/questions/26651198/how-to-remove-this-gray-top-border-in-javafx-textarea Example of using CSS file: https://www.b4x.com/android/forum/threads/css-example.35854/#content
T ToolboxZX Member Licensed User Longtime User Jul 27, 2016 #5 Erel said: This will require using a CSS file. See the answer here: http://stackoverflow.com/questions/26651198/how-to-remove-this-gray-top-border-in-javafx-textarea Example of using CSS file: https://www.b4x.com/android/forum/threads/css-example.35854/#content Click to expand... Thank you again for your quick reply on this subject Erel! Actually, doing some additional hunting around I was able to achieve this by adding some additional code in the extra CSS field, beyond the "-fx-text-fill: white;" value. Just out of curiosity, since the example referenced for using CSS requires use of the deprecated Scene Builder, do you have any plans for adding any features to the more modern internal designer? In B4J 4.20, the Scene Builder did not come up for me when attempting to edit the file, so I thought perhaps you removed it in preparation for something better Upvote 0
Erel said: This will require using a CSS file. See the answer here: http://stackoverflow.com/questions/26651198/how-to-remove-this-gray-top-border-in-javafx-textarea Example of using CSS file: https://www.b4x.com/android/forum/threads/css-example.35854/#content Click to expand... Thank you again for your quick reply on this subject Erel! Actually, doing some additional hunting around I was able to achieve this by adding some additional code in the extra CSS field, beyond the "-fx-text-fill: white;" value. Just out of curiosity, since the example referenced for using CSS requires use of the deprecated Scene Builder, do you have any plans for adding any features to the more modern internal designer? In B4J 4.20, the Scene Builder did not come up for me when attempting to edit the file, so I thought perhaps you removed it in preparation for something better
Erel B4X founder Staff member Licensed User Longtime User Jul 27, 2016 #6 ToolboxZX said: Just out of curiosity, since the example referenced for using CSS requires use of the deprecated Scene Builder, do you have any plans for adding any features to the more modern internal designer Click to expand... I've updated the example to be based on the internal designer: https://www.b4x.com/android/forum/threads/css-example.35854/#content Upvote 0
ToolboxZX said: Just out of curiosity, since the example referenced for using CSS requires use of the deprecated Scene Builder, do you have any plans for adding any features to the more modern internal designer Click to expand... I've updated the example to be based on the internal designer: https://www.b4x.com/android/forum/threads/css-example.35854/#content