mirror of
https://codeberg.org/unspeaker/tengri.git
synced 2026-02-22 18:59:02 +01:00
wip: refactor(tui): 1 error left
how do i flip buffer
This commit is contained in:
parent
3bdef228e8
commit
8ca90b9aa0
5 changed files with 86 additions and 58 deletions
|
|
@ -64,8 +64,8 @@ impl<N: Coord> XYWH<N> {
|
|||
pub fn with_h (&self, h: N) -> XYWH<N> {
|
||||
Self(self.x(), self.y(), self.w(), h)
|
||||
}
|
||||
pub fn lrtb (&self) -> XYWH<N> {
|
||||
Self(self.x(), self.x2(), self.y(), self.y2())
|
||||
pub fn lrtb (&self) -> [N;4] {
|
||||
[self.x(), self.x2(), self.y(), self.y2()]
|
||||
}
|
||||
pub fn clipped_w (&self, w: N) -> XYWH<N> {
|
||||
Self(self.x(), self.y(), self.w().min(w), self.h())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue