mirror of
https://github.com/Textualize/textual.git
synced 2025-10-17 02:38:12 +03:00
docstrings
This commit is contained in:
@@ -143,8 +143,8 @@ def resolve_box_models(
|
||||
width_fraction = fraction_unit
|
||||
height_fraction = Fraction(size.height)
|
||||
else:
|
||||
height_fraction = fraction_unit
|
||||
width_fraction = Fraction(size.width)
|
||||
height_fraction = fraction_unit
|
||||
|
||||
box_models = [
|
||||
box_model
|
||||
|
||||
@@ -31,6 +31,8 @@ def get_box_model(
|
||||
styles (StylesBase): Styles object.
|
||||
container (Size): The size of the widget container.
|
||||
viewport (Size): The viewport size.
|
||||
width_fraction (Fraction): A fraction used for 1 `fr` unit on the width dimension.
|
||||
height_fraction (Fraction):A fraction used for 1 `fr` unit on the height dimension.
|
||||
get_auto_width (Callable): A callable which accepts container size and parent size and returns a width.
|
||||
get_auto_height (Callable): A callable which accepts container size and parent size and returns a height.
|
||||
|
||||
|
||||
@@ -420,7 +420,8 @@ class Widget(DOMNode):
|
||||
Args:
|
||||
container (Size): The size of the container widget (with a layout)
|
||||
viewport (Size): The viewport size.
|
||||
fraction_unit (Fraction): The unit used for `fr` units.
|
||||
width_fraction (Fraction): A fraction used for 1 `fr` unit on the width dimension.
|
||||
height_fraction (Fraction):A fraction used for 1 `fr` unit on the height dimension.
|
||||
|
||||
Returns:
|
||||
BoxModel: The size and margin for this widget.
|
||||
|
||||
Reference in New Issue
Block a user