3 unstable releases
new 0.2.2 | Jan 11, 2025 |
---|---|
0.2.1 | Jan 11, 2025 |
0.1.5 | Dec 14, 2024 |
0.1.1 |
|
#583 in GUI
464 downloads per month
32KB
622 lines
Iced File Tree
A lightweight file tree widget for the iced toolkit.
Usage
Include iced_file_tree
as a dependency in your Cargo.toml
:
[dependencies]
iced = "0.13.1"
iced_file_tree = "0.2.0"
Example
use iced::widget::scrollable;
use iced_file_tree::file_tree;
enum Message {
FileTreeMessage(PathBuf),
// ...
}
fn view(state: &State) -> Element<'_, Message> {
let path: PathBuf = // ...
scrollable(
file_tree(path)
.unwrap()
.on_double_click(Message::FileTreeMessage),
)
.into()
}
The FileTree
widget is recommended to be put in an iced Scrollable
.
Dependencies
~39–74MB
~1.5M SLoC