Styling javafx alertbox without css strings - javafx

How can I change JavaFX alertbox background without using css strings?. I mean something like Node.setStyle(-fx-background-color: red;)

Related

ripple effect issue with materialize css

I am using materialize-css library in angular. Along with the materialize-css I am using materialize-stepper library that is based on the materialize-css.
MaterializeCSS uses .waves-effect CSS class to provide ripple effect on buttons, a tag and on all other clickables.
materialize-stepper also uses the .waves-effect. When I click on the node with .waves-effect class it appends a div having the ripple effect. Problem is on the next click it adds one new div with ripple effect. So it makes the clickable button or node with dark background (step 2) as this does not remove existing div.
what could be the possible issue?

Open accordeon pane in Materialize CSS based on screensize

In materialize CSS, I can open a pane by adding a class active to the one I want opened. Is there also a way to let this be dependent of the current grid breakpoint? For instance using something like active-lg?
Otherwise, is there an option through javascript to get the current breakpoint (S/M/L/XL) from materialize CSS?

Qt Designer button image change while keeping windows style?

I can change the image or any other style of a QPushButton in the designer by changing the stylesheet, but any change in the style sheet changes all the other properties.
For instance, when I change the border image everything else is changed and it does not inherit the rest of the properties from the parent (or windows style).
How can I keep the windows style while changing only the image?
From How can I set Styles to a QTabwidget without overwriting existing styles in QT ?:
A style sheet is all or nothing. so if u all apply style sheet, it
might sort of reset the look for some widgets and to fix that, you
must supply a full stylesheet.
The key parts are:
A style sheet is all or nothing.
you must supply a full stylesheet.
You can set an image for the QPushButton from the code or by using QtDesigner like this:
Select the button
In the properties window set the image and the
size (properties icon and iconSize).
Did you try set style to the single push button:
your_push_button_pointer->setStyleSheet(
"QPushButton{background-image: url(:/images/call_up.bmp);}"
"QPushButton:hover{background-image: url(:/images/call_hov.bmp);}"
"QPushButton:pressed{background-image: url(:/images/call_down.bmp);}");

How to apply styles to a group of Labels in javafx without css

I have a javaFx VBox named countVBox in which a append Labels on the click of a button. Now with css, I can do:
.countVBox .label {
-fx-background-color: #0000ff;
}
I want to achieve the same effect - making the label's background colour blue after it is appended, but without using css. Please tell me if it's possible. Thanks. I am using javafx 2.2
You can access the background of a region (such as a label), using the getBackground() API. Once you have a background, there are methods on the background which will allow you to manipulate it via code.
In most cases I'd recommend using CSS (in a stylesheet) over manipulating the region background in Java code.
See also:
In JavaFX, should I use CSS or setter methods to change properties on my UI Nodes?

make textbox not to inherit any css

I want to create a textbox to make a loginform. But there is alot of css on it that i don't want to use. Im also using bootstrap so there is a lot of standard css classes and stuff that the textbox inherits. How do i make it not inherit any other classes or can i make it to be reset so that it doesn't have any css classes except the ones i tell i to?!
One of the problems i have is that the textarea looks like it is sunk into the background i rather want it so look flat.
in your CSS
input[type="text"]{border:none; box-shadow:none; width:auto}
you can change any of these properties at will, or apply to all input elements by deleting the [text] part

Resources