ALib C++ Framework
by
Library Version: 2511 R0
Documentation generated by doxygen
Loading...
Searching...
No Matches
console.inl
Go to the documentation of this file.
1//==================================================================================================
2/// \file
3/// This header-file is part of module \alib_system of the \aliblong.
4///
5/// \emoji :copyright: 2013-2025 A-Worx GmbH, Germany.
6/// Published under #"mainpage_license".
7//==================================================================================================
8ALIB_EXPORT namespace alib { namespace system {
9
10//==================================================================================================
11/// This class provides system-dependent features in respect the console attached to a process.
12//==================================================================================================
14{
15 protected:
16 /// Console text width.
17 ALIB_DLL static
19
20 public:
21 /// Tries to detect the current width of the console. Returns \c 0 in case of failure.
22 /// @param forceRedetect If \c true, the console size is tried to be detected, even if it
23 /// had been done before (and even if it failed before).<br>
24 /// Defaults to \c false.
25 /// @param defaultWidth The default value, in case the detection fails or the detected
26 /// value is \c 0.<br>
27 /// Defaults to \c 80.
28 ///
29 /// @return The console width.
30 ALIB_DLL static
31 int GetWidth( bool forceRedetect = false, int defaultWidth= 80 );
32};
33
34} // namespace alib[::system]
35
36/// Type alias in namespace \b alib.
38
39} // namespace [alib]
#define ALIB_DLL
Definition alib.inl:573
#define ALIB_EXPORT
Definition alib.inl:562
This class provides system-dependent features in respect the console attached to a process.
Definition console.inl:14
static int GetWidth(bool forceRedetect=false, int defaultWidth=80)
Definition console.cpp:43
static int lastReceivedWidth
Console text width.
Definition console.inl:18
system::Console Console
Type alias in namespace alib.
Definition console.inl:37