Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 0.7 #181

Merged
merged 31 commits into from
Sep 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
45b4ab0
Expand styling options for tabs (#139)
LennysLounge Jun 6, 2023
fd0c238
feat: double click on separator to reset size (#146)
zkrising Jul 1, 2023
73c8967
Update version number and changelog
Adanos020 Jul 1, 2023
850c339
feat: allow disabling vertical/horizontal splits (#145)
zkrising Jul 23, 2023
afce578
Rename `SplitTypes` to `AllowedSplits`. Update changelog.
Adanos020 Jul 23, 2023
f9c0a12
Allow individual tabs to be closable or not (#150)
ptxmac Jul 29, 2023
daa69e0
Remove blank space where the close button is not enabled (#153)
12089897411 Aug 11, 2023
0bd85e5
Add the NodeIndex to context_menu() parameter list (#157)
ToppDev Aug 21, 2023
96f04c6
Support for undocking and docking tabs as windows (#149)
Vickerinox Aug 27, 2023
5c26183
pdate tab's scroll
12089897411 Aug 24, 2023
33f576e
update tab's scroll
12089897411 Aug 24, 2023
56c1352
update scroll mode for every tab
12089897411 Aug 24, 2023
1d10c70
update scroll mode for every tab
12089897411 Aug 25, 2023
87f4db5
update scroll mode for every tab
12089897411 Aug 25, 2023
fffebd7
Finish up rebase
Adanos020 Aug 27, 2023
8007b14
Reformat
Adanos020 Aug 27, 2023
d686736
Enable/disable scroll bars on individual tabs. (#160)
12089897411 Aug 27, 2023
c980560
Reformat
Adanos020 Aug 27, 2023
6713787
Update changelog and contribution guide
Adanos020 Aug 27, 2023
d818a3a
Make `TabViewer::{on_add,add_popup}` accept corresponding surface ind…
Adanos020 Aug 27, 2023
deaf0ff
Fix bug #168 (#171)
Vickerinox Aug 28, 2023
2c8011d
Fix for issue #172 (#173)
Vickerinox Aug 30, 2023
297aa63
Minor clarifications to documentation and changelog
Adanos020 Aug 30, 2023
67c606f
Add `serde` attributes to `DockState` and all types stored in it
Adanos020 Sep 2, 2023
37e9b5e
Make `DockState` and types related to it debugable
Adanos020 Sep 2, 2023
1de3979
Fix for issue #174 (#176)
Vickerinox Sep 4, 2023
9ace31a
Fixes to small bugs (#177)
Vickerinox Sep 4, 2023
567bf55
Translations (#178)
Adanos020 Sep 6, 2023
4b50722
Fix hover_pos on touch screens (#180)
ToppDev Sep 18, 2023
aa1f752
Update changelog
Adanos020 Sep 18, 2023
5a2a81f
New demo GIF
Adanos020 Sep 18, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 79 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,84 @@
# egui_dock changelog

## 0.7.0 - 2023-09-18

This is the biggest update so far, introducing the long awaited undocking feature: tabs can now be dragged out into
new egui windows. Massive thanks to [Vickerinox](https://github.com/Vickerinox) for implementing it!

This update also includes an overhaul of the documentation, aiming to not only be more readable and correct, but also
provide a guide of how to use the library.

### Changed

- Adjusted the styling of tabs to closer follow the egui default styling. ([#139](https://github.com/Adanos020/egui_dock/pull/139))
- Double-clicking on a separator resets the size of both adjacent nodes. ([#146](https://github.com/Adanos020/egui_dock/pull/146))
- Tabs can now only be dragged with the primary pointer button (e.g. left mouse button). ([#177](https://github.com/Adanos020/egui_dock/pull/177))

### Fixed

- Correctly draw a border around a dock area using the `Style::border` property. ([#139](https://github.com/Adanos020/egui_dock/pull/139))
- Non-closable tabs now cannot be closed by clicking with the middle mouse button. ([9cdef8c](https://github.com/Adanos020/egui_dock/pull/149/commits/9cdef8cb77e73ef7a065d1313f7fb8feae0253b4))
- Dragging tabs around now works on touchscreens. ([#180](https://github.com/Adanos020/egui_dock/pull/180))

### Added

- From [#139](https://github.com/Adanos020/egui_dock/pull/139):
- `Style::main_surface_border_rounding` for the rounding of the dock area border.
- `TabStyle::active` for the active style of a tab.
- `TabStyle::inactive` for the inactive style of a tab.
- `TabStyle::focused` for the focused style of a tab.
- `TabStyle::hovered` for the hovered style of a tab.
- `TabStyle::tab_body` for styling the body of the tab including background color, stroke color, rounding and inner margin.
- `TabStyle::minimum_width` to set the minimum width of the tab.
- `TabInteractionStyle` to style the active/inactive/focused/hovered states of a tab.
- `AllowedSplits` enum which lets you choose in which directions a `DockArea` can be split. ([#145](https://github.com/Adanos020/egui_dock/pull/145))
- From [#149](https://github.com/Adanos020/egui_dock/pull/149):
- `DockState<Tab>` containing the entire state of the tab hierarchies stored in a collection of `Surfaces`.
- `Surface<Tab>` enum which represents an area (e.g. a window) with its own `Tree<Tab>`.
- `SurfaceIndex` to identify a `Surface` stored in the `DockState`.
- `Split::is_tob_bottom` and `Split::is_left_right`.
- `TabInsert` which replaces current `TabDestination` (see breaking changes).
- `impl From<(SurfaceIndex, NodeIndex, TabInsert)> for TabDestination`.
- `impl From<SurfaceIndex> for TabDestination`.
- `TabDestination::is_window` (see breaking changes).
- `Tree::root_node` and `Tree::root_node_mut`.
- `Node::rect` returning the `Rect` occupied by the node.
- `Node::tabs` and `Node::tabs_mut` returning an optional slice of tabs if the node is a leaf.
- `WindowState` representing the current state of a `Surface::Window` and allowing you to manipulate the window.
- `OverlayStyle` (stored as `Style::overlay`) and `OverlayFeel`: they specify the look and feel of the drag-and-drop overlay.
- `OverlayType` letting you choose if the overlay should be the new icon buttons or the old highlighted rectangles.
- `LeafHighlighting` specifying how a currently hovered leaf should be highlighted.
- `DockArea::window_bounds` setting the area which windows are constrained by.
- `DockArea::show_window_close_buttons` setting determining if windows should have a close button or not.
- `DockArea::show_window_collapse_buttons` setting determining if windows should have a collapse button or not.
- `TabViewer::allowed_in_windows` specifying if a given tab can be shown in a window.
- `TabViewer::closable` lets individual tabs be closable or not. ([#150](https://github.com/Adanos020/egui_dock/pull/150))
- `TabViewer::scroll_bars` specifying if horizontal and vertical scrolling is enabled for given tab – replaces `DockArea::scroll_area_in_tabs` (see breaking changes). ([#160](https://github.com/Adanos020/egui_dock/pull/160))
- `Translations` specifying what text will be displayed in some parts of the `DockingArea`, e.g. the tab context menus (defined in `TabContextMenuTranslations`). ([#178](https://github.com/Adanos020/egui_dock/pull/178))

### Breaking changes

- From [#139](https://github.com/Adanos020/egui_dock/pull/139):
- Moved `TabStyle::inner_margin` to `TabBodyStyle::inner_margin`.
- Moved `TabStyle::fill_tab_bar` to `TabBarStyle::fill_tab_bar`.
- Moved `TabStyle::outline_color` to `TabInteractionStyle::outline_color`.
- Moved `TabStyle::rounding` to `TabInteractionStyle::rounding`.
- Moved `TabStyle::bg_fill` to `TabInteractionStyle::bg_fill`.
- Moved `TabStyle::text_color_unfocused` to `TabStyle::inactive.text_color`.
- Moved `TabStyle::text_color_active_focused` to `TabStyle::focused.text_color`.
- Moved `TabStyle::text_color_active_unfocused` to `TabStyle::active.text_color`.
- Renamed `Style::tabs` to `Style::tab`.
- Removed `TabStyle::text_color_focused`. This style was practically never reachable.
- From [#149](https://github.com/Adanos020/egui_dock/pull/149):
- `TabDestination` now specifies if a tab will be moved to a `Window`, a `Node`, or an `EmptySurface`. Its original purpose is now served by `TabInsert`.
- `Tree::split` now panics if supplied `fraction` is not in range 0..=1.
- Moved `Tree::move_tab` to `DockState::move_tab`.
- Renamed `Style::border` to `Style::main_surface_border_stroke`.
- Moved `Style::selection_color` to `OverlayStyle::selection_color`.
- `DockArea::new` now takes in a `DockState` instead of a `Tree`.
- Removed `DockArea::scroll_area_in_tabs` – override `TabViewer::scroll_bars` instead. ([#160](https://github.com/Adanos020/egui_dock/pull/160))
- Methods `TabViewer::{context_menu,on_add,add_popup}` now take in an additional `SurfaceIndex` parameter. ([#167](https://github.com/Adanos020/egui_dock/pull/167))

## 0.6.3 - 2023-06-16

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Bug reports should include how to reproduce said bug, if known.
## Pull requests

1. Fork this repository.
2. In your fork create a branch for your changes – do **not** submit directly to `main`.
2. In your fork create a branch for your changes – do **not** submit directly to `main` or `release-0.x`.
3. Make your changes and open a pull request.
- If your changes are not complete but e.g. you want feedback on your idea before fully committing to it, open a draft PR.
- Otherwise, feel free to open a regular PR.
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name = "egui_dock"
description = "Docking support for `egui` - an immediate-mode GUI library for Rust"
authors = ["lain-dono", "Adam Gąsior (Adanos020)"]
version = "0.6.3"
version = "0.7.0"
edition = "2021"
rust-version = "1.65"
license = "MIT"
Expand Down
22 changes: 17 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,34 @@
[![docs.rs](https://img.shields.io/docsrs/egui_dock)](https://docs.rs/egui_dock/)

Originally created by [@lain-dono](https://github.com/lain-dono), this library provides docking support for `egui`.
It lets you open and close tabs, freely move them around, insert them in selected parts of the `DockArea`, and resize them.

## How to contribute

Feel free to open new issues and pull requests.
## Contributing

Before contributing, please read [the contribution guide](CONTRIBUTING.md).

This library is a collaborative project developed with direct involvement of its users.

Please feel free to open new issues and pull requests, and participate in discussions!
A lot of our discussions take place on [`egui`'s official Discord server](https://discord.gg/JFcEma9bJq),
in the `#egui_dock` channel.

## Features

- Opening and closing tabs.
- Moving tabs between nodes and resizing.
- Dragging tabs out into new `egui` windows.
- Highly customizable look and feel.
- High degree of control over behaviour of the whole dock area and of individual tabs.
- Manipulating tabs and dock layout from code.

## Quick start

Add `egui` and `egui_dock` to your project's dependencies.

```toml
[dependencies]
egui = "0.22"
egui_dock = "0.6"
egui_dock = "0.7"
```

Then proceed by setting up `egui`, following its [quick start guide](https://github.com/emilk/egui#quick-start).
Expand Down
Loading