Garry's Mod Wiki

draw.RoundedBoxEx

draw.RoundedBoxEx( number cornerRadius, number x, number y, number width, number height, table color, boolean roundTopLeft = false, boolean roundTopRight = false, boolean roundBottomLeft = false, boolean roundBottomRight = false )

Description

Draws a rounded rectangle. This function also lets you specify which corners are drawn rounded.

This is a rendering function that requires a 2d rendering context.

This means that it will only work in 2d Rendering Hooks.

Arguments

1 number cornerRadius
Radius of the rounded corners, works best with a power of 2 number.
2 number x
The x coordinate of the top left of the rectangle.
3 number y
The y coordinate of the top left of the rectangle.
4 number width
The width of the rectangle.
5 number height
The height of the rectangle.
6 table color
The color to fill the rectangle with. Uses the Color.
7 boolean roundTopLeft = false
Whether the top left corner should be rounded.
8 boolean roundTopRight = false
Whether the top right corner should be rounded.
9 boolean roundBottomLeft = false
Whether the bottom left corner should be rounded.
10 boolean roundBottomRight = false
Whether the bottom right corner should be rounded.

Page Links


Special Pages


Wikis

?

Render Time: 56ms

DB GetPage 3
Generate Html 29
SaveChanges (1) 9
Render Body 0
Render Sidebar 12