mirror of
https://github.com/eliasstepanik/imgui-rs.git
synced 2026-01-28 05:48:34 +00:00
fmt
This commit is contained in:
parent
eb1bd01179
commit
416272a48a
@ -114,7 +114,7 @@ fn main() {
|
|||||||
[o[0] + 0.0, o[1] + 100.0],
|
[o[0] + 0.0, o[1] + 100.0],
|
||||||
[o[0] + 0.0, o[1] + 0.0],
|
[o[0] + 0.0, o[1] + 0.0],
|
||||||
],
|
],
|
||||||
[1.0, 0.0, 1.0]
|
[1.0, 0.0, 1.0],
|
||||||
)
|
)
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
@ -128,7 +128,7 @@ fn main() {
|
|||||||
[o[0] + 120.0 + 0.0, o[1] + 100.0],
|
[o[0] + 120.0 + 0.0, o[1] + 100.0],
|
||||||
[o[0] + 120.0 + 0.0, o[1] + 0.0],
|
[o[0] + 120.0 + 0.0, o[1] + 0.0],
|
||||||
],
|
],
|
||||||
[0.0, 1.0, 1.0]
|
[0.0, 1.0, 1.0],
|
||||||
)
|
)
|
||||||
.filled(true)
|
.filled(true)
|
||||||
.build();
|
.build();
|
||||||
|
|||||||
@ -230,11 +230,7 @@ impl<'ui> DrawListMut<'ui> {
|
|||||||
/// polygon, if not filled is drawn as a line specified by
|
/// polygon, if not filled is drawn as a line specified by
|
||||||
/// [`PolyLine::thickness`] (default 1.0)
|
/// [`PolyLine::thickness`] (default 1.0)
|
||||||
#[doc(alias = "AddPolyline", alias = "AddConvexPolyFilled")]
|
#[doc(alias = "AddPolyline", alias = "AddConvexPolyFilled")]
|
||||||
pub fn add_polyline<C, P>(
|
pub fn add_polyline<C, P>(&'ui self, points: Vec<P>, c: C) -> Polyline<'ui>
|
||||||
&'ui self,
|
|
||||||
points: Vec<P>,
|
|
||||||
c: C,
|
|
||||||
) -> Polyline<'ui>
|
|
||||||
where
|
where
|
||||||
C: Into<ImColor32>,
|
C: Into<ImColor32>,
|
||||||
P: Into<MintVec2>,
|
P: Into<MintVec2>,
|
||||||
@ -516,11 +512,7 @@ pub struct Polyline<'ui> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl<'ui> Polyline<'ui> {
|
impl<'ui> Polyline<'ui> {
|
||||||
fn new<C, P>(
|
fn new<C, P>(draw_list: &'ui DrawListMut<'_>, points: Vec<P>, c: C) -> Self
|
||||||
draw_list: &'ui DrawListMut<'_>,
|
|
||||||
points: Vec<P>,
|
|
||||||
c: C,
|
|
||||||
) -> Self
|
|
||||||
where
|
where
|
||||||
C: Into<ImColor32>,
|
C: Into<ImColor32>,
|
||||||
P: Into<MintVec2>,
|
P: Into<MintVec2>,
|
||||||
@ -573,7 +565,6 @@ impl<'ui> Polyline<'ui> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// Represents a rectangle about to be drawn
|
/// Represents a rectangle about to be drawn
|
||||||
#[must_use = "should call .build() to draw the object"]
|
#[must_use = "should call .build() to draw the object"]
|
||||||
pub struct Rect<'ui> {
|
pub struct Rect<'ui> {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user