gamu1012/cli-text-decoration
最新稳定版本:1.0.0
Composer 安装命令:
composer require gamu1012/cli-text-decoration
包简介
String decoration library for PHP CLI output
README 文档
README
String decoration library for PHP CLI output
Installation
composer require gamu1012/cli-text-decoration
Basic Usage
<?php
require __DIR__ . '/vendor/autoload.php';
echo \Gamu1012\CliTextDecoration::setString("RED")->red()->decorate() . "\n";
echo \Gamu1012\CliTextDecoration::setString("MAGENTA-WHITE_BACKGROUND-UNDERLINE")->magenta()->whiteBackground()->underLine()->decorate() . "\n";
To decorate a character string, first set the target string with setString
The setString method returns a CliTextDecoration instance
Use this to connect chain of decoration information.
Finally, we use the decorate method to get the result
Method List
Front Color
- black()
- red()
- green()
- yellow()
- magenta()
- cyan()
- white()
Background Color
- blackBackground()
- redBackground()
- greenBackground()
- yellowBackground()
- magentaBackground()
- cyanBackground()
- whiteBackground()
Attribute
- bold()
- italic()
- underLine()
- blink()
- hidden()
统计信息
- 总下载量: 844
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2017-06-17
