xtd 1.0.0
Loading...
Searching...
No Matches
xtd::forms::paint_event_args Class Reference
Inheritance diagram for xtd::forms::paint_event_args:
xtd::event_args xtd::object

Definition

Provides data for the xtd::forms::control::paint event.

Header
#include <xtd/forms/paint_event_args>
Namespace
xtd::forms
Library
xtd.forms
Remarks
The xtd::forms::control::paint event occurs when a control is redrawn. A paint_event_args specifies the graphics to use to paint the control and the clip_rectangle in which to paint.

Public Constructors

 paint_event_args (xtd::forms::control &control, const xtd::drawing::rectangle &clip_rectangle, xtd::forms::message &message)
 Initializes a new instance of the paint_event_args class with the specified control, clipping rectangle.

Public Properties

auto clip_rectangle () const noexcept -> const xtd::drawing::rectangle &
 Gets the rectangle in which to paint.
auto graphics () -> xtd::drawing::graphics &
 Gets the graphics used to paint.
xtd::forms::messagemessage () noexcept
 Gets the message associate to paint.

Additional Inherited Members

static const event_args empty
 Provides a value to use with events that do not have event data.
 event_args ()=default
 Initializes a new instance of the event_args class.
 object ()=default
 Create a new instance of the ultimate base class object.
virtual auto equals (const object &obj) const noexcept -> bool
 Determines whether the specified object is equal to the current object.
virtual auto get_hash_code () const noexcept -> xtd::usize
 Serves as a hash function for a particular type.
virtual auto get_type () const noexcept -> type_object
 Gets the type of the current instance.
template<typename object_t>
auto memberwise_clone () const -> xtd::unique_ptr_object< object_t >
 Creates a shallow copy of the current object.
virtual auto to_string () const -> xtd::string
 Returns a xtd::string that represents the current object.
template<typename object_a_t, typename object_b_t>
static auto equals (const object_a_t &object_a, const object_b_t &object_b) noexcept -> bool
 Determines whether the specified object instances are considered equal.
template<typename object_a_t, typename object_b_t>
static auto reference_equals (const object_a_t &object_a, const object_b_t &object_b) noexcept -> bool
 Determines whether the specified object instances are the same instance.

Constructor & Destructor Documentation

◆ paint_event_args()

xtd::forms::paint_event_args::paint_event_args ( xtd::forms::control & control,
const xtd::drawing::rectangle & clip_rectangle,
xtd::forms::message & message )

Initializes a new instance of the paint_event_args class with the specified control, clipping rectangle.

Parameters
controlThe xtd::forms::control used to paint the item.
clip_rectangleThe xtd::drawing::rectangle that represents the rectangle in which to paint.
messageThe xtd::forms::message that represents the message associate to this paint_event_args.
Remarks
The message is needed for xtd::forms::control::on_paint_ xtd::forms::control::on_paint_background to call def_wnd_proc method.

Member Function Documentation

◆ clip_rectangle()

auto xtd::forms::paint_event_args::clip_rectangle ( ) const -> const xtd::drawing::rectangle &
nodiscardnoexcept

Gets the rectangle in which to paint.

Returns
The xtd::drawing::rectangle in which to paint.

◆ graphics()

auto xtd::forms::paint_event_args::graphics ( ) -> xtd::drawing::graphics &
nodiscard

Gets the graphics used to paint.

Returns
The xtd::drawing::graphics object used to paint. The xtd::drawing::graphics object provides methods for drawing objects on the display device.

◆ message()

xtd::forms::message & xtd::forms::paint_event_args::message ( )
nodiscardnoexcept

Gets the message associate to paint.

Returns
The xtd::forms::message object associate to paint.

The documentation for this class was generated from the following file: