public function detab(Text $text, array $options = array())
    {
        /** @noinspection PhpUnusedParameterInspection */
        $text->replace('/(.*?)\t/', function (Text $whole, Text $string) use ($options) {
            return $string . str_repeat(' ', $options['tabWidth'] - $string->getLength() % $options['tabWidth']);
        });
    }