72 graphics(
const graphics& value);
73 graphics& operator =(
const graphics& value);
120 [[nodiscard]] auto
dpi_x() const noexcept ->
float;
124 [[nodiscard]] auto
dpi_y() const noexcept ->
float;
326 auto
draw_arc(const
xtd::
drawing::
pen&
pen,
float x,
float y,
float width,
float height,
float start_angle,
float sweep_angle) ->
void;
367 auto
draw_bezier(const
pen&
pen,
float x1,
float y1,
float x2,
float y2,
float x3,
float y3,
float x4,
float y4) ->
void;
745 auto
draw_pie(const
xtd::
drawing::
pen&
pen,
float x,
float y,
float width,
float height,
float start_angle,
float sweep_angle) ->
void;
1179 [[nodiscard]] auto
is_visible(
float x,
float y,
float width,
float height) ->
bool;
1377 [[nodiscard]]
auto to_page_unit(
float value)
const -> float;
1380 [[nodiscard]]
auto to_pixels(
float value)
const -> float;
1389 auto draw_image_disabled(
const xtd::drawing::image&
image,
float x,
float y,
float width,
float height,
float brightness) -> void;
Contains xtd::drawing::brush class.
Provides methods for creating, manipulating, searching, and sorting arrays, thereby serving as the ba...
Definition array.hpp:64
Defines objects used to fill the interiors of graphical shapes such as rectangles,...
Definition brush.hpp:33
Represents an ARGB (alpha, red, green, blue) color.
Definition color.hpp:52
Defines a particular format for text, including font face, size, and style attributes....
Definition font.hpp:45
auto draw_point(const xtd::drawing::pen &pen, const xtd::drawing::point &point) -> void
Draws a point specified by the coordinate pairs.
auto fill_closed_curve(const xtd::drawing::brush &brush, const xtd::array< xtd::drawing::point > &points) -> void
Fills the interior of a closed cardinal spline curve defined by an array of xtd::drawing::point struc...
auto compositing_mode() const noexcept -> xtd::drawing::drawing_2d::compositing_mode
Gets a value that specifies how composited images are drawn to this xtd::drawing::graphics.
auto translate_clip(xtd::int32 dx, xtd::int32 dy) -> void
Translates the clipping region of this xtd::drawing::graphics by specified amounts in the horizontal ...
auto draw_polygon(const xtd::drawing::pen &pen, const xtd::array< xtd::drawing::point > &points) -> void
Draws a polygon defined by an array of xtd::drawing::point structures.
auto interpolation_mode() const noexcept -> xtd::drawing::drawing_2d::interpolation_mode
Gets the interpolation mode associated with this xtd::drawing::graphics.
static auto from_hdc(xtd::intptr hdc) -> graphics
Creates a new xtd::drawing::graphics from the specified handle to a device context.
auto copy_from_screen(const xtd::drawing::point &upper_left_source, const xtd::drawing::point &upper_left_destination, const xtd::drawing::size &block_region_size) -> void
Performs a bit-block transfer of color data, corresponding to a rectangle of pixels,...
auto draw_icon_unstretched(const xtd::drawing::icon &icon, const xtd::drawing::rectangle &rect) -> void
Draws the image represented by the specified Icon without scaling the image.
auto get_hdc() const -> xtd::intptr
Gets the handle to the device context associated with this xtd::drawing::graphics.
auto draw_arc(const xtd::drawing::pen &pen, const xtd::drawing::rectangle &rect, float start_angle, float sweep_angle) -> void
Draws an arc representing a portion of an ellipse specified by a xtd::drawing::rectangle structure.
auto draw_image_unscaled(const xtd::drawing::image &image, const xtd::drawing::point &point) -> void
Draws a specified image using its original physical size at a specified location.
auto intersect_clip(const xtd::drawing::region ®ion) -> void
Updates the clip region of this xtd::drawing::graphics to the intersection of the current clip region...
auto fill_pie(const xtd::drawing::brush &brush, const xtd::drawing::rectangle &rect, float start_angle, float sweep_angle) -> void
Fills the interior of a pie section defined by an ellipse specified by a xtd::drawing::rectangle stru...
auto copy_from_graphics(const graphics &source, const xtd::drawing::point &upper_left_source, const xtd::drawing::point &upper_left_destination, const xtd::drawing::size &block_region_size) -> void
Performs a bit-block transfer of color data, corresponding to a rectangle of pixels,...
auto get_nearest_color(const xtd::drawing::color &color) const -> xtd::drawing::color
Gets the nearest color to the specified xtd::drawing::color structure.
auto draw_rectangles(const xtd::drawing::pen &pen, const xtd::array< xtd::drawing::rectangle > &rects) -> void
Draws a series of rectangles specified by xtd::drawing::rectangle structures.
static auto from_image(const xtd::drawing::image &image) -> graphics
Creates a new xtd::drawing::graphics from the specified xtd::drawing::image.
auto fill_ellipse(const xtd::drawing::brush &brush, const xtd::drawing::rectangle &rect) -> void
Fills the interior of an ellipse defined by a bounding rectangle specified by a xtd::drawing::rectang...
auto smoothing_mode() const noexcept -> xtd::drawing::drawing_2d::smoothing_mode
Gets the rendering quality for this xtd::drawing::graphics.
auto text_contrast() const noexcept -> xtd::int32
Gets the gamma correction value for rendering text.
auto to_string() const noexcept -> xtd::string override
Returns a xtd::string that represents the current object.
Definition graphics.hpp:1333
auto scale_transform(float sx, float sy) -> void
Applies the specified scaling operation to the transformation matrix of this xtd::drawing::graphics b...
auto measure_string(const xtd::string &text, const xtd::drawing::font &font) -> xtd::drawing::size_f
Measures the specified string when drawn with the specified xtd::drawing::font.
auto fill_rectangles(const xtd::drawing::brush &brush, const xtd::array< xtd::drawing::rectangle > &rects) -> void
Fills the interiors of a series of rectangles specified by xtd::drawing::rectangle structures.
auto visible_clip_bounds() const noexcept -> xtd::drawing::rectangle_f
Gets the bounding rectangle of the visible clipping region of this xtd::drawing::graphics.
auto draw_path(const xtd::drawing::pen &pen, const xtd::drawing::drawing_2d::graphics_path &path) -> void
Draws a xtd::drawing::drawing_2d::graphics_path.
auto draw_ellipse(const xtd::drawing::pen &pen, const xtd::drawing::rectangle &rect) -> void
Draws an ellipse specified by a bounding xtd::drawing::rectangle structure.
auto draw_pie(const xtd::drawing::pen &pen, const xtd::drawing::rectangle &rect, float start_angle, float sweep_angle) -> void
Draws a pie shape defined by an ellipse specified by a xtd::drawing::rectangle structure and two radi...
auto text_rendering_hint() const noexcept -> xtd::drawing::text::text_rendering_hint
Gets the rendering mode for text associated with this xtd::drawing::graphics.
auto release_hdc(xtd::intptr hdc) -> void
Releases a device context handle obtained by a previous call to the xtd::drawing::graphics::get_hdc()...
auto draw_image_unscaled_and_clipped(const xtd::drawing::image &image, const xtd::drawing::rectangle &rect) -> void
Draws the specified image without scaling and clips it, if necessary, to fit in the specified rectang...
auto fill_polygon(const xtd::drawing::brush &brush, const xtd::array< xtd::drawing::point > &points) -> void
Fills the interior of a polygon defined by an array of points specified by xtd::drawing::point struct...
auto page_scale() const noexcept -> float
Gets the scaling between world units and page units for this xtd::drawing::graphics.
auto dpi_x() const noexcept -> float
Gets the horizontal resolution of this xtd::drawing::graphics.
auto draw_image(const xtd::drawing::image &image, const xtd::drawing::rectangle &rect) -> void
Draws the specified xtd::drawing::image at the specified location and with the specified size.
auto fill_rectangle(const xtd::drawing::brush &brush, const xtd::drawing::rectangle &rect) -> void
Fills the interior of a rectangle specified by a xtd::drawing::rectangle structure.
auto draw_string(const xtd::string &s, const xtd::drawing::font &font, const xtd::drawing::brush &brush, const xtd::drawing::rectangle_f &layout_rectangle) -> void
Draws the specified text string at the specified rectangle with the specified xtd::drawing::brush and...
auto pixel_offset_mode() const noexcept -> xtd::drawing::drawing_2d::pixel_offset_mode
Gets a value specifying how pixels are offset during rendering of this xtd::drawing::graphics.
auto clear(const xtd::drawing::color &color) -> void
Clears the entire drawing surface and fills it with the specified background color.
auto trim_string(const xtd::string &text, const xtd::drawing::font &font, float width, xtd::drawing::string_trimming trimming) -> xtd::string
Trims the specified string for a specified width with the specified xtd::drawing::font and with the s...
auto is_visible(const xtd::drawing::rectangle &rect) -> bool
Indicates whether the rectangle specified by a xtd::drawing::rectangle structure is contained within ...
auto draw_icon(const xtd::drawing::icon &icon, xtd::int32 x, xtd::int32 y) -> void
Draws the image represented by the specified xtd::drawing::icon at the specified coordinates.
auto clip_bounds() const noexcept -> xtd::drawing::rectangle_f
Gets a xtd::drawing::rectangle_f structure that bounds the clipping region of this xtd::drawing::grap...
auto draw_bezier(const xtd::drawing::pen &pen, const xtd::drawing::point &pt1, const xtd::drawing::point &pt2, const xtd::drawing::point &pt3, const xtd::drawing::point &pt4) -> void
Draws a Bézier spline defined by four Point structures.
auto flush() -> void
Forces execution of all pending graphics operations and returns immediately without waiting for the o...
auto restore(const xtd::drawing::drawing_2d::graphics_state &gstate) -> void
Restores the state of this xtd::drawing::graphics to the state represented by a xtd::drawing::drawing...
auto clip() const noexcept -> xtd::drawing::region
Gets a xtd::drawing::region that limits the drawing region of this xtd::drawing::graphics.
static auto from_hwnd(xtd::intptr hwnd) -> graphics
Creates a new xtd::drawing::graphics from the specified handle to a window.
auto draw_beziers(const pen &pen, const xtd::array< xtd::drawing::point > &points) -> void
Draws a series of Bézier splines from an array of xtd::drawing::point structures.
auto fill_rounded_rectangle(const xtd::drawing::brush &brush, const xtd::drawing::rectangle &rect, xtd::int32 radius) -> void
Fills the interior of a rounded rectangle specified by a xtd::drawing::rectangle structure.
auto reset_transform() -> void
Resets the world transformation matrix of this xtd::drawing::graphics to the identity matrix.
auto reset_clip() -> void
Resets the clip region of this xtd::drawing::graphics to an infinite region.
auto draw_rotated_string(const xtd::string &s, const xtd::drawing::font &font, const xtd::drawing::brush &brush, const xtd::drawing::point_f &point, float angle) -> void
Draws the specified text string at the specified location with the specified xtd::drawing::brush,...
auto compositing_quality() const noexcept -> xtd::drawing::drawing_2d::compositing_quality
Gets the rendering quality of composited images drawn to this xtd::drawing::graphics.
static auto from_hdc(xtd::intptr hdc, xtd::intptr hdevice) -> graphics
Creates a new xtd::drawing::graphics from the specified handle to a device contextand handle to a dev...
auto exclude_clip(const xtd::drawing::region ®ion) -> void
Updates the clip region of this xtd::drawing::graphics to exclude the area specified by a xtd::drawin...
auto dpi_y() const noexcept -> float
Gets the vertical resolution of this xtd::drawing::graphics.
auto save() -> xtd::drawing::drawing_2d::graphics_state
Saves the current state of this xtd::drawing::graphics and identifies the saved state with a xtd::dra...
auto fill_path(const xtd::drawing::brush &brush, const xtd::drawing::drawing_2d::graphics_path &path) -> void
Fills the interior of a xtd::drawing::drawing_2d::graphics_path.
auto multiply_transform(const xtd::drawing::drawing_2d::matrix &matrix) -> void
Multiplies the world transformation of this xtd::drawing::graphics and specified the xtd::drawing::dr...
auto handle() const noexcept -> xtd::intptr
Gets the handle device context that the graphics is bound to.
auto page_unit() const noexcept -> xtd::drawing::graphics_unit
Gets or sets the unit of measure used for page coordinates in this xtd::drawing::graphics.
auto draw_line(const xtd::drawing::pen &pen, const xtd::drawing::point &pt1, const point &pt2) -> void
Draws a line connecting two xtd::drawing::point structures.
auto transform() const noexcept -> xtd::drawing::drawing_2d::matrix
Gets a copy of the geometric world transformation for this xtd::drawing::graphics.
auto translate_transform(float dx, float dy) -> void
Changes the origin of the coordinate system by prepending the specified translation to the transforma...
auto draw_rounded_rectangle(const xtd::drawing::pen &pen, const xtd::drawing::rectangle &rect, xtd::int32 radius) -> void
Draws a rounded rectangle specified by a xtd::drawing::rectangle structure, and radius.
auto draw_lines(const xtd::drawing::pen &pen, const xtd::array< xtd::drawing::point > &points) -> void
Draws a series of line segments that connect an array of xtd::drawing::point structures.
auto fill_region(const xtd::drawing::brush &brush, const xtd::drawing::region ®ion) -> void
Fills the interior of a xtd::drawing::region.
auto draw_curve(const pen &pen, const xtd::array< xtd::drawing::point > &points) -> void
Draws a cardinal spline through a specified array of xtd::drawing::point structures.
auto rotate_transform(float angle) -> void
Applies the specified rotation to the transformation matrix of this xtd::drawing::graphics.
auto draw_closed_curve(const pen &pen, const xtd::array< xtd::drawing::point > &points) -> void
Draws a closed cardinal spline defined by an array of xtd::drawing::point structures.
auto draw_rectangle(const xtd::drawing::pen &pen, const xtd::drawing::rectangle &rect) -> void
Draws a rectangle specified by a xtd::drawing::rectangle structure.
Represents a Windows icon, which is a small bitmap image that is used to represent an object....
Definition icon.hpp:28
An abstract base class that provides functionality for the bitmap and metafile descended classes.
Definition image.hpp:49
Defines an object used to draw lines and curves. This class cannot be inherited.
Definition pen.hpp:32
Describes the interior of a graphics shape composed of rectangles and paths. This class cannot be inh...
Definition region.hpp:32
Supports all classes in the xtd class hierarchy and provides low-level services to derived classes....
Definition object.hpp:45
virtual auto get_type() const noexcept -> type_object
Gets the type of the current instance.
Contains xtd::drawing::drawing_2d::compositing_mode enum class.
Contains xtd::drawing::drawing_2d::compositing_quality enum class.
Contains xtd::drawing::copy_pixel_operation enum class.
Contains xtd::drawing::color class.
Contains drawing_export_ keyword.
Contains xtd::drawing::drawing_2d::flush_intention enum class.
Contains xtd::drawing::font class.
Contains xtd::drawing::drawing_2d::graphics_path class.
Contains xtd::drawing::drawing_2d::graphics_state class.
Contains xtd::drawing::graphics_unit enum class.
#define drawing_export_
Define shared library export.
Definition drawing_export.hpp:13
string_trimming
Specifies how to trim characters from a string that does not completely fit into a layout shape.
Definition string_trimming.hpp:17
xtd::shared_ptr_object< type_t > sptr
The xtd::sptr object is a shared pointer.
Definition sptr.hpp:25
std::intmax_t intptr
Represent a pointer or a handle.
Definition intptr.hpp:23
std::int32_t int32
Represents a 32-bit signed integer.
Definition int32.hpp:25
std::size_t usize
Represents an unsigned size of any object in bytes.
Definition usize.hpp:22
graphics_unit
Specifies the unit of measure for the given data. This enumeration has a flags attribute that allows ...
Definition graphics_unit.hpp:17
copy_pixel_operation
Determines how the source color in a copy pixel operation is combined with the destination color to r...
Definition copy_pixel_operation.hpp:18
Contains xtd::drawing::drawing_2d::interpolation_mode enum class.
Contains xtd::drawing::drawing_2d::matrix class.
Contains xtd::drawing::drawing_2d::matrix_order enum class.
The xtd::drawing::drawing_2d namespace provides advanced two-dimensional and vector graphics function...
Definition compositing_mode.hpp:12
The xtd::drawing::text namespace provides advanced GDI+ typography functionality.
Definition font_collection.hpp:14
The xtd::drawing namespace provides access to GDI+ basic graphics functionality. More advanced functi...
Definition actions_system_images.hpp:10
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8
constexpr auto data() const noexcept -> const_pointer
Gets direct access to the underlying contiguous storage.
Definition read_only_span.hpp:197
Contains xtd::drawing::pen class.
Contains xtd::drawing::drawing_2d::pixel_offset_mode enum class.
Contains xtd::drawing::point struct.
Contains xtd::drawing::point_f struct.
Contains xtd::drawing::rectangle struct.
Contains xtd::drawing::rectangle_f struct.
Contains xtd::drawing::region class.
Contains xtd::drawing::size struct.
Contains xtd::drawing::size_f struct.
Contains xtd::drawing::drawing_2d::smoothing_mode enum class.
Contains xtd::drawing::solid_brush class.
Represents an ordered pair of floating-point x- and y-coordinates that defines a point in a two-dimen...
Definition point_f.hpp:35
Represents an ordered pair of integer x- and y-coordinates that defines a point in a two-dimensional ...
Definition point.hpp:54
Stores a set of four floating-point numbers that represent the location and size of a rectangle....
Definition rectangle_f.hpp:34
Stores a set of four integers that represent the location and size of a rectangle.
Definition rectangle.hpp:44
Stores an ordered pair of floating-point, which specify a height and width.
Definition size_f.hpp:32
Stores an ordered pair of integers, which specify a height and width.
Definition size.hpp:32
Contains xtd::drawing::text::text_rendering_hint enum class.