mirror of
https://github.com/ratatui-org/ratatui
synced 2025-02-16 14:08:44 +00:00
chore!: make Positions iterator fields private (#1424)
BREAKING CHANGE: The Rect Positions iterator no longer has public fields. The `rect` and `current_position` fields have been made private as they were not intended to be accessed directly.
This commit is contained in:
parent
8db7a9a44a
commit
9fd1beedb2
2 changed files with 6 additions and 6 deletions
|
@ -85,13 +85,13 @@ single `palette::Hsl` value and is gated behind a `palette` feature flag.
|
|||
+ Color::from_hsl(Hsl::new(360.0, 100.0, 100.0))
|
||||
```
|
||||
|
||||
### Removed public fields from `Rect` iterators ([#1358])
|
||||
### Removed public fields from `Rect` iterators ([#1358], [#1424])
|
||||
|
||||
[#1358]: https://github.com/ratatui/ratatui/pull/1358
|
||||
[#1424]: https://github.com/ratatui/ratatui/pull/1424
|
||||
|
||||
The `pub` modifier has been removed from fields on the `layout::rect::Columns` and
|
||||
`layout::rect::Rows`. These fields were not intended to be public and should not have been accessed
|
||||
directly.
|
||||
The `pub` modifier has been removed from fields on the `Columns`,`Rows`, and `Positions` iterators.
|
||||
These fields were not intended to be public and should not have been accessed directly.
|
||||
|
||||
### `Rect::area()` now returns u32 instead of u16 ([#1378])
|
||||
|
||||
|
|
|
@ -129,9 +129,9 @@ impl DoubleEndedIterator for Columns {
|
|||
/// The iterator will yield all positions within the `Rect` in a row-major order.
|
||||
pub struct Positions {
|
||||
/// The `Rect` associated with the positions.
|
||||
pub rect: Rect,
|
||||
rect: Rect,
|
||||
/// The current position within the `Rect`.
|
||||
pub current_position: Position,
|
||||
current_position: Position,
|
||||
}
|
||||
|
||||
impl Positions {
|
||||
|
|
Loading…
Add table
Reference in a new issue