From 926550bac7d21d57049c500573b5d1fdd155f8cc Mon Sep 17 00:00:00 2001 From: jean-emmanuel Date: Tue, 18 Mar 2025 16:52:52 +0100 Subject: [PATCH] docs: update --- .../docs/docs/widgets/properties-reference.md | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/resources/docs/docs/widgets/properties-reference.md b/resources/docs/docs/widgets/properties-reference.md index 4c9b6011..fa195d3d 100644 --- a/resources/docs/docs/widgets/properties-reference.md +++ b/resources/docs/docs/widgets/properties-reference.md @@ -220,7 +220,7 @@ | property | type |default | description | | --- | --- | --- | --- | |
directory#
| `string` | "auto" | Default browsing directory | - |
extension#
| `string` | "*" | Only display files with this extension | + |
extension#
| `string`|
`array` | "*" | Only display files with this extension. Multiple extensions can be specified with an array of strings (`["jpg", "jpeg"]`) | |
allowDir#
| `boolean` | false | Allow selecting a folder (by pressing "open" when no file is selected) | ## Containers @@ -238,7 +238,7 @@ |
contain#
| `boolean` | true | If `layout` is `vertical` or `horizontal`, prevents children from overflowing the panel. | |
scroll#
| `boolean` | true | Set to `false` to disable scrollbars | |
innerPadding#
| `boolean` | true | Set to `false` to make the `padding` property apply only between children and not at the container's inner boundaries. | - |
tabsPosition#
| `string` | "top" | Defines the position of the navigation bar if the panel contains tabs

Choices: `top`, `bottom`, `left`, `right` | + |
tabsPosition#
| `string` | "top" | Defines the position of the navigation bar if the panel contains tabs

Choices: `top`, `bottom`, `left`, `right`, `hidden` | === "panel" @@ -450,7 +450,7 @@ |
contain#
| `boolean` | true | If `layout` is `vertical` or `horizontal`, prevents children from overflowing the panel. | |
scroll#
| `boolean` | true | Set to `false` to disable scrollbars | |
innerPadding#
| `boolean` | true | Set to `false` to make the `padding` property apply only between children and not at the container's inner boundaries. | - |
tabsPosition#
| `string` | "top" | Defines the position of the navigation bar if the panel contains tabs

Choices: `top`, `bottom`, `left`, `right` | + |
tabsPosition#
| `string` | "top" | Defines the position of the navigation bar if the panel contains tabs

Choices: `top`, `bottom`, `left`, `right`, `hidden` | |
hideMenu#
| `boolean` | false | Set to `true` to hide the main menu button. | === "root" @@ -493,7 +493,7 @@ |
contain#
| `boolean` | true | If `layout` is `vertical` or `horizontal`, prevents children from overflowing the panel. | |
scroll#
| `boolean` | true | Set to `false` to disable scrollbars | |
innerPadding#
| `boolean` | true | Set to `false` to make the `padding` property apply only between children and not at the container's inner boundaries. | - |
tabsPosition#
| `string` | "top" | Defines the position of the navigation bar if the panel contains tabs

Choices: `top`, `bottom`, `left`, `right` | + |
tabsPosition#
| `string` | "top" | Defines the position of the navigation bar if the panel contains tabs

Choices: `top`, `bottom`, `left`, `right`, `hidden` | |
label#
| `string`|
`boolean` | "auto" | Set to `false` to hide completely
- Insert icons using the prefix ^ followed by the icon's name : `^play`, `^pause`, etc (see https://fontawesome.com/icons?d=gallery&s=solid&m=free)
- Icons can be transformed with the following suffixes: `.flip-[horizontal|vertical|both]`, `.rotate-[90|180|270]`, `.spin`, `.pulse`. Example: `^play.flip-horizontal` | === "tab" @@ -612,12 +612,10 @@ | property | type |default | description | | --- | --- | --- | --- | - |
rangeX#
| `object` | \{
 "min": 20,
 "max": 22000
}
| Defines the min and max values for the x axis (in Hz, logarithmic scale) | + |
rangeX#
| `object` | \{
 "min": 20,
 "max": 22000
}
| Defines the min and max values for the x axis (in Hz, logarithmic scale)

The sampling frequency used to compute the response curve will be 2 * rangeX.max | |
rangeY#
| `object` | \{
 "min": -6,
 "max": 6
}
| Defines the min and max values for the y axis (in dB) | - |
logScaleX#
| `boolean`|
`number` | false | Set to `true` to use logarithmic scale for the x axis. Set to `-1` for exponential scale. | - |
logScaleY#
| `boolean`|
`number` | false | Set to `true` to use logarithmic scale for the y axis. Set to `-1` for exponential scale. | |
origin#
| `number`|
`boolean` | "auto" | Defines the y axis origin. Set to `false` to disable it | - |
filters#
| `array` | "" | Each item must be an object with the following properties
- `type`: string ("highpass", "highshelf", "lowpass", "lowshelf", "peak", "bandpass" or "notch", default: "peak")
- `freq`: number (filter's resonant frequency, default: 1000)
- `q`: number (Q factor, default: 1)
- `gain`: number (default: 0)
- `on`: boolean (default: true)

See https://developer.mozilla.org/en-US/docs/Web/API/BiquadFilterNode | + |
filters#
| `array` | "" | Each item must be an object with the following properties
- `type`: string ("highpass", "highshelf", "lowpass", "lowshelf", "peak", "bandpass" or "notch", default: "peak")
- `freq`: number (filter's resonant frequency, default: 1000)
- `q`: number (Q factor, default: 1)
- `gain`: number (default: 0)
- `on`: boolean (default: true)
- `poles`: if `type` is "highpass" or "lowpass", indicates the number of poles for the filter (if omitted or 0, a biquad filter with Q factor is used). Set to 1 for 6dB/otaves roll-off, 2 for 12dB/octaves, etc.

See https://developer.mozilla.org/en-US/docs/Web/API/BiquadFilterNode | |
pips#
| `boolean` | true | Set to false to hide the scale | === "value" @@ -706,9 +704,10 @@ | property | type |default | description | | --- | --- | --- | --- | |
css#
| `string` | "" | CSS rules. See documentation.

Some style-related properties can be set or read from css using css variables:
- `--color-background`: `colorBg`
- `--color-widget`: `colorWidget`
- `--color-fill`: `colorFill`
- `--color-stroke`: `colorStroke`
- `--color-text`: `colorText`
- `--widget-padding`: `padding`
- `--line-width`: `lineWidth`
- `--border-radius`: `borderRadius`
- `--alpha-fill-on`: `alphaFillOn`
- `--alpha-fill-off`: `alphaFillOff`
- `--alpha-stroke`: `alphaStroke`
- `--alpha-pips`: `alphaPips`
- `--alpha-pips-text`: `alphaPipsText`

Canvas-based widget have their computed width and height available as css variables (read-only):
- `--widget-width`
- `--widget-height` | - |
pointSize#
| `integer` | 20 | Defines the points' size | + |
pointSize#
| `integer` | 20 | Defines the points' size (may be in %) | |
ephemeral#
| `boolean` | false | When set to `true`, the point will be drawn only while touched. | |
pips#
| `boolean` | true | Set to `false` to hide the scale | + |
label#
| `string` | "" | Text displayed in the handle | === "xy" @@ -720,8 +719,8 @@ |
rangeY#
| `object` | \{
 "min": 0,
 "max": 1
}
| Defines the min and max values for the y axis | |
logScaleX#
| `boolean`|
`number` | false | Set to `true` to use logarithmic scale for the x axis. Set to `-1` for exponential scale. | |
logScaleY#
| `boolean`|
`number` | false | Set to `true` to use logarithmic scale for the y axis. Set to `-1` for exponential scale. | - |
axisLock#
| `string` | "" | Restrict movements to one of the axes only unless `Shift` is held.

When left to the default value, holding `Shift` while dragging will lock the pad according the first movement.

Choices: ``, `x`, `y` | - |
doubleTap#
| `boolean`|
`string` | false | Set to `true` to make the fader reset to its default value when receiving a double tap.

Can also be an osc address, which case the widget will just send an osc message: `/ ` | + |
axisLock#
| `string` | "" | Restrict movements to one of the axes only unless `Shift` is held.

When left empty, holding `Shift` while dragging will lock the pad according the first movement. `auto` will do the opposite.

Choices: ``, `x`, `y`, `auto` | + |
doubleTap#
| `boolean`|
`string` | false | Set to `true` to make the knob reset to its `default` value when receiving a double tap.

Can be an osc address, in which case the widget will just send an osc message with no value (but `preArgs` included).

If set to "script", `onTouch` will be called with `event.type` set to `doubleTap`.

Choices: `false`, `true`, `script` | |
sensitivity#
| `number` | 1 | Defines the pad's sensitivity when `snap` is `false` | === "scripting" @@ -758,7 +757,7 @@ | property | type |default | description | | --- | --- | --- | --- | |
css#
| `string` | "" | CSS rules. See documentation.

Some style-related properties can be set or read from css using css variables:
- `--color-background`: `colorBg`
- `--color-widget`: `colorWidget`
- `--color-fill`: `colorFill`
- `--color-stroke`: `colorStroke`
- `--color-text`: `colorText`
- `--widget-padding`: `padding`
- `--line-width`: `lineWidth`
- `--border-radius`: `borderRadius`
- `--alpha-fill-on`: `alphaFillOn`
- `--alpha-fill-off`: `alphaFillOff`
- `--alpha-stroke`: `alphaStroke`
- `--alpha-pips`: `alphaPips`
- `--alpha-pips-text`: `alphaPipsText`

Canvas-based widget have their computed width and height available as css variables (read-only):
- `--widget-width`
- `--widget-height` | - |
pointSize#
| `integer` | 20 | Defines the points' size | + |
pointSize#
| `integer` | 20 | Defines the points' default size (may be in %) | |
ephemeral#
| `boolean` | false | When set to `true`, the points will be drawn only while touched. | |
pips#
| `boolean` | true | Set to `false` to hide the scale | @@ -767,14 +766,15 @@ | property | type |default | description | | --- | --- | --- | --- | |
points#
| `integer`|
`array` | 2 | Defines the number of points on the pad

Can be an array of strings that will be used as labels for the points (ex: `['A', 'B']`) | + |
pointsAttr#
| `object` | [] | Defines per-point properties that are otherwise inherited from the multixy. Must be an array of objects (one per point) that may contain the following keys:
- visible (visibility and interactability)
- colorFill (background color)
- colorStroke (outline color)
- colorText (label color)
- color (shorthand for colorFill and colorStroke)
- alphaFillOn (background opacity)
- pointSize
- label | |
snap#
| `boolean` | false | By default, the points are dragged from their initial position.

If set to `true`, touching anywhere on the widget's surface will make them snap to the touching coordinates | |
spring#
| `boolean` | false | When set to `true`, the widget will go back to its default value when released | |
rangeX#
| `object` | \{
 "min": 0,
 "max": 1
}
| Defines the min and max values for the x axis | |
rangeY#
| `object` | \{
 "min": 0,
 "max": 1
}
| Defines the min and max values for the y axis | |
logScaleX#
| `boolean`|
`number` | false | Set to `true` to use logarithmic scale for the x axis. Set to `-1` for exponential scale. | |
logScaleY#
| `boolean`|
`number` | false | Set to `true` to use logarithmic scale for the y axis. Set to `-1` for exponential scale. | - |
axisLock#
| `string` | "" | Restrict movements to one of the axes only.

When left to the default value, holding `Shift` while dragging will lock the pad according the first movement.

Choices: ``, `x`, `y` | - |
doubleTap#
| `boolean`|
`string` | false | Set to `true` to make the fader reset to its default value when receiving a double tap.

Can also be an osc address, which case the widget will just send an osc message: `/ ` | + |
axisLock#
| `string` | "" | Restrict movements to one of the axes only.

When left empty, holding `Shift` while dragging will lock the pad according the first movement. `auto` will do the opposite.

Choices: ``, `x`, `y`, `auto` | + |
doubleTap#
| `boolean`|
`string` | false | Set to `true` to make the knob reset to its `default` value when receiving a double tap.

Can be an osc address, in which case the widget will just send an osc message with no value (but `preArgs` included).

If set to "script", `onTouch` will be called with `event.type` set to `doubleTap`.

Choices: `false`, `true`, `script` | |
sensitivity#
| `number` | 1 | Defines the pad's sensitivity when `snap` is `false` | === "scripting" @@ -835,7 +835,7 @@ |
snap#
| `boolean` | false | By default, dragging the widget will modify it's value starting from its last value. Setting this to `true` will make it snap directly to the mouse/touch position | |
touchZone#
| `string` | "all" | Restrict interaction to a part of the widget:
- `all`: touching the widget anywhere will start an interaction
- `knob`: touching the knob will start an interaction
- `gauge`: touching anywhere in the knob's moving range will start an interaction

This setting is ignored in containers with `traversing` set to `true`

Choices: `all`, `knob`, `gauge` | |
spring#
| `boolean` | false | When set to `true`, the widget will go back to its `default` value when released | - |
doubleTap#
| `boolean` | false | Set to `true` to make the fader reset to its `default` value when receiving a double tap.

Can also be an osc address, in which case the widget will just send an osc message (`/ `) | + |
doubleTap#
| `boolean`|
`string` | false | Set to `true` to make the knob reset to its `default` value when receiving a double tap.

Can be an osc address, in which case the widget will just send an osc message with no value (but `preArgs` included).

If set to "script", `onTouch` will be called with `event.type` set to `doubleTap`.

Choices: `false`, `true`, `script` | |
range#
| `object` | \{
 "min": 0,
 "max": 1
}
| Defines the breakpoints of the fader's scale:
- keys can be percentages and/or `min` / `max`
- values can be `number` or `object` if a custom label is needed

Example: (`{min:{"-inf": 0}, "50%": 0.25, max: {"+inf": 1}}`) | |
logScale#
| `boolean`|
`number` | false | Set to `true` to use logarithmic scale. Set to `-1` for exponential scale. | |
sensitivity#
| `number` | 1 | Defines the fader's sensitivity when `snap` is `false` | @@ -869,7 +869,7 @@ | --- | --- | --- | --- | |
mode#
| `string` | "vertical" | - `vertical`: relative move in vertical motion
- `circular`: relative move in circular motion
- `snap`: snap to touch position
- `snap-alt`: alternative snap mode that allow jumping from `range.min` to `range.max`. `sensitivity` is ignored with this mode.

Choices: `vertical`, `circular`, `snap`, `snap-alt` | |
spring#
| `boolean` | false | When set to `true`, the widget will go back to its `default` value when released | - |
doubleTap#
| `boolean` | false | Set to `true` to make the knob reset to its `default` value when receiving a double tap.

Can also be an osc address, in which case the widget will just send an osc message (`/ `) | + |
doubleTap#
| `boolean`|
`string` | false | Set to `true` to make the knob reset to its `default` value when receiving a double tap.

Can be an osc address, in which case the widget will just send an osc message with no value (but `preArgs` included).

If set to "script", `onTouch` will be called with `event.type` set to `doubleTap`.

Choices: `false`, `true`, `script` | |
range#
| `object` | \{
 "min": 0,
 "max": 1
}
| Defines the breakpoints of the fader's scale:
- keys can be percentages and/or `min` / `max`
- values can be `number` or `object` if a custom label is needed

Example: (`{min:{"-inf": 0}, "50%": 0.25, max: {"+inf": 1}}`) | |
logScale#
| `boolean`|
`number` | false | Set to `true` to use logarithmic scale. Set to `-1` for exponential scale. | |
sensitivity#
| `number` | 1 | Defines the knob's sensitivity when `mode` is not `snap` | @@ -936,7 +936,7 @@ |
snap#
| `boolean` | false | By default, dragging the widget will modify it's value starting from its last value. Setting this to `true` will make it snap directly to the mouse/touch position | |
touchZone#
| `string` | "all" | Restrict interaction to a part of the widget:
- `all`: touching the widget anywhere will start an interaction
- `knob`: touching the knob will start an interaction
- `gauge`: touching anywhere in the knob's moving range will start an interaction

This setting is ignored in containers with `traversing` set to `true`

Choices: `all`, `knob`, `gauge` | |
spring#
| `boolean` | false | When set to `true`, the widget will go back to its `default` value when released | - |
doubleTap#
| `boolean` | false | Set to `true` to make the fader reset to its `default` value when receiving a double tap.

Can also be an osc address, in which case the widget will just send an osc message (`/ `) | + |
doubleTap#
| `boolean`|
`string` | false | Set to `true` to make the knob reset to its `default` value when receiving a double tap.

Can be an osc address, in which case the widget will just send an osc message with no value (but `preArgs` included).

If set to "script", `onTouch` will be called with `event.type` set to `doubleTap`.

Choices: `false`, `true`, `script` | |
range#
| `object` | \{
 "min": 0,
 "max": 1
}
| Defines the breakpoints of the fader's scale:
- keys can be percentages and/or `min` / `max`
- values can be `number` or `object` if a custom label is needed

Example: (`{min:{"-inf": 0}, "50%": 0.25, max: {"+inf": 1}}`) | |
logScale#
| `boolean`|
`number` | false | Set to `true` to use logarithmic scale. Set to `-1` for exponential scale. | |
sensitivity#
| `number` | 1 | Defines the fader's sensitivity when `snap` is `false` |