Update README.md

This commit is contained in:
Javi Agenjo
2020-03-29 20:50:20 +02:00
committed by GitHub
parent e8eda9d30f
commit e9e7c8df21

View File

@@ -186,7 +186,14 @@ function MyNodeType()
This is the list of supported widgets:
* **"number"** to change a value of a number, the syntax is ```this.addWidget("number","Number", current_value, callback, { min: 0, max: 100, step: 1} );```
* **"slider"** to change a number by draging the mouse, the syntax is the same as number.
* **"combo"** to select between multiple choices, the syntax is: ```this.addWidget("combo","Combo", "red", callback, { values:["red","green","blue"]} );```
* **"combo"** to select between multiple choices, the syntax is:
```this.addWidget("combo","Combo", "red", callback, { values:["red","green","blue"]} );```
or if you want to use objects:
```this.addWidget("combo","Combo", value1, callback, { values: { "title1":value1, "title2":value2 } );```
* **"text"** to edit a short string
* **"toggle"** like a checkbox
* **"button"**