forked from 1b-agent/opencadstudio-upstream
Dock: flush title bars and a vertical title bar for floating panels
Every docked panel now shows its title bar flush along the top, like the Properties panel: dock::frame takes the title bar separately and pads only the content below it. A floating panel drops its horizontal title bar for a vertical one on the side facing the nearer workspace edge. Close and the auto-hide pin sit at the top; the panel's icon sits at the bottom with the title reading upward above it. The free part of the bar drags the panel. With auto-hide on, a floating panel shrinks to its title bar until hovered. Panel views take a dock::Chrome (auto-collapse plus floating) in place of the bare auto-collapse flag, so the shared title bar knows when to step aside. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013RyGiMXcsf9HTKfqDxaQGt
This commit is contained in:
10 files changed
+271
-81
No files matched your search
@@ -542,11 +542,11 @@ impl PropertiesPanel {
|
||||
.unwrap_or_default()
|
||||
}
|
||||
|
||||
pub fn view(&self, width: f32, auto_collapse: bool) -> Element<'_, Message> {
|
||||
pub fn view(&self, width: f32, chrome: crate::ui::dock::Chrome) -> Element<'_, Message> {
|
||||
use crate::ui::dock::PanelId;
|
||||
// ── Header ──────────────────────────────────────────────────────────
|
||||
let header =
|
||||
crate::ui::dock::title_bar(PanelId::Properties, t!("Properties").into_owned(), auto_collapse);
|
||||
crate::ui::dock::title_bar(PanelId::Properties, t!("Properties").into_owned(), chrome);
|
||||
|
||||
// ── Title bar (entity type / "No Selection") ─────────────────────
|
||||
let title_content: Element<'_, Message> = if self.selection_groups.is_empty() {
|
||||
|
||||
Reference in new issue
Block a user