dhtmlxEditor with full control buttons - editor

When I added a dhtmlxEditor type, it shows only basic editor control button such as bold, italic, underline and erase.
ex)
{ type:"editor" , name:"notice", label:"Notice", labelWidth:600, inputWidth:600, inputHeight:279, labelLeft:25, labelTop:50, inputLeft:25, inputTop:71 }
How can I use toolbar option with full control buttons provided?

You need to add property
{ ... toolbar: true ... }

Related

How can I change the text color of an Ant Design Radio component when it is disabled

I want to change the text color when an Ant Design Radio button is disabled. I have been trying things like this...
.ant-radio[disabled]:active {
color: $g06;
}
Which haven't worked.
Add the folowing css.
.ant-radio-disabled + span {
color: #ea6262;
}
Screenshot

How to remove the background of a dialog?

I created a custom dialog with my own panes and controls in it. But the dialog has a white border default which I want to remove. Here is an example with a single image:
I tried using ScenicView but couldn't find a way to catch the dialog layer and modify it:
public class MainView extends View {
Image img = new Image("https://i.stack.imgur.com/7bI1Y.jpg", 300, 500, true, true);
public MainView(String name) {
super(name);
Button b = new Button("Pop");
b.setOnAction(e -> {
Dialog<Void> dialog = new Dialog<>();
dialog.setOnShown(e2 -> {
Parent parent = getParent();
Pane p = (Pane) parent.lookup(".dialog");
p.setPadding(new Insets(0));
});
dialog.setGraphic(new ImageView(img));
dialog.showAndWait();
});
setCenter(b);
}
}
Best i got was removing the flowpane child to remove some of the lower part
dialog.setOnShown(e2 -> {
Parent parent = getParent();
Pane p = (Pane) parent.lookup(".dialog");
p.getChildren().removeIf(c -> (c instanceof FlowPane));
System.out.println(p.getChildren());
});
Removing the VBox moves the dialog which i don't want to do and changing its padding also dose nothing.
As you can see with ScenicView, the Dialog has the dialog style class.
One easy way to modify the dialog style is via css. Just add a css file to your view, and set:
.dialog {
-fx-background-color: transparent;
}
That will set the background transparent, instead of the default white color.
If you want to remove the borders instead, then you can play with padding. As you can also see with ScenicView, the dialog has a VBox with style class container for the content in the center, and the flow pane for the buttons at the bottom, with style class dialog-button-bar.
Before anything, just use the setContent method to add the image instead of the setGraphic one:
dialog.setContent(new ImageView(img));
And this will be required to remove all the borders, and let the image take the whole dialog:
.dialog,
.dialog > .container,
.dialog > .dialog-button-bar {
-fx-padding: 0;
}

QML TextField does not show copy menu on iOS

If I use default TextField control, default ios edit menu for copy/paste is displayed
TextField {
}
But I need TextField control without border, so I use TextFieldStyle
TextField {
text: value
style: TextFieldStyle {
background: Rectangle {
border.width: 0
}
}
}
In this case there is no ios edit menu fo copy/paste. Is possible to have default ios edit menu with TextField without border ?
Add: it works on iOS in Qt 5.7.0

Text running off the screen in QML, Blackberry

I have a problem in Blackberry Native. The text id is a QString, and it contains many words, and I am not sure how to code it such that the text does not run off the screen. I tried LabelTextFitMode and it doesn't work. Any ideas?
Label {
text: "Description:"
textStyle.fontWeight: FontWeight.Normal
textStyle.fontSize: FontSize.Small
textStyle.color: Color.DarkRed // Show this text
}
Label {
id: description // Name this as type_label so that the property alias above can set the text property of this item
//textStyle.fontSize: FontSize.Small
textFit {
mode: LabelTextFitMode.FitToBounds
}
}
Just use multiline like this:
Label {
id: description
multiline: true
}

How to customize the button and label text size for each field separately in blackberry application?

I am new to BB application. I want customized the size for the button text and label text.
I am using this code
try {
FontFamily alphaSansFamily = FontFamily.forName("BBAlpha Serif");
Font appFont = alphaSansFamily.getFont(Font.PLAIN, 9, Ui.UNITS_pt);
setFont(appFont);
} catch (ClassNotFoundException e) {
}
but using this it will change size for what all the field we are using within the constructor.But I need different size for different field .Like Title will be big size and other label text button text will be small size.
I am guessing that you are calling that when you are creating the screen so the setFont() changes the font for the full screen.
You can call set font on the required button or label and it will change the font only for that field
e.g button.setFont(yourFont)
Are you calling setFont() explicitly on the Field you wish to change?
just in the above try block donot declere the statement setFont(appFont), this sets the font of the whole screen.
Insead set the font by specifying which label or button you want to set the font like
LabelField lf1 = new LabelField("Testing");
lf1.setFont(appFont);
Again
ObjectChoiceField ocf1 = new ObjectChoiceField("","","");
ocf1.setFont(appFont);

Resources