Extension: omni.kit.widget.search_delegate-1.0.8 |
Documentation Generated: Aug 12, 2025 |
Overview#
The Search Delegate Widget extension provides the core components to integrate a file system search feature into Omniverse Kit applications. It offers a structured framework for creating search user interfaces by combining input fields, search delegates, and models to display results in a file browser view. The extension is designed to streamline the creation of search components and ensure consistent behavior across different parts of the application.

Concepts#
SearchDelegate
An abstract base class that defines the interface for search UI components. It manages properties such as widget visibility, enabled state, and the active search directory, requiring subclasses to implement their own UI building and cleanup operations.SearchField
A concrete implementation of the search delegate that provides a user interface for entering search keywords. It supports tokenization of search words and triggers a callback with search results once the input is processed.SearchResultsModel and SearchResultsItem
These classes extend file browser functionalities to present search results. The model creates a structured root group, subscribes to updates from a backend search model, and ensures that changes in search items are reflected in the display. The item class encapsulates details of each search result, whether it represents a file or a folder.
Functionality#
UI Construction and Management
The extension enables the development of search interfaces by allowing developers to build custom UI elements based on a predefined delegate. The SearchField widget, for instance, constructs an input area that can display search tokens and respond to editing changes.Dynamic Search and Result Presentation
Once users input search terms, the widget initiates the search process and uses the SearchResultsModel to manage and update the file browser view with the corresponding search hits. SearchResultsItem supports additional features like retrieving custom thumbnails for folder items.Integration of Search with File Browser
By leveraging the file browser components from the related extension, the search results are displayed consistently alongside other file system elements. This integration simplifies workflows that involve both search and navigation of files or directories.
Relationships#
Dependencies
The extension builds on several key modules:omni.ui
omni.client
omni.kit.widget.filebrowser
omni.kit.search_core
These dependencies ensure that search functionalities integrate smoothly with existing file browser mechanisms and user interface components provided by Omniverse Kit.
Usage Examples#
At a high level, you can instantiate a SearchField by providing a callback function that processes the search results generated by the SearchResultsModel. Adjusting properties such as visibility, enabled state, and search_dir allows for seamless integration into your application’s workflow. The extension is purpose-built to offer a consistent file search experience using the familiar file browser paradigm.
Considerations#
The extension is designed as a framework to be extended and customized. While the SearchDelegate provides the necessary hooks, specific UI behavior and additional logic can be implemented in subclasses.
Integration with the file browser means that any modifications to the file browser extension may influence the appearance and behavior of search results.
As with any search-based UI component, careful management of subscriptions and resource cleanup (via the destroy methods) is essential to prevent memory leaks and ensure optimal performance.