| Conditions | 3 |
| Paths | 3 |
| Total Lines | 12 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 17 | private function __construct(iterable $terminalProbes) |
||
| 18 | { |
||
| 19 | /** @var ITerminalProbe $terminalProbe */ |
||
| 20 | foreach ($terminalProbes as $terminalProbe) { |
||
| 21 | if ($terminalProbe::isSupported()) { |
||
| 22 | $this->colorMode = $terminalProbe::getColorMode(); |
||
| 23 | $this->width = $terminalProbe::getWidth(); |
||
| 24 | return; |
||
| 25 | } |
||
| 26 | } |
||
| 27 | $this->colorMode = ITerminal::TERMINAL_DEFAULT_COLOR_SUPPORT; |
||
| 28 | $this->width = ITerminal::TERMINAL_DEFAULT_WIDTH; |
||
| 29 | } |
||
| 60 | } |