W3cubDocs

/Godot 4.2

ColorRect

Inherits: Control < CanvasItem < Node < Object

A control that displays a solid color rectangle.

Description

Displays a rectangle filled with a solid color. If you need to display the border alone, consider using a Panel instead.

Tutorials

Properties

Color

color

Color(1, 1, 1, 1)

Property Descriptions

Color color = Color(1, 1, 1, 1)

  • void set_color ( Color value )
  • Color get_color ( )

The fill color of the rectangle.

© 2014–present Juan Linietsky, Ariel Manzur and the Godot community
Licensed under the Creative Commons Attribution Unported License v3.0.
https://docs.godotengine.org/en/4.2/classes/class_colorrect.html