bootstack.ask_float#

bootstack.ask_float(prompt, *, title='', value=None, min_value=None, max_value=None, step=None, value_format=None, parent=None)#

Show a float-input dialog with optional range validation.

Parameters:
  • prompt (str) – Prompt text displayed above the input field.

  • title (str) – Dialog window title.

  • value (float | None) – Pre-filled initial value.

  • min_value (float | None) – Minimum accepted value.

  • max_value (float | None) – Maximum accepted value.

  • step (float | None) – Increment/decrement step size.

  • value_format (str | None) – ICU format pattern for displaying the value (e.g. '$#,##0.00' for currency, '#,##0.##' for decimals). See Format specs.

  • parent (Any) – Parent widget. Defaults to the active root window.

Returns:

The entered float, or None if canceled.

Return type:

float | None