xtd - Reference Guide
0.1.0
Modern c++17/20 framework to create console, GUI and unit test applications on Windows, macOS, Linux, iOS and android.
Loading...
Searching...
No Matches
xtd.forms
include
xtd
forms
horizontal_control_layout_style.h
Go to the documentation of this file.
1
4
#pragma once
5
#include <optional>
6
#include "
control_layout_style.h
"
7
9
namespace
xtd
{
11
namespace
forms
{
18
class
horizontal_control_layout_style
:
public
control_layout_style
{
19
public
:
21
horizontal_control_layout_style
() =
default
;
24
horizontal_control_layout_style
(
float
width
) : width_(
width
) {}
27
horizontal_control_layout_style
(int32_t
width
) : width_(static_cast<float>(
width
)) {}
30
horizontal_control_layout_style
(
xtd::forms::size_type
size_type
) :
control_layout_style
(
size_type
) {}
34
horizontal_control_layout_style
(
float
width
,
xtd::forms::size_type
size_type
) :
control_layout_style
(
size_type
), width_(
width
) {}
38
horizontal_control_layout_style
(int32_t
width
,
xtd::forms::size_type
size_type
) :
control_layout_style
(
size_type
), width_(static_cast<float>(
width
)) {}
41
horizontal_control_layout_style
(
bool
expanded
) :
control_layout_style
(
expanded
) {}
45
horizontal_control_layout_style
(
float
width
,
bool
expanded
) :
control_layout_style
(
expanded
), width_(
width
) {}
49
horizontal_control_layout_style
(int32_t
width
,
bool
expanded
) :
control_layout_style
(
expanded
), width_(static_cast<float>(
width
)) {}
52
horizontal_control_layout_style
(
xtd::forms::content_alignment
align
) :
control_layout_style
(
align
) {}
56
horizontal_control_layout_style
(
float
width
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
align
), width_(
width
) {}
60
horizontal_control_layout_style
(int32_t
width
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
align
), width_(static_cast<float>(
width
)) {}
64
horizontal_control_layout_style
(
xtd::forms::size_type
size_type
,
bool
expanded
) :
control_layout_style
(
size_type
,
expanded
) {}
69
horizontal_control_layout_style
(
float
width
,
xtd::forms::size_type
size_type
,
bool
expanded
) :
control_layout_style
(
size_type
,
expanded
), width_(
width
) {}
74
horizontal_control_layout_style
(int32_t
width
,
xtd::forms::size_type
size_type
,
bool
expanded
) :
control_layout_style
(
size_type
,
expanded
), width_(static_cast<float>(
width
)) {}
78
horizontal_control_layout_style
(
xtd::forms::size_type
size_type
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
size_type
,
align
) {}
83
horizontal_control_layout_style
(
float
width
,
xtd::forms::size_type
size_type
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
size_type
,
align
), width_(
width
) {}
88
horizontal_control_layout_style
(int32_t
width
,
xtd::forms::size_type
size_type
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
size_type
,
align
), width_(static_cast<float>(
width
)) {}
93
horizontal_control_layout_style
(
xtd::forms::size_type
size_type
,
bool
expanded
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
size_type
,
expanded
,
align
) {}
99
horizontal_control_layout_style
(
float
width
,
xtd::forms::size_type
size_type
,
bool
expanded
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
size_type
,
expanded
,
align
), width_(
width
) {}
105
horizontal_control_layout_style
(int32_t
width
,
xtd::forms::size_type
size_type
,
bool
expanded
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
size_type
,
expanded
,
align
), width_(static_cast<float>(
width
)) {}
109
horizontal_control_layout_style
(
bool
expanded
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
expanded
,
align
) {}
114
horizontal_control_layout_style
(
float
width
,
bool
expanded
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
expanded
,
align
), width_(
width
) {}
119
horizontal_control_layout_style
(int32_t
width
,
bool
expanded
,
xtd::forms::content_alignment
align
) :
control_layout_style
(
expanded
,
align
), width_(static_cast<float>(
width
)) {}
120
123
std::optional<float>
width
()
const
{
return
width_;}
126
void
width
(
float
width
) {width_ =
width
;}
127
130
xtd::ustring
to_string
() const noexcept
override
{
return
ustring::format
(
"horizontal_control_layout_style=[expanded={}, align={}, size_type={}, width={}]"
,
expanded
(),
align
(),
size_type
(), width_.value_or(-1));}
131
133
bool
operator==(
const
horizontal_control_layout_style
& value)
const
{
return
width_ == value.width_ && control_layout_style::operator==(value);}
134
bool
operator!=(
const
horizontal_control_layout_style
& value)
const
{
return
!operator==(value);}
135
friend
std::ostream& operator<<(std::ostream& os,
const
xtd::forms::horizontal_control_layout_style
&
control_layout_style
)
noexcept
{
136
return
os <<
control_layout_style
.to_string();
137
}
139
140
private
:
141
std::optional<float> width_;
142
};
143
}
144
}
xtd::forms::control_layout_style
Implements the basic functionality that represents the appearance and behavior of a control layout.
Definition:
control_layout_style.h:20
xtd::forms::control_layout_style::control_layout_style
control_layout_style()=default
Initialises a new instance of control layout style class.
xtd::forms::control_layout_style::align
xtd::forms::content_alignment align() const
Gets a flag indicating how a control should be align to its containing layout container.
Definition:
control_layout_style.h:76
xtd::forms::control_layout_style::size_type
xtd::forms::size_type size_type() const
Gets a flag indicating how a control should be sized relative to its containing layout container.
Definition:
control_layout_style.h:55
xtd::forms::control_layout_style::expanded
bool expanded() const
Gets a flag indicating if control is expanded to its containing layout container.
Definition:
control_layout_style.h:65
xtd::forms::horizontal_control_layout_style
Implements the basic functionality that represents the appearance and behavior of a control layout.
Definition:
horizontal_control_layout_style.h:18
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(int32_t width, xtd::forms::size_type size_type, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified width,...
Definition:
horizontal_control_layout_style.h:88
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(float width)
Initialises a new instance of horizontal control layout style class with specified width.
Definition:
horizontal_control_layout_style.h:24
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(xtd::forms::size_type size_type, bool expanded, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified size type,...
Definition:
horizontal_control_layout_style.h:93
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(int32_t width, xtd::forms::size_type size_type, bool expanded, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified width,...
Definition:
horizontal_control_layout_style.h:105
xtd::forms::horizontal_control_layout_style::to_string
xtd::ustring to_string() const noexcept override
Returns a string that represent xtd::forms::control_layout_style.
Definition:
horizontal_control_layout_style.h:130
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(int32_t width)
Initialises a new instance of horizontal control layout style class with specified width.
Definition:
horizontal_control_layout_style.h:27
xtd::forms::horizontal_control_layout_style::width
std::optional< float > width() const
Gets the width value for a control.
Definition:
horizontal_control_layout_style.h:123
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(int32_t width, bool expanded)
Initialises a new instance of horizontal control layout style class with specified width and expanded...
Definition:
horizontal_control_layout_style.h:49
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(int32_t width, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified width and content ...
Definition:
horizontal_control_layout_style.h:60
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(float width, bool expanded)
Initialises a new instance of horizontal control layout style class with specified width and expanded...
Definition:
horizontal_control_layout_style.h:45
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(xtd::forms::size_type size_type, bool expanded)
Initialises a new instance of horizontal control layout style class with specified size type and expa...
Definition:
horizontal_control_layout_style.h:64
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(float width, xtd::forms::size_type size_type, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified width,...
Definition:
horizontal_control_layout_style.h:83
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(float width, bool expanded, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified expanded and conte...
Definition:
horizontal_control_layout_style.h:114
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified content alignment.
Definition:
horizontal_control_layout_style.h:52
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(float width, xtd::forms::size_type size_type, bool expanded, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified width,...
Definition:
horizontal_control_layout_style.h:99
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(float width, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified width and content ...
Definition:
horizontal_control_layout_style.h:56
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style()=default
Initialises a new instance of horizontal control layout style class.
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(int32_t width, xtd::forms::size_type size_type)
Initialises a new instance of horizontal control layout style class with specified width and size typ...
Definition:
horizontal_control_layout_style.h:38
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(int32_t width, xtd::forms::size_type size_type, bool expanded)
Initialises a new instance of horizontal control layout style class with specified width,...
Definition:
horizontal_control_layout_style.h:74
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(bool expanded)
Initialises a new instance of horizontal control layout style class with specified expanded.
Definition:
horizontal_control_layout_style.h:41
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(int32_t width, bool expanded, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified expanded and conte...
Definition:
horizontal_control_layout_style.h:119
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(float width, xtd::forms::size_type size_type, bool expanded)
Initialises a new instance of horizontal control layout style class with specified width,...
Definition:
horizontal_control_layout_style.h:69
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(xtd::forms::size_type size_type)
Initialises a new instance of horizontal control layout style class with specified size type.
Definition:
horizontal_control_layout_style.h:30
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(bool expanded, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified expanded and conte...
Definition:
horizontal_control_layout_style.h:109
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(float width, xtd::forms::size_type size_type)
Initialises a new instance of horizontal control layout style class with specified width and size typ...
Definition:
horizontal_control_layout_style.h:34
xtd::forms::horizontal_control_layout_style::horizontal_control_layout_style
horizontal_control_layout_style(xtd::forms::size_type size_type, xtd::forms::content_alignment align)
Initialises a new instance of horizontal control layout style class with specified size type and cont...
Definition:
horizontal_control_layout_style.h:78
xtd::forms::horizontal_control_layout_style::width
void width(float width)
Sets the width value for a control.
Definition:
horizontal_control_layout_style.h:126
xtd::ustring
Represents text as a sequence of UTF-8 code units.
Definition:
ustring.h:48
control_layout_style.h
Contains xtd::forms::control_layout_style class.
xtd::ustring::format
static ustring format(const ustring &fmt, args_t &&... args)
Writes the text representation of the specified arguments list, to string using the specified format ...
Definition:
ustring.h:689
xtd::forms::size_type
size_type
Specifies how rows or columns of user interface (UI) elements should be sized relative to their conta...
Definition:
size_type.h:18
xtd::forms::content_alignment
content_alignment
Specifies alignment of content on the drawing surface.
Definition:
content_alignment.h:17
xtd::forms
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition:
about_box.h:13
xtd
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition:
system_report.h:17
Generated on Sat Jan 28 2023 18:12:25 for xtd - Reference Guide by
Gammasoft
. All rights reserved.