Skip to content

Commit fbbeaa1

Browse files
committed
Review documentation
1 parent 2a0043a commit fbbeaa1

File tree

777 files changed

+10529
-10529
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

777 files changed

+10529
-10529
lines changed

docs/doxygen/doxygen/cmake_commands_page.dox

Lines changed: 68 additions & 68 deletions
Large diffs are not rendered by default.

docs/doxygen/doxygen/format_page.dox

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -40,23 +40,23 @@
4040
/// * Overriding the operator << object method to define a custom string representation of an object’s value. For more information, see the @ref OverridingShiftLeftoperatorMethodSection section later in this topic.
4141
/// * Defining format specifiers that enable the string representation of an object’s value to take multiple forms. For example, the "X" format specifier in the following statement converts an integer to the string representation of a hexadecimal value.
4242
///
43-
/// @code
43+
/// ```cpp
4444
/// int integer_value = 60312;
4545
/// xtd::console::write_line(xtd::to_string(integer_value, "X")); // Displays EB98.
46-
/// @endcode
46+
/// ```
4747
///
4848
/// For more information about format specifiers, see the @ref ToStringMethodAndFormatStringsSection section.
4949
///
5050
/// * Using format providers to take advantage of the formatting conventions of a specific culture. For example, the following statement displays a currency value by using the formatting conventions of the en-US culture.
5151
///
52-
/// @code
52+
/// ```cpp
5353
/// double cost = 1632.54;
5454
/// xtd::console::write_line(xtd::to_string(cost, "C", std::locale("en_US.UTF-8")));
5555
///
5656
/// // The example displays the following output:
5757
/// //
5858
/// // $1,632.54
59-
/// @endcode
59+
/// ```
6060
///
6161
/// For more information about formatting with format providers, see the @ref CultureSensitiveFormattingSection section.
6262
///
@@ -80,10 +80,10 @@
8080
///
8181
/// Consider the following Format code fragment.
8282
///
83-
/// @code
83+
/// ```cpp
8484
/// string name = "Fred";
8585
/// xtd::ustring::format("Name = {0}, age = {1:D3}", name, 42);
86-
/// @endcode
86+
/// ```
8787
///
8888
/// The fixed text is "Name = " and ", age = ". The format items are "{0}", whose index is 0, which corresponds to the object name, and "{1:D3}", whose index is 1, which corresponds to the integer 42.
8989
///
@@ -99,45 +99,45 @@
9999
///
100100
/// The optional index component, also called a parameter specifier, is a number starting from 0 that identifies a corresponding item in the list of objects. That is, the format item whose parameter specifier is 0 formats the first object in the list, the format item whose parameter specifier is 1 formats the second object in the list, and so on. The following example includes four parameter specifiers, numbered zero through three, to represent prime numbers less than ten:
101101
///
102-
/// @code
102+
/// ```cpp
103103
/// std::string primes;
104104
/// primes = xtd::ustring::format("Prime numbers less than 10: {0}, {1}, {2}, {3}", 2, 3, 5, 7 );
105105
/// std::cout << primes << std::endl;
106106
/// // The example displays the following output:
107107
/// //
108108
/// // Prime numbers less than 10: 2, 3, 5, 7
109-
/// @endcode
109+
/// ```
110110
///
111111
/// Multiple format items can refer to the same element in the list of objects by specifying the same parameter specifier. For example, you can format the same numeric value in hexadecimal, scientific, and number format by specifying a composite format string such as : "0x{0:X} {0:E} {0:N}", as the following example shows.
112112
///
113-
/// @code
113+
/// ```cpp
114114
/// std::string multiple = xtd::ustring::format("0x{0:X} {0:E} {0:N}", std::numeric_limits<long long>::max());
115115
/// std::cout << multiple << std::endl;
116116
/// // The example displays the following output:
117117
/// //
118118
/// // 0x7FFFFFFFFFFFFFFF 9.223372E+18 9,223,372,036,854,775,807.00
119-
/// @endcode
119+
/// ```
120120
///
121121
/// Each format item can refer to any object in the list. For example, if there are three objects, you can format the second, first, and third object by specifying a composite format string like this: "{1} {0} {2}". An object that is not referenced by a format item is ignored. A std::argument_error is thrown at runtime if a parameter specifier designates an item outside the bounds of the list of objects.
122122
///
123123
/// If the index component is not specified, it will be automatically generated in the order of the argument list.
124124
///
125125
/// The following example shows format without specified index:
126126
///
127-
/// @code
127+
/// ```cpp
128128
/// std::cout << xtd::ustring::format("{} {} {:F2}", 1, "two", 3.0) << std::endl;
129129
/// // The example displays the following output:
130130
/// //
131131
/// // 1 two 3.00
132-
/// @endcode
132+
/// ```
133133
///
134134
/// @subsubsection AlignmentComponentSection Alignment Component
135135
///
136136
/// The optional alignment component is a signed integer indicating the preferred formatted field width. If the value of alignment is less than the length of the formatted string, alignment is ignored and the length of the formatted string is used as the field width. The formatted data in the field is right-aligned if alignment is positive and left-aligned if alignment is negative. If padding is necessary, white space is used. The comma is required if alignment is specified.
137137
///
138138
/// The following example defines two arrays, one containing the names of employees and the other containing the hours they worked over a two-week period. The composite format string left-aligns the names in a 20-character field, and right-aligns their hours in a 5-character field. Note that the "N1" standard format string is also used to format the hours with one fractional digit.
139139
///
140-
/// @code
140+
/// ```cpp
141141
/// #include <iostream>
142142
/// #include <vector>
143143
/// #include <xtd/xtd>
@@ -162,7 +162,7 @@
162162
/// // Ebenezer 40.3
163163
/// // Francine 80.0
164164
/// // George 16.8
165-
/// @endcode
165+
/// ```
166166
///
167167
/// @subsubsection FormatStringComponentSection Format String Component
168168
///
@@ -192,47 +192,47 @@
192192
///
193193
/// One way to write your code to avoid misinterpreting escaped braces and format items is to format the braces and format item separately. That is, in the first format operation display a literal opening brace, in the next operation display the result of the format item, then in the final operation display a literal closing brace. The following example illustrates this approach.
194194
///
195-
/// @code
195+
/// ```cpp
196196
/// int value = 6324;
197197
/// std::string output = xtd::ustring::format("{0}{1:D}{2}", "{", value, "}");
198198
/// std::cout << output << std::endl;
199199
/// // The example displays the following output:
200200
/// //
201201
/// // {6324}
202-
/// @endcode
202+
/// ```
203203
///
204204
/// @subsection CodeExamplesSection Code Examples
205205
///
206206
/// The following example shows one string created using composite formatting and another created using xtd::to_string method. Both types of formatting produce equivalent results.
207207
///
208-
/// @code
208+
/// ```cpp
209209
/// std::string format_string1 = xtd::ustring::format("0:X4", std::numeric_limits<short>::max());
210210
/// std::string format_string2 = xtd::to_ustring::format(std::numeric_limits<short>::max(), "X4");
211-
/// @endcode
211+
/// ```
212212
///
213213
/// xtd::console::write_line exposes the same functionality as xtd::ustring::format. The only difference between the two methods is that xtd::ustring::format returns its result as a string, while xtd::console::write_line writes the result to the output stream (std::cout) associated with the console object. The following example uses the xtd::console::write_line method to format the value of my_int to a currency value.
214214
///
215-
/// @code
215+
/// ```cpp
216216
/// int my_int = 100;
217217
/// xtd::console::write_line("{0:C}", my_int);
218218
/// // The example displays the following output if en-US is the current culture:
219219
/// //
220220
/// // $100.00
221-
/// @endcode
221+
/// ```
222222
///
223223
/// The following example demonstrates formatting multiple objects, including formatting one object two different ways.
224224
///
225-
/// @code
225+
/// ```cpp
226226
/// std::string my_name = "Fred";
227227
/// xtd::console::write_line(xtd::ustring::format("Name = {0}, hours = {1:hh}, minutes = {1:mm}", myName, date_time::now()));
228228
/// // Depending on the current time, the example displays output like the following:
229229
/// //
230230
/// // Name = Fred, hours = 11, minutes = 30
231-
/// @endcode
231+
/// ```
232232
///
233233
/// The following example demonstrates the use of alignment in formatting. The arguments that are formatted are placed between vertical bar characters (|) to highlight the resulting alignment.
234234
///
235-
/// @code
235+
/// ```cpp
236236
/// std::string my_first_name = "Fred";
237237
/// std::string my_last_name = "Opals";
238238
/// int myInt = 100;
@@ -260,7 +260,7 @@
260260
/// // First Name = |Fred |
261261
/// // Last Name = |Opals |
262262
/// // Price = |$100.00 |
263-
/// @endcode
263+
/// ```
264264
///
265265
/// @section NumericFormatSection Numeric format
266266
///

docs/doxygen/doxygen/main_page.dox

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
///
5151
/// @subsection ExamplesConsoleSubsection Console
5252
/// hello_world_console.cpp:
53-
/// @code
53+
/// ```cpp
5454
/// #include <xtd/xtd>
5555
///
5656
/// using namespace xtd;
@@ -60,32 +60,32 @@
6060
/// console::foreground_color(console_color::white);
6161
/// console::write_line("Hello, World!");
6262
/// }
63-
/// @endcode
63+
/// ```
6464
///
6565
/// CMakeLists.txt:
66-
/// @code
66+
/// ```cpp
6767
/// cmake_minimum_required(VERSION 3.20)
6868
///
6969
/// project(hello_world_console)
7070
/// find_package(xtd REQUIRED)
7171
/// add_sources(hello_world_console.cpp)
7272
/// target_type(CONSOLE_APPLICATION)
73-
/// @endcode
73+
/// ```
7474
///
7575
/// @subsubsection ExamplesConsoleBuildAndRunSubsubsection Build and run
7676
/// Open "Command Prompt" or "Terminal". Navigate to the folder that contains the project and type the following:
77-
/// @code
77+
/// ```cpp
7878
/// xtdc run
79-
/// @endcode
79+
/// ```
8080
///
8181
/// @subsubsection ExamplesConsoleOutputSubsubsection Output
82-
/// @code
82+
/// ```cpp
8383
/// Hello, World!
84-
/// @endcode
84+
/// ```
8585
///
8686
/// @subsection ExamplesFormsSubsection Forms
8787
/// hello_world_forms.cpp:
88-
/// @code
88+
/// ```cpp
8989
/// #include <xtd/xtd>
9090
///
9191
/// using namespace xtd::forms;
@@ -110,23 +110,23 @@
110110
/// auto main() -> int {
111111
/// application::run(main_form());
112112
/// }
113-
/// @endcode
113+
/// ```
114114
///
115115
/// CMakeLists.txt:
116-
/// @code
116+
/// ```cpp
117117
/// cmake_minimum_required(VERSION 3.20)
118118
///
119119
/// project(hello_world_forms)
120120
/// find_package(xtd REQUIRED)
121121
/// add_sources(hello_world_forms.cpp)
122122
/// target_type(GUI_APPLICATION)
123-
/// @endcode
123+
/// ```
124124
///
125125
/// @subsubsection ExamplesFormsBuildAndRunSubsubsection Build and run
126126
/// Open "Command Prompt" or "Terminal". Navigate to the folder that contains the project and type the following:
127-
/// @code
127+
/// ```cpp
128128
/// xtdc run
129-
/// @endcode
129+
/// ```
130130
///
131131
/// @subsubsection ExamplesFormsOutputSubsubsection Output
132132
///
@@ -147,7 +147,7 @@
147147
///
148148
/// @subsection ExamplesUnitTestSubsection Unit tests
149149
/// hello_world_test.cpp:
150-
/// @code
150+
/// ```cpp
151151
/// #include <xtd/xtd>
152152
/// #include <string>
153153
///
@@ -173,23 +173,23 @@
173173
/// auto main() -> int {
174174
/// return console_unit_test(argv, argc).run();
175175
/// }
176-
/// @endcode
176+
/// ```
177177
///
178178
/// CMakeLists.txt:
179-
/// @code
179+
/// ```cpp
180180
/// cmake_minimum_required(VERSION 3.20)
181181
///
182182
/// project(hello_world_test)
183183
/// find_package(xtd REQUIRED)
184184
/// add_sources(hello_world_test.cpp)
185185
/// target_type(TEST_APPLICATION)
186-
/// @endcode
186+
/// ```
187187
///
188188
/// @subsubsection ExamplesUnitTestBuildAndRunSubsubsection Build and run
189189
/// Open "Command Prompt" or "Terminal". Navigate to the folder that contains the project and type the following:
190-
/// @code
190+
/// ```cpp
191191
/// xtdc run
192-
/// @endcode
192+
/// ```
193193
///
194194
/// @subsubsection ExamplesUnitTestOutputSubsubsection Output
195195
///

0 commit comments

Comments
 (0)