Horizontal width auto (#1155)

* Improvements to width:auto HorizontalLayout

* Fix HorizontalLayout.get_content_width

* Horizontal width auto improvement

* Removing some printxz

* Update snapshot for horizontal layout width auto dock
This commit is contained in:
darrenburns
2022-11-16 14:49:52 +00:00
committed by GitHub
parent a37eac3cad
commit a465f5c236
6 changed files with 240 additions and 55 deletions

View File

@@ -2,9 +2,11 @@ from pathlib import Path
import pytest
# These paths should be relative to THIS directory.
WIDGET_EXAMPLES_DIR = Path("../../docs/examples/widgets")
LAYOUT_EXAMPLES_DIR = Path("../../docs/examples/guide/layout")
STYLES_EXAMPLES_DIR = Path("../../docs/examples/styles")
SNAPSHOT_APPS_DIR = Path("./snapshot_apps")
# --- Layout related stuff ---
@@ -29,6 +31,10 @@ def test_horizontal_layout(snap_compare):
assert snap_compare(LAYOUT_EXAMPLES_DIR / "horizontal_layout.py")
def test_horizontal_layout_width_auto_dock(snap_compare):
assert snap_compare(SNAPSHOT_APPS_DIR / "horizontal_auto_width.py")
def test_vertical_layout(snap_compare):
assert snap_compare(LAYOUT_EXAMPLES_DIR / "vertical_layout.py")