# Version 3.14 #

## guidata Version 3.14.4 ##

🛠️ Bug fixes:

* **`DataSetEditGroupBox` / computed items**: Fixed input field corruption when typing into a `LineEditWidget` whose `DataSet` contains other items declared via `set_computed(...)` (or any `display.callback`) — typing multiple characters in a row (e.g. `52` after selecting all) was silently truncated and re-interpreted between keystrokes (producing `5.02` instead of `52`, or `0.0.25` instead of `0.25`). The reactive update of computed siblings was recursively re-entering the same callback with a different exclusion target and overwriting the field the user was editing. Bug introduced in v3.13.0 (commit `0af365e`, "Add support for computed properties in datasets") (fixes [Issue #104](https://github.com/PlotPyStack/guidata/issues/104))
* **High-DPI display scaling**: Enabled automatic high-DPI scaling attributes (`AA_EnableHighDpiScaling`, `AA_UseHighDpiPixmaps`, `HighDpiScaleFactorRoundingPolicy.PassThrough`) before `QApplication` creation in `qapplication()` — on Qt5, UI elements were not scaled on high-DPI monitors (150%/200%/300% Windows display scaling), making text and widgets appear disproportionately small. Qt6 already enables these by default, so the calls are no-ops there. This single change resolves a large portion of visible symptoms downstream (PlotPy, PythonQwt, DataLab) (partial fix for [Issue #101](https://github.com/PlotPyStack/guidata/issues/101))
* **`CheckBoxWidget` clipping**: Fixed checkbox visual clipping when the checkbox text is empty — in mixed-widget grid layouts (especially at high DPI), the checkbox's natural height was smaller than other input widgets (`QComboBox`, `QLineEdit`), causing it to be cut off. The minimum height is now aligned to a standard input widget height
* **`gbuild` CLI command**: Fixed `gbuild` entry point referencing a `main` function that did not exist in `securebuild.py` — running the `gbuild` command after installing guidata raised an `AttributeError`. The argument parsing code was moved from a top-level `if __name__` block into a proper `main()` function (fixes [Issue #99](https://github.com/PlotPyStack/guidata/issues/99))
* **Cleanup utility (`gclean`)**: Fixed `clean_wix_installer_files` removing git-tracked files (e.g. `.bmp`, `.wxs` templates) when their extension matched generated artefact patterns — tracked files are now excluded from glob-based removal

♻️ Internal changes:

* **Debug environment variable**: Renamed debug environment variable from `DEBUG` to `GUIDATA_DEBUG` to avoid collisions with unrelated tooling or third-party conventions that also use the generic `DEBUG` name

## guidata Version 3.14.3 ##

🛠️ Bug fixes:

* **`FilesOpenItem`**: Fixed `AttributeError` raised when calling `from_string(None)` and `TypeError` raised when serializing an item whose value was never set — `None` values are now handled gracefully (empty list / empty sequence)
* **`FilesOpenItem`**: Replaced unsafe `eval()` call with `ast.literal_eval()` when parsing list-literal strings — eliminates an arbitrary code execution risk when reading list-of-paths values from configuration files or command-line arguments
* **`PreviewTableModel` (import wizard)**: Fixed mutable default argument bug where multiple `PreviewTableModel` instances shared the same underlying data list, causing cross-instance mutations
* **Dockable console**: Fixed floating dock widget that could not be reopened after closing — when a dock widget was closed while floating (via the window's X button), it now automatically re-docks inside the main window when re-shown, instead of remaining hidden as a floating window
* **Dark mode toolbar overflow button**: Fixed toolbar overflow button (the `>>` chevron) being invisible in dark mode — added proper QSS styling with gradient backgrounds and hover/pressed states for the `qt_toolbar_ext_button`

♻️ Internal changes:

* **Development environment**: Added `scripts/run_with_env.py` utility to run commands within multiple Python environment contexts (WinPython, venv, etc.), with `.env` file support for `PYTHONPATH` configuration
* **Translation file cleanup**: Enhanced PO file cleanup to remove additional headers (`PO-Revision-Date`, `Generated-By`, `Project-Id-Version`, `Report-Msgid-Bugs-To`, `Language-Team`) that cause unnecessary diffs in version control. Also cleanup the POT template file after extraction.

## guidata Version 3.14.2 ##

🛠️ Bug fixes:

* **Old QtPy compatibility**: Fixed `ImportError` when using QtPy < 2.0.0 (guidata supports QtPy >= 1.9) — the `PYSIDE6` constant was not available before QtPy 2.0.0
* **MultipleChoiceItem validation**: Fixed `DataItemValidationError` when accepting a dialog containing a `MultipleChoiceItem` with validation enabled — the widget was passing a list instead of the expected tuple, causing a validation failure when closing the dialog (fixes [Issue #98](https://github.com/PlotPyStack/guidata/issues/98))
* **PyQt6 compatibility**: Fixed `RuntimeError: wrapped C/C++ object has been deleted` when closing dialogs in automated tests with PyQt6 — `exec_dialog()` now checks object validity before calling `deleteLater()`, since Qt may already have destroyed the C++ object during `exec()`

## guidata Version 3.14.1 ##

* Added official support for Python 3.14

🛠️ Bug fixes:

* **PySide6 compatibility**: Added `is_qobject_valid()` utility function to safely check if a `QObject`'s underlying C++ object is still valid
  * With PySide6, accessing methods on a deleted C++ object causes a segfault instead of raising `RuntimeError` (as PyQt does)
  * Uses `shiboken.isValid()` on PySide2/PySide6 and `objectName()` try/except on PyQt5/PyQt6
  * Updated `close_widgets_and_quit()` to use `is_qobject_valid()` instead of a bare try/except for widget validity checks
  * Updated `close_dialog_and_quit()` to check widget validity before and after `processEvents()`, preventing segfaults when Qt deletes widgets during event processing

♻️ Code improvements:

* Refactored refresh action lambda in `IconBrowserWindow` for improved readability
* Simplified widget name retrieval in `close_widgets_and_quit()` function

## guidata Version 3.14.0 ##

✨ New features:

* **Jupyter notebook HTML representation**: Added rich HTML display support for DataSet and LabeledEnum objects
  * New `_repr_html_()` method on `DataSet` class for styled HTML table rendering in Jupyter notebooks
  * New `_repr_html_()` method on `LabeledEnum` class for formatted display of enum values with labels
  * CSS styling with `.guidata-dataset-table` class for consistent visual appearance
  * Automatically called by Jupyter when displaying objects as cell output
  * HTML representation now includes attribute names in a third column for easier programmatic access

* **Interactive Python experience**: Improved DataSet representation in Python interpreters
  * New `__repr__()` method on `DataSet` class shows attribute names instead of labels
  * Makes it easy to discover attribute names when working interactively in a Python shell or notebook
  * `print(dataset)` still shows user-friendly labels, while `repr(dataset)` or just typing the variable shows attribute names

* **Secure build utility**: Added `--prebuild` option to run commands before package build
  * New `--prebuild` command-line argument for `guidata.utils.securebuild`
  * Executes custom commands in the temporary build directory before `python -m build`
  * Useful for compiling translations or other pre-build tasks in the clean clone environment
  * Automatically replaces `python` with the current interpreter to avoid PATH issues on Windows
  * Converts relative PYTHONPATH entries to absolute paths for correct module resolution
  * Usage: `python -m guidata.utils.securebuild --prebuild "python -m guidata.utils.translations compile --name myapp --directory ."`

* New `cleanup-doc` command for Sphinx documentation translation files
  * Added `cleanup_doc_translations()` function to clean up `.po` files in `doc/locale/` directories
  * Removes `POT-Creation-Date` and `Last-Translator` headers from all Sphinx-generated translation files
  * Usage: `python -m guidata.utils.translations cleanup-doc --directory .`
  * Helps avoid merge conflicts when cherry-picking commits between branches (e.g., `release` ↔ `develop`)
  * Optional `--locale-dir` argument to specify custom locale directory path (defaults to `doc/locale`)

* Translation file generation: Ignore POT-Creation-Date and Last-Translator headers to reduce unnecessary diffs
  * Added `_cleanup_po_file()` helper function to remove the `POT-Creation-Date` and `Last-Translator` headers from generated `.po` files
  * This prevents spurious diffs in version control when regeneration occurs at different times
  * Integrated cleanup step into `generate_translation_files()` after `.po` file creation
  * Ensures cleaner translation file management and reduces noise in commit history

* **Icon Browser utility**: Added a new GUI tool for browsing and exploring icon collections
  * New `guidata.widgets.iconbrowser` module with `IconBrowserWindow` widget
  * Command-line tool: `giconbrowser [folder]` or `python -m guidata.widgets.iconbrowser [folder]`
  * Features a split-pane interface with tree view for folder navigation and icon grid display
  * Tree view shows folder hierarchy with open/closed folder icons and file counts
  * Single-click on icons opens file location in system file explorer (Windows/macOS/Linux)
  * Adjustable thumbnail sizes (16-256 pixels) via toolbar
  * Supports PNG, SVG, ICO, JPG, GIF, and BMP formats
  * Responsive grid layout adapts to window resizing
  * Useful for developers managing icons for their applications and libraries
  * Refresh action to toolbar for reloading current folder after external changes

* **Cleanup utility enhancements**: Improved the `guidata.utils.cleanup` module
  * Added case sensitivity option for glob patterns (default: case-insensitive matching)
  * Improved module name detection from `pyproject.toml` when name differs from directory name
  * Enhanced documentation cleanup to support removing PDF files with library name prefix
  * These improvements make the cleanup utility more robust and flexible for different project structures
