swen100 /
cairo
| 1 | <?php |
||
| 2 | |||
| 3 | use Cairo\Context; |
||
|
0 ignored issues
–
show
|
|||
| 4 | use Cairo\Surface\Image; |
||
|
0 ignored issues
–
show
The type
Cairo\Surface\Image was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths Loading history...
|
|||
| 5 | use Cairo\Surface\ImageFormat; |
||
|
0 ignored issues
–
show
The type
Cairo\Surface\ImageFormat was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths Loading history...
|
|||
| 6 | |||
| 7 | $surface = new Image(ImageFormat::ARGB32, 8, 8); |
||
| 8 | $context = new Context($surface); |
||
| 9 | $context->save(); |
||
| 10 | $context->setSourceRgb(0, 0, 1); |
||
| 11 | $context->paint(); |
||
| 12 | |||
| 13 | $context->rectangle(2, 2, 4, 4); |
||
| 14 | $context->clip(); |
||
| 15 | $context->setSourceRgb(1, 0, 0); |
||
| 16 | $context->paint(); |
||
| 17 | $context->restore(); |
||
| 18 | $context->pushGroup(); |
||
| 19 | |||
| 20 | $s = $context->getGroupSurface(); |
||
| 21 | |||
| 22 | $context->setSourceRgb(0, 1, 0); |
||
| 23 | $context->fill(); |
||
| 24 | $off = $s->getDeviceOffset(); |
||
| 25 | $te = $off['x']; |
||
| 26 | |||
| 27 | echo $te; |
||
| 28 | |||
| 29 | $context->rectangle(2, 2, 4, 4); |
||
| 30 | $context->fill(); |
||
| 31 | $context->popGroupToSource(); |
||
| 32 | $context->paint(); |
||
| 33 | |||
| 34 | $surface->writeToPng(dirname(__FILE__).'/get-group-target-php.png'); |
||
| 35 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths