Skip to content

Commit 908bf98

Browse files
committed
fix formatting
1 parent b15049b commit 908bf98

File tree

3 files changed

+8
-10
lines changed

3 files changed

+8
-10
lines changed

examples/progress.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@
99
$image = Vips\Image::black(1, 1000000);
1010
$image->setProgress(true);
1111

12-
$image->signalConnect("preeval", function($image, $progress) {
12+
$image->signalConnect("preeval", function ($image, $progress) {
1313
echo "preeval:\n";
1414
});
15-
$image->signalConnect("eval", function($image, $progress) {
15+
$image->signalConnect("eval", function ($image, $progress) {
1616
echo "eval: $progress->percent % complete\r";
17-
});
17+
});
1818

19-
$image->signalConnect("posteval", function($image, $progress) {
19+
$image->signalConnect("posteval", function ($image, $progress) {
2020
echo "\nposteval:\n";
2121
});
2222

examples/streaming-custom.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,17 @@
2727
});
2828

2929
// open for write and read ... formats like tiff need to be able to seek back
30-
// in the output and update bytes later
30+
// in the output and update bytes later
3131
$out_file = fopen($argv[2], 'w+');
3232
$target = new Vips\TargetCustom();
3333
$target->onWrite(function ($buffer) use (&$out_file) {
3434
$result = fwrite($out_file, $buffer);
3535
if ($result === false) {
3636
// IO error
3737
return -1;
38-
}
39-
else
38+
} else {
4039
return $result;
40+
}
4141
});
4242
// read and seek are optional
4343
$target->onSeek(function ($offset, $whence) use (&$out_file) {
@@ -53,4 +53,3 @@
5353

5454
$image = Vips\Image::newFromSource($source);
5555
$image->writeToTarget($target, $argv[3]);
56-

src/Image.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1299,7 +1299,7 @@ public function remove(string $name): void
12991299
/**
13001300
* Enable progress reporting on an image.
13011301
*
1302-
* The preeval, eval and posteval signals will be emitted on the
1302+
* The preeval, eval and posteval signals will be emitted on the
13031303
* most-downstream image for which setProgress() was enabled. @see
13041304
* GObject::signalConnect().
13051305
*
@@ -1310,7 +1310,6 @@ public function remove(string $name): void
13101310
public function setProgress(bool $progress): void
13111311
{
13121312
FFI::vips()->vips_image_set_progress($this->pointer, $progress);
1313-
13141313
}
13151314

13161315
/**

0 commit comments

Comments
 (0)