BindedInputNumber
Introduction
BindedInputNumber
widget in Supervisely is a user interface element that allows users to input two numerical values and customize their behavior using the proportional, min, and max properties. With the BindedInputNumber widget, users can fine-tune specific parameters within supervisely apps that require two numerical inputs, such as defining a rectangular region of interest by specifying the x
and y
coordinates and the width
and height
. The BindedInputNumber
widget provides a convenient and flexible way to input and manage these values, with customizable behavior to ensure accurate and precise inputs.
Function signature
Parameters
Parameters | Type | Description |
---|---|---|
|
| Width value |
|
| Weight value |
|
| Minimum allowed value |
|
| Maximum allowed value |
|
| Synchronize changes in width and height parameters |
|
| ID of the widget |
width
Determine width value.
type: int
default value: 256
height
Determine height value.
type: int
default value: 256
min
Minimum allowed value.
type: int
default value: 1
max
Maximum allowed value.
type: int
default value: 10000
proportional
Synchronize changes in width and height parameters.
type: bool
default value: false
widget_id
ID of the widget.
type: str
default value: None
Methods and attributes
Attributes and Methods | Description |
---|---|
| Set widgets |
| Get input |
| Set |
| Set |
| Set |
| Disable widget. |
| Enable widget. |
Mini App Example
You can find this example in our Github repository:
ui-widgets-demos/input/004_binded_input_number/src/main.py
Import libraries
Initialize BindedInputNumber
widget
BindedInputNumber
widgetCreate app layout
Prepare a layout for app using Card
widget with the content
parameter and place widget that we've just created in the Container
widget.
Create app using layout
Create an app object with layout parameter.
Last updated