@@ -33,10 +33,10 @@ |
||
| 33 | 33 | protected static string $percentNumberFormat; |
| 34 | 34 | protected static bool $createInitialized; |
| 35 | 35 | protected static array $colorSupportLevels; |
| 36 | - protected static ?array $defaultStylePattern = null; |
|
| 37 | - protected static ?array $defaultCharPattern = null; |
|
| 38 | - protected static ?array $mainStylePattern = null; |
|
| 39 | - protected static ?array $mainCharPattern = null; |
|
| 36 | + protected static ? array $defaultStylePattern = null; |
|
| 37 | + protected static ? array $defaultCharPattern = null; |
|
| 38 | + protected static ? array $mainStylePattern = null; |
|
| 39 | + protected static ? array $mainCharPattern = null; |
|
| 40 | 40 | protected static ?IFrame $mainLeadingSpacer = null; |
| 41 | 41 | protected static ?IFrame $mainTrailingSpacer = null; |
| 42 | 42 | protected static ?IFrame $defaultLeadingSpacer = null; |
@@ -22,7 +22,7 @@ discard block |
||
| 22 | 22 | (bool)( |
| 23 | 23 | ($error['type'] ?? 0) |
| 24 | 24 | & |
| 25 | - (E_ERROR | E_CORE_ERROR | E_COMPILE_ERROR | E_USER_ERROR | E_RECOVERABLE_ERROR) |
|
| 25 | + (E_ERROR|E_CORE_ERROR|E_COMPILE_ERROR|E_USER_ERROR|E_RECOVERABLE_ERROR) |
|
| 26 | 26 | ); |
| 27 | 27 | } |
| 28 | 28 | |
@@ -53,7 +53,7 @@ discard block |
||
| 53 | 53 | protected function doCreateHandlers(ISpinner $spinner): iterable |
| 54 | 54 | { |
| 55 | 55 | yield from [ |
| 56 | - SIGINT => function () use ($spinner): void { |
|
| 56 | + SIGINT => function() use ($spinner): void { |
|
| 57 | 57 | $spinner->interrupt(); |
| 58 | 58 | $this->stop(); |
| 59 | 59 | }, |
@@ -45,12 +45,12 @@ |
||
| 45 | 45 | // Automatically run loop at end of program, unless already started or stopped explicitly. |
| 46 | 46 | // @codeCoverageIgnoreStart |
| 47 | 47 | $hasRun = false; |
| 48 | - EventLoop::defer(static function () use (&$hasRun): void { |
|
| 48 | + EventLoop::defer(static function() use (&$hasRun): void { |
|
| 49 | 49 | $hasRun = true; |
| 50 | 50 | }); |
| 51 | 51 | |
| 52 | - $stopped =& self::$stopped; |
|
| 53 | - register_shutdown_function(static function () use (&$hasRun, &$stopped) { |
|
| 52 | + $stopped = & self::$stopped; |
|
| 53 | + register_shutdown_function(static function() use (&$hasRun, &$stopped) { |
|
| 54 | 54 | // Don't run if we're coming from a fatal error (uncaught exception). |
| 55 | 55 | if (self::error()) { |
| 56 | 56 | return; |
@@ -90,7 +90,7 @@ discard block |
||
| 90 | 90 | public function add(IWidgetComposite|IWidgetContext $element): IWidgetContext |
| 91 | 91 | { |
| 92 | 92 | $this->wrap( |
| 93 | - function () use ($element, &$result): void { |
|
| 93 | + function() use ($element, &$result): void { |
|
| 94 | 94 | $result = $this->widget->add($element); |
| 95 | 95 | } |
| 96 | 96 | ); |
@@ -122,7 +122,7 @@ discard block |
||
| 122 | 122 | public function remove(IWidgetComposite|IWidgetContext $element): void |
| 123 | 123 | { |
| 124 | 124 | $this->wrap( |
| 125 | - function () use ($element) { |
|
| 125 | + function() use ($element) { |
|
| 126 | 126 | $this->widget->remove($element); |
| 127 | 127 | } |
| 128 | 128 | ); |
@@ -6,8 +6,8 @@ |
||
| 6 | 6 | |
| 7 | 7 | interface IInterval |
| 8 | 8 | { |
| 9 | - final public const MIN_INTERVAL_MILLISECONDS = 10; // 10 milliseconds |
|
| 10 | - final public const MAX_INTERVAL_MILLISECONDS = 900000; // 15 minutes |
|
| 9 | + final public const MIN_INTERVAL_MILLISECONDS = 10; // 10 milliseconds |
|
| 10 | + final public const MAX_INTERVAL_MILLISECONDS = 900000; // 15 minutes |
|
| 11 | 11 | |
| 12 | 12 | public function toMicroseconds(): float; |
| 13 | 13 | |
@@ -27,16 +27,16 @@ |
||
| 27 | 27 | private static function createDeterminer(): Closure |
| 28 | 28 | { |
| 29 | 29 | if (function_exists('\AlecRabbit\WCWidth\wcswidth')) { |
| 30 | - return static function (string $string): int { |
|
| 30 | + return static function(string $string): int { |
|
| 31 | 31 | return wcswidth($string); |
| 32 | 32 | }; |
| 33 | 33 | } |
| 34 | 34 | if (function_exists('\mb_strlen')) { |
| 35 | - return static function (string $string): int { |
|
| 35 | + return static function(string $string): int { |
|
| 36 | 36 | return mb_strlen($string); |
| 37 | 37 | }; |
| 38 | 38 | } |
| 39 | - return static function (string $string): int { |
|
| 39 | + return static function(string $string): int { |
|
| 40 | 40 | return strlen($string); |
| 41 | 41 | }; |
| 42 | 42 | } |