xtd - Reference Guide 0.2.0
xtd::forms::style_sheets::control Class Reference

#include <control.h>

Definition

The control selector allows you to specify the box and color of a control.

Inheritance
xtd::objectxtd::forms::style_sheets::ibox_modelxtd::forms::style_sheets::control
Implements
xtd::forms::style_sheets::ibox_model, xtd::forms::style_sheets::itext_model, xtd::iequatable <>
Namespace
xtd::forms::style_sheets
Library
xtd.forms
Remarks
You need to know how the box model works.
For more information, see Box Model.

Constructors

 control ()=default
 Initializes a new instance of the xtd::forms::style_sheets::control class. More...
 

Properties

bool auto_ellipsis () const noexcept override
 Gets a value indicating whether the ellipsis character (...) appears at the right edge of the control, denoting that the control text extends beyond the specified length of the control. More...
 
controlauto_ellipsis (bool value) noexcept
 Sets a value indicating whether the ellipsis character (...) appears at the right edge of the control, denoting that the control text extends beyond the specified length of the control. More...
 
const xtd::drawing::colorbackground_color () const noexcept override
 Gets the background color is used to add background effects to the box. More...
 
controlbackground_color (const xtd::drawing::color &value) noexcept
 Sets the background color is used to add background effects to the box. More...
 
const xtd::forms::style_sheets::background_imagebackground_image () const noexcept override
 Gets the background image is used to add background effects to the box. More...
 
controlbackground_image (const xtd::forms::style_sheets::background_image &value) noexcept
 Sets the background image is used to add background effects to the box. More...
 
const xtd::forms::style_sheets::border_colorborder_color () const noexcept override
 Gets the color is used to set the color of the borders. More...
 
controlborder_color (const xtd::forms::style_sheets::border_color &value) noexcept
 Sets the color is used to set the color of the borders. More...
 
xtd::forms::style_sheets::border_radius border_radius () const noexcept override
 Gets the radius is used to add rounded borders to an element. More...
 
controlborder_radius (xtd::forms::style_sheets::border_radius value) noexcept
 Sets the radius is used to add rounded borders to an element. More...
 
xtd::forms::style_sheets::border_style border_style () const noexcept override
 Gets the style specifies what kind of borders to display. More...
 
controlborder_style (xtd::forms::style_sheets::border_style value) noexcept
 Sets the style specifies what kind of borders to display. More...
 
xtd::forms::style_sheets::border_width border_width () const noexcept override
 Gets the width specifies the width of the borders. More...
 
controlborder_width (xtd::forms::style_sheets::border_width value) noexcept
 Sets the width specifies the width of the border. More...
 
const xtd::drawing::colorcolor () const noexcept override
 Gets the color is used to add foreground effects to the text. More...
 
controlcolor (const xtd::drawing::color &value) noexcept
 Sets the color is used to add foreground effects to the text. More...
 
xtd::forms::style_sheets::text_decoration decoration () const noexcept override
 Gets the decoration of the text. More...
 
controldecoration (xtd::forms::style_sheets::text_decoration value) noexcept
 Sets the decoration of the text. More...
 
const xtd::drawing::fontfont () const noexcept override
 Gets the font of the text. More...
 
controlfont (const xtd::drawing::font &value) noexcept
 Sets the font of the text. More...
 
std::optional< xtd::forms::style_sheets::lengthheight () const noexcept override
 Gets the height of the box. More...
 
controlheight (const std::optional< xtd::forms::style_sheets::length > &value) noexcept
 Sets the height of the box. More...
 
xtd::forms::content_alignment image_alignment () const noexcept override
 Gets the alignment of the image. More...
 
controlimage_alignment (xtd::forms::content_alignment value) noexcept
 Sets the alignment of the image. More...
 
const xtd::forms::style_sheets::marginmargin () const noexcept override
 Gets the area outside the border. More...
 
controlmargin (const xtd::forms::style_sheets::margin &value) noexcept
 Sets the area outside the border. More...
 
const xtd::forms::style_sheets::outline_coloroutline_color () const noexcept override
 Gets the color is used to set the color of the outlines. More...
 
controloutline_color (const xtd::forms::style_sheets::outline_color &value) noexcept
 Sets the color is used to set the color of the outlines. More...
 
xtd::forms::style_sheets::outline_offset outline_offset () const noexcept override
 Gets the ofset specifies the width of the outlines. More...
 
controloutline_offset (xtd::forms::style_sheets::outline_offset value) noexcept
 Sets the width specifies the offset of the outlines. More...
 
xtd::forms::style_sheets::outline_radius outline_radius () const noexcept override
 Gets the radius is used to add rounded outline to an element. More...
 
controloutline_radius (xtd::forms::style_sheets::outline_radius value) noexcept
 Sets the radius is used to add rounded outlines to an element. More...
 
xtd::forms::style_sheets::outline_style outline_style () const noexcept override
 Gets the style specifies what kind of outlines to display. More...
 
controloutline_style (xtd::forms::style_sheets::outline_style value) noexcept
 Sets the style specifies what kind of outlines to display. More...
 
xtd::forms::style_sheets::outline_width outline_width () const noexcept override
 Gets the width specifies the width of the outlines. More...
 
controloutline_width (xtd::forms::style_sheets::outline_width value) noexcept
 Sets the width specifies the width of the outlines. More...
 
const xtd::forms::style_sheets::paddingpadding () const noexcept override
 Gets the area area around the content. More...
 
controlpadding (const xtd::forms::style_sheets::padding &value) noexcept
 Sets the area area around the content. More...
 
xtd::forms::content_alignment text_alignment () const noexcept override
 Gets the alignment of the text. More...
 
controltext_alignment (xtd::forms::content_alignment value) noexcept
 Sets the alignment of the text. More...
 
xtd::forms::style_sheets::text_transformation transformation () const noexcept override
 Gets the transformation of the text. More...
 
controltransformation (xtd::forms::style_sheets::text_transformation value) noexcept
 Sets the transformation of the text. More...
 
std::optional< xtd::forms::style_sheets::lengthwidth () const noexcept override
 Gets the width of the box. More...
 
controlwidth (std::optional< xtd::forms::style_sheets::length > value) noexcept
 Sets the width of the box. More...
 
xtd::forms::style_sheets::white_space white_space () const noexcept override
 Gets how white-space inside an element is handled. More...
 
controlwhite_space (xtd::forms::style_sheets::white_space value) noexcept
 Sets how white-space inside an element is handled. More...
 

Methods

bool equals (const object &other) const noexcept override
 Determines whether the specified object is equal to the current object. More...
 
bool equals (const control &other) const noexcept override
 
xtd::drawing::color get_solid_background_color () const noexcept
 
xtd::drawing::rectangle get_border_rectangle (const xtd::drawing::rectangle &bounds) const noexcept override
 Gets the computed boder rectangle from specified bounds. More...
 
xtd::drawing::rectangle get_fill_rectangle (const xtd::drawing::rectangle &bounds) const noexcept override
 Gets the computed fill rectangle from specified bounds. More...
 
xtd::drawing::rectangle get_outline_rectangle (const xtd::drawing::rectangle &bounds) const noexcept override
 Gets the computed outline rectangle from specified bounds. More...
 
xtd::drawing::rectangle get_content_rectangle (const xtd::drawing::rectangle &bounds) const noexcept override
 Gets the computed content rectangle from specified bounds. More...
 
xtd::drawing::string_format make_string_format () const noexcept override
 Gets the string format of the text. More...
 
static control create_control ()
 

Additional Inherited Members

- Public Member Functions inherited from xtd::forms::style_sheets::ibox_model
- Public Member Functions inherited from xtd::forms::style_sheets::itext_model
- Public Member Functions inherited from xtd::forms::style_sheets::iimage_model
- Public Member Functions inherited from xtd::iequatable< control >
virtual bool equals (const control &) const noexcept=0
 Indicates whether the current object is equal to another object of the same type. More...
 
- Public Member Functions inherited from xtd::object
 object ()=default
 Create a new instance of the ultimate base class object. More...
 
virtual size_t get_hash_code () const noexcept
 Serves as a hash function for a particular type. More...
 
template<typename object_t >
std::unique_ptr< object_t > memberwise_clone () const
 Gets the type of the current instance. More...
 
virtual xtd::ustring to_string () const noexcept
 Returns a sxd::ustring that represents the current object. More...
 
- Static Public Member Functions inherited from xtd::object
static bool equals (const object &object_a, const object &object_b) noexcept
 Determines whether the specified object instances are considered equal. More...
 
static bool reference_equals (const object &object_a, const object &object_b) noexcept
 Determines whether the specified object instances are the same instance. More...
 

Constructor & Destructor Documentation

◆ control()

xtd::forms::style_sheets::control::control ( )
default

Initializes a new instance of the xtd::forms::style_sheets::control class.

Remarks
You need to know how the box model works.
For more information, see Box Model.

Member Function Documentation

◆ auto_ellipsis() [1/2]

bool xtd::forms::style_sheets::control::auto_ellipsis ( ) const
overridevirtualnoexcept

Gets a value indicating whether the ellipsis character (...) appears at the right edge of the control, denoting that the control text extends beyond the specified length of the control.

Returns
true if the additional control text is to be indicated by an ellipsis; otherwise, false.

Implements xtd::forms::style_sheets::itext_model.

◆ auto_ellipsis() [2/2]

control& xtd::forms::style_sheets::control::auto_ellipsis ( bool  value)
noexcept

Sets a value indicating whether the ellipsis character (...) appears at the right edge of the control, denoting that the control text extends beyond the specified length of the control.

Parameters
valuetrue if the additional control text is to be indicated by an ellipsis; otherwise, false.
Returns
This current instance.

◆ background_color() [1/2]

const xtd::drawing::color& xtd::forms::style_sheets::control::background_color ( ) const
overridevirtualnoexcept

Gets the background color is used to add background effects to the box.

Returns
The background color is used to add background effects to the box.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ background_color() [2/2]

control& xtd::forms::style_sheets::control::background_color ( const xtd::drawing::color value)
noexcept

Sets the background color is used to add background effects to the box.

Parameters
valueThe background color is used to add background effects to the box.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ background_image() [1/2]

const xtd::forms::style_sheets::background_image& xtd::forms::style_sheets::control::background_image ( ) const
overridevirtualnoexcept

Gets the background image is used to add background effects to the box.

Returns
The background image is used to add background effects to the box.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ background_image() [2/2]

control& xtd::forms::style_sheets::control::background_image ( const xtd::forms::style_sheets::background_image value)
noexcept

Sets the background image is used to add background effects to the box.

Parameters
valueThe background image is used to add background effects to the box.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ border_color() [1/2]

const xtd::forms::style_sheets::border_color& xtd::forms::style_sheets::control::border_color ( ) const
overridevirtualnoexcept

Gets the color is used to set the color of the borders.

Returns
The color is used to set the color of the borders.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ border_color() [2/2]

control& xtd::forms::style_sheets::control::border_color ( const xtd::forms::style_sheets::border_color value)
noexcept

Sets the color is used to set the color of the borders.

Parameters
valueThe color is used to set the color of the borders.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ border_radius() [1/2]

xtd::forms::style_sheets::border_radius xtd::forms::style_sheets::control::border_radius ( ) const
overridevirtualnoexcept

Gets the radius is used to add rounded borders to an element.

Returns
The radius is used to add rounded borders to an element.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ border_radius() [2/2]

control& xtd::forms::style_sheets::control::border_radius ( xtd::forms::style_sheets::border_radius  value)
noexcept

Sets the radius is used to add rounded borders to an element.

Parameters
valueThe radius is used to add rounded borders to an element.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ border_style() [1/2]

xtd::forms::style_sheets::border_style xtd::forms::style_sheets::control::border_style ( ) const
overridevirtualnoexcept

Gets the style specifies what kind of borders to display.

Returns
The style specifies what kind of borders to display.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ border_style() [2/2]

control& xtd::forms::style_sheets::control::border_style ( xtd::forms::style_sheets::border_style  value)
noexcept

Sets the style specifies what kind of borders to display.

Parameters
valueThe style specifies what kind of borders to display.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ border_width() [1/2]

xtd::forms::style_sheets::border_width xtd::forms::style_sheets::control::border_width ( ) const
overridevirtualnoexcept

Gets the width specifies the width of the borders.

Returns
The width specifies the width of the borders.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ border_width() [2/2]

control& xtd::forms::style_sheets::control::border_width ( xtd::forms::style_sheets::border_width  value)
noexcept

Sets the width specifies the width of the border.

Parameters
valueThe width specifies the width of the borders.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ color() [1/2]

const xtd::drawing::color& xtd::forms::style_sheets::control::color ( ) const
overridevirtualnoexcept

Gets the color is used to add foreground effects to the text.

Returns
The color is used to add foreground effects to the text.

Implements xtd::forms::style_sheets::itext_model.

◆ color() [2/2]

control& xtd::forms::style_sheets::control::color ( const xtd::drawing::color value)
noexcept

Sets the color is used to add foreground effects to the text.

Parameters
valueThe color is used to add foreground effects to the text.

◆ decoration() [1/2]

xtd::forms::style_sheets::text_decoration xtd::forms::style_sheets::control::decoration ( ) const
overridevirtualnoexcept

Gets the decoration of the text.

Returns
One of xtd::forms::style_sheets::text_decoration values.

Implements xtd::forms::style_sheets::itext_model.

◆ decoration() [2/2]

control& xtd::forms::style_sheets::control::decoration ( xtd::forms::style_sheets::text_decoration  value)
noexcept

Sets the decoration of the text.

Parameters
valueOne of xtd::forms::style_sheets::text_decoration values.
Returns
This current instance.

◆ equals()

bool xtd::forms::style_sheets::control::equals ( const object obj) const
overridevirtualnoexcept

Determines whether the specified object is equal to the current object.

Parameters
objThe object to compare with the current object.
Returns
true if the specified object is equal to the current object. otherwise, false.
Examples
The following code example compares the current instance with another object.

Reimplemented from xtd::object.

◆ font() [1/2]

const xtd::drawing::font& xtd::forms::style_sheets::control::font ( ) const
overridevirtualnoexcept

Gets the font of the text.

Returns
The font of the text.

Implements xtd::forms::style_sheets::itext_model.

◆ font() [2/2]

control& xtd::forms::style_sheets::control::font ( const xtd::drawing::font value)
noexcept

Sets the font of the text.

Returns
This current instance.
Parameters
valueThe font of the text.

◆ get_border_rectangle()

xtd::drawing::rectangle xtd::forms::style_sheets::control::get_border_rectangle ( const xtd::drawing::rectangle bounds) const
overridevirtualnoexcept

Gets the computed boder rectangle from specified bounds.

Parameters
boundsThe bounds use to compute the borfder rectangle with this box instance.
Returns
The computed boder rectangle from specified bounds.
Remarks
The border rectangle is euqual to bounds rectangle minus margin.

Implements xtd::forms::style_sheets::ibox_model.

◆ get_content_rectangle()

xtd::drawing::rectangle xtd::forms::style_sheets::control::get_content_rectangle ( const xtd::drawing::rectangle bounds) const
overridevirtualnoexcept

Gets the computed content rectangle from specified bounds.

Parameters
boundsThe bounds use to compute the content rectangle with this box instance.
Returns
The content boder rectangle from specified bounds.
Remarks
The content rectangle is euqual to fill rectangle minus padding.
The content rectangle is euqual to border rectangle minux border width minus padding.

Implements xtd::forms::style_sheets::ibox_model.

◆ get_fill_rectangle()

xtd::drawing::rectangle xtd::forms::style_sheets::control::get_fill_rectangle ( const xtd::drawing::rectangle bounds) const
overridevirtualnoexcept

Gets the computed fill rectangle from specified bounds.

Parameters
boundsThe bounds use to compute the fill rectangle with this box instance.
Returns
The computed boder rectangle from specified bounds.
Remarks
The fill rectangle is euqual to border rectangle minus border width.
The fill rectangle is euqual to content rectangle plus padding.

Implements xtd::forms::style_sheets::ibox_model.

◆ get_outline_rectangle()

xtd::drawing::rectangle xtd::forms::style_sheets::control::get_outline_rectangle ( const xtd::drawing::rectangle bounds) const
overridevirtualnoexcept

Gets the computed outline rectangle from specified bounds.

Parameters
boundsThe bounds use to compute the outline rectangle with this box instance.
Returns
The computed boder rectangle from specified bounds.
Remarks
The outline rectangle is euqual to bounds rectangle minus margin + 1 + outline offset.

Implements xtd::forms::style_sheets::ibox_model.

◆ height() [1/2]

std::optional<xtd::forms::style_sheets::length> xtd::forms::style_sheets::control::height ( ) const
overridevirtualnoexcept

Gets the height of the box.

Returns
The height of the box.
Remarks
You need to know how the box model works.
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ height() [2/2]

control& xtd::forms::style_sheets::control::height ( const std::optional< xtd::forms::style_sheets::length > &  value)
noexcept

Sets the height of the box.

Returns
The height of the box.
This current instance.
Remarks
You need to know how the box model works.
For more information, see Box Model.

◆ image_alignment() [1/2]

xtd::forms::content_alignment xtd::forms::style_sheets::control::image_alignment ( ) const
overridevirtualnoexcept

Gets the alignment of the image.

Returns
A combination of xtd::forms::content_alignment values.

Implements xtd::forms::style_sheets::iimage_model.

◆ image_alignment() [2/2]

control& xtd::forms::style_sheets::control::image_alignment ( xtd::forms::content_alignment  value)
noexcept

Sets the alignment of the image.

Parameters
valueA combination of xtd::forms::content_alignment values.
Returns
This current instance.

◆ make_string_format()

xtd::drawing::string_format xtd::forms::style_sheets::control::make_string_format ( ) const
overridevirtualnoexcept

Gets the string format of the text.

Returns
The string format used by xtd::drawing::graphics::draw_text method to draw a text.

Implements xtd::forms::style_sheets::itext_model.

◆ margin() [1/2]

const xtd::forms::style_sheets::margin& xtd::forms::style_sheets::control::margin ( ) const
overridevirtualnoexcept

Gets the area outside the border.

Returns
The area outside the border.
Remarks
The margin is transparent.
You need to know how the box model works.
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ margin() [2/2]

control& xtd::forms::style_sheets::control::margin ( const xtd::forms::style_sheets::margin value)
noexcept

Sets the area outside the border.

Parameters
valueThe area outside the border.
Returns
This current instance.
Remarks
The margin is transparent.
You need to know how the box model works.
For more information, see Box Model.

◆ outline_color() [1/2]

const xtd::forms::style_sheets::outline_color& xtd::forms::style_sheets::control::outline_color ( ) const
overridevirtualnoexcept

Gets the color is used to set the color of the outlines.

Returns
The color is used to set the color of the outlines.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ outline_color() [2/2]

control& xtd::forms::style_sheets::control::outline_color ( const xtd::forms::style_sheets::outline_color value)
noexcept

Sets the color is used to set the color of the outlines.

Parameters
valueThe color is used to set the color of the outlines.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ outline_offset() [1/2]

xtd::forms::style_sheets::outline_offset xtd::forms::style_sheets::control::outline_offset ( ) const
overridevirtualnoexcept

Gets the ofset specifies the width of the outlines.

Returns
The offset specifies the width of the outlines.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ outline_offset() [2/2]

control& xtd::forms::style_sheets::control::outline_offset ( xtd::forms::style_sheets::outline_offset  value)
noexcept

Sets the width specifies the offset of the outlines.

Parameters
valueThe width specifies the offset of the outlines.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ outline_radius() [1/2]

xtd::forms::style_sheets::outline_radius xtd::forms::style_sheets::control::outline_radius ( ) const
overridevirtualnoexcept

Gets the radius is used to add rounded outline to an element.

Returns
The radius is used to add rounded outline to an element.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ outline_radius() [2/2]

control& xtd::forms::style_sheets::control::outline_radius ( xtd::forms::style_sheets::outline_radius  value)
noexcept

Sets the radius is used to add rounded outlines to an element.

Parameters
valueThe radius is used to add rounded outlines to an element.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ outline_style() [1/2]

xtd::forms::style_sheets::outline_style xtd::forms::style_sheets::control::outline_style ( ) const
overridevirtualnoexcept

Gets the style specifies what kind of outlines to display.

Returns
The style specifies what kind of outlines to display.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ outline_style() [2/2]

control& xtd::forms::style_sheets::control::outline_style ( xtd::forms::style_sheets::outline_style  value)
noexcept

Sets the style specifies what kind of outlines to display.

Parameters
valueThe style specifies what kind of outlines to display.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ outline_width() [1/2]

xtd::forms::style_sheets::outline_width xtd::forms::style_sheets::control::outline_width ( ) const
overridevirtualnoexcept

Gets the width specifies the width of the outlines.

Returns
The width specifies the width of the outlines.
Remarks
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ outline_width() [2/2]

control& xtd::forms::style_sheets::control::outline_width ( xtd::forms::style_sheets::outline_width  value)
noexcept

Sets the width specifies the width of the outlines.

Parameters
valueThe width specifies the width of the outlines.
Returns
This current instance.
Remarks
For more information, see Box Model.

◆ padding() [1/2]

const xtd::forms::style_sheets::padding& xtd::forms::style_sheets::control::padding ( ) const
overridevirtualnoexcept

Gets the area area around the content.

Returns
The area around the content.
Remarks
The padding is transparent.
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ padding() [2/2]

control& xtd::forms::style_sheets::control::padding ( const xtd::forms::style_sheets::padding value)
noexcept

Sets the area area around the content.

Parameters
valueThe area around the content.
Returns
This current instance.
Remarks
The padding is transparent.
For more information, see Box Model.

◆ text_alignment() [1/2]

xtd::forms::content_alignment xtd::forms::style_sheets::control::text_alignment ( ) const
overridevirtualnoexcept

Gets the alignment of the text.

Returns
A combination of xtd::forms::content_alignment values.

Implements xtd::forms::style_sheets::itext_model.

◆ text_alignment() [2/2]

control& xtd::forms::style_sheets::control::text_alignment ( xtd::forms::content_alignment  value)
noexcept

Sets the alignment of the text.

Parameters
valueA combination of xtd::forms::content_alignment values.
Returns
This current instance.

◆ transformation() [1/2]

xtd::forms::style_sheets::text_transformation xtd::forms::style_sheets::control::transformation ( ) const
overridevirtualnoexcept

Gets the transformation of the text.

Returns
One of xtd::forms::style_sheets::text_transformation values.

Implements xtd::forms::style_sheets::itext_model.

◆ transformation() [2/2]

control& xtd::forms::style_sheets::control::transformation ( xtd::forms::style_sheets::text_transformation  value)
noexcept

Sets the transformation of the text.

Parameters
valueOne of xtd::forms::style_sheets::text_transformation values.
Returns
This current instance.

◆ white_space() [1/2]

xtd::forms::style_sheets::white_space xtd::forms::style_sheets::control::white_space ( ) const
overridevirtualnoexcept

Gets how white-space inside an element is handled.

Returns
One of xtd::forms::style_sheets::white_space values.

Implements xtd::forms::style_sheets::itext_model.

◆ white_space() [2/2]

control& xtd::forms::style_sheets::control::white_space ( xtd::forms::style_sheets::white_space  value)
noexcept

Sets how white-space inside an element is handled.

Parameters
valueOne of xtd::forms::style_sheets::white_space values.
Returns
This current instance.

◆ width() [1/2]

std::optional<xtd::forms::style_sheets::length> xtd::forms::style_sheets::control::width ( ) const
overridevirtualnoexcept

Gets the width of the box.

Returns
The width of the box.
Remarks
You need to know how the box model works.
For more information, see Box Model.

Implements xtd::forms::style_sheets::ibox_model.

◆ width() [2/2]

control& xtd::forms::style_sheets::control::width ( std::optional< xtd::forms::style_sheets::length value)
noexcept

Sets the width of the box.

Parameters
valueThe width of the box.
Returns
This current instance.
Remarks
You need to know how the box model works.
For more information, see Box Model.

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