Inheritance | yii\debug\models\timeline\Svg » yii\base\Object |
---|---|
Implements | yii\base\Configurable |
Available since version | 2.0.8 |
Source Code | https://github.com/yiisoft/yii2-debug/blob/master/models/timeline/Svg.php |
Svg is used to draw a graph using SVG
Property | Type | Description | Defined By |
---|---|---|---|
$gradient | array | Color indicators svg graph. | yii\debug\models\timeline\Svg |
$listenMessages | array | Listen messages panels | yii\debug\models\timeline\Svg |
$stroke | string | Stroke color | yii\debug\models\timeline\Svg |
$template | string | Svg template | yii\debug\models\timeline\Svg |
$x | integer | Max X coordinate | yii\debug\models\timeline\Svg |
$y | integer | Max Y coordinate | yii\debug\models\timeline\Svg |
Property | Type | Description | Defined By |
---|---|---|---|
$panel | yii\debug\panels\TimelinePanel | yii\debug\models\timeline\Svg | |
$points | array | Each point is define by a X and a Y coordinate. | yii\debug\models\timeline\Svg |
Method | Description | Defined By |
---|---|---|
__call() | Calls the named method which is not a class method. | yii\base\Object |
__construct() | Constructor. | yii\debug\models\timeline\Svg |
__get() | Returns the value of an object property. | yii\base\Object |
__isset() | Checks if a property is set, i.e. defined and not null. | yii\base\Object |
__set() | Sets value of an object property. | yii\base\Object |
__toString() | yii\debug\models\timeline\Svg | |
__unset() | Sets an object property to null. | yii\base\Object |
canGetProperty() | Returns a value indicating whether a property can be read. | yii\base\Object |
canSetProperty() | Returns a value indicating whether a property can be set. | yii\base\Object |
className() | Returns the fully qualified name of this class. | yii\base\Object |
hasMethod() | Returns a value indicating whether a method is defined. | yii\base\Object |
hasPoints() | yii\debug\models\timeline\Svg | |
hasProperty() | Returns a value indicating whether a property is defined. | yii\base\Object |
init() | Initializes the object. | yii\base\Object |
Method | Description | Defined By |
---|---|---|
addPoints() | yii\debug\models\timeline\Svg | |
linearGradient() | yii\debug\models\timeline\Svg | |
polygon() | yii\debug\models\timeline\Svg | |
polyline() | yii\debug\models\timeline\Svg |
Color indicators svg graph.
public array $gradient = [10 => '#d6e685', 60 => '#8cc665', 90 => '#44a340', 100 => '#1e6823']
Listen messages panels
public array $listenMessages = ['log', 'profiling']
protected yii\debug\panels\TimelinePanel $panel = null
Each point is define by a X and a Y coordinate.
protected array $points = []
Stroke color
public string $stroke = '#1e6823'
Svg template
public string $template = '<svg width="{x}" height="{y}" viewBox="0 0 {x} {y}" preserveAspectRatio="none"><defs>{linearGradient}</defs><g><polygon points="{polygon}" fill="url(#gradient)"/><polyline points="{polyline}" fill="none" stroke="{stroke}" stroke-width="1"/></g></svg>'
Max X coordinate
public integer $x = 1920
Max Y coordinate
public integer $y = 40
Constructor.
The default implementation does two things:
$config
.If this method is overridden in a child class, it is recommended that
$config
here.public void __construct ( yii\debug\panels\TimelinePanel $panel, $config = [] ) | ||
---|---|---|
$panel | ||
$config | array |
Name-value pairs that will be used to initialize the object properties |
public string __toString ( ) |
---|
protected integer addPoints ( $messages ) | ||
---|---|---|
$messages | array |
Log messages. See \yii\debug\models\timeline\Logger::messages for the structure |
return | integer |
Added points |
public boolean hasPoints ( ) | ||
---|---|---|
return | boolean |
Has points |
protected string linearGradient ( ) |
---|
protected string polygon ( ) | ||
---|---|---|
return | string |
Points attribute for polygon path |
protected string polyline ( ) | ||
---|---|---|
return | string |
Points attribute for polyline path |
© 2008–2017 by Yii Software LLC
Licensed under the three clause BSD license.
http://www.yiiframework.com/doc-2.0/yii-debug-models-timeline-svg.html