mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
gg: Context.resize()
This commit is contained in:
parent
4be45e8d02
commit
3dae3f786d
@ -484,6 +484,11 @@ fn abs(a f32) f32 {
|
|||||||
return -a
|
return -a
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn (mut ctx Context) resize(width int, height int) {
|
||||||
|
ctx.width = width
|
||||||
|
ctx.height = height
|
||||||
|
}
|
||||||
|
|
||||||
pub fn (ctx &Context) draw_line(x f32, y f32, x2 f32, y2 f32, c gx.Color) {
|
pub fn (ctx &Context) draw_line(x f32, y f32, x2 f32, y2 f32, c gx.Color) {
|
||||||
if c.a != 255 {
|
if c.a != 255 {
|
||||||
sgl.load_pipeline(ctx.timage_pip)
|
sgl.load_pipeline(ctx.timage_pip)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user