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

Feature: Support FIXED and FLOW operations for Overlay depends on options #743

Merged
merged 2 commits into from Jan 12, 2024

Conversation

penguinolog
Copy link
Collaborator

  • Add tests
  • Update documentation
Checklist
  • I've ensured that similar functionality has not already been implemented
  • I've ensured that similar functionality has not earlier been proposed and declined
  • I've branched off the master or python-dual-support branch
  • I've merged fresh upstream into my branch recently
  • I've ran tox successfully in local environment
  • I've included docstrings and/or documentation and/or examples for my code (if this is a new feature)

@penguinolog penguinolog added the Feature Feature request/implementation label Jan 12, 2024
@github-actions github-actions bot added docs Issues related to documentation Tests Tests labels Jan 12, 2024
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

File will be re-generated from original vectors in another PR

@@ -304,17 +304,17 @@ new space.
Overlay Widgets
---------------

The :class:`Overlay` widget is a box widget that contains two
other box widgets. The bottom widget is rendered the full size of the Overlay
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like totally outdated

@coveralls
Copy link

coveralls commented Jan 12, 2024

Pull Request Test Coverage Report for Build 7505379911

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.09%) to 69.883%

Totals Coverage Status
Change from base Build 7501472280: 0.09%
Covered Lines: 8339
Relevant Lines: 12018

💛 - Coveralls

* * width amount and GIVEN width or min_width AND:
* * * FLOW supported by the TOP widget AND PACK height type
* * * BOX supported by the TOP widget AND height_amount and GIVEN height or min height
"""
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMHO adding examples is overkill (too complex arguments sequences)

if Sizing.FIXED in top_sizing:
sizing.add(Sizing.FIXED)
else:
warnings.warn(
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

negative cases with warnings and exceptions should be covered separately.

Provide information about owner widget
def __rich_repr__(inner_self) -> Iterator[tuple[str | None, typing.Any] | typing.Any]:
yield from self.items()
yield from inner_self.items()
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Autocomplete fail


if typing.TYPE_CHECKING:
from collections.abc import Iterator

from typing_extensions import Literal


class OverlayError(Exception):
pass
class OverlayError(WidgetError):
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Proper exception class (need to do for others widgets too)

@penguinolog penguinolog merged commit 3f27be7 into urwid:master Jan 12, 2024
35 checks passed
@penguinolog penguinolog deleted the fixed_flow_overlay branch January 12, 2024 21:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Issues related to documentation Feature Feature request/implementation Tests Tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants