$src_image = call_user_func( $loader, $params['srcPath'] );
- $rotation = function_exists( 'imagerotate' ) && !isset( $params['disableRotation'] ) ? $this->getRotation( $image ) : 0;
+ $rotation = function_exists( 'imagerotate' ) && !isset( $params['disableRotation'] ) ?
+ $this->getRotation( $image ) :
+ 0;
list( $width, $height ) = $this->extractPreRotationDimensions( $params, $rotation );
$dst_image = imagecreatetruecolor( $width, $height );
}
/**
- * Swaps an embedded ICC profile for another, if found. Depends on exiftool, no-op if not installed.
+ * Swaps an embedded ICC profile for another, if found.
+ * Depends on exiftool, no-op if not installed.
* @param string $filepath File to be manipulated (will be overwritten)
- * @param string $oldProfileString Exact name of color profile to look for (the one that will be replaced)
+ * @param string $oldProfileString Exact name of color profile to look for
+ * (the one that will be replaced)
* @param string $profileFilepath ICC profile file to apply to the file
* @since 1.26
* @return bool
* Gets configuration for the file warning message. Return value of
* the following structure:
* array(
- * 'module' => 'example.filewarning.messages', // Required, module with messages loaded for the client
- * 'messages' => array( // Required, array of names of messages
- * 'main' => 'example-filewarning-main', // Required, main warning message
- * 'header' => 'example-filewarning-header', // Optional, header for warning dialog
- * 'footer' => 'example-filewarning-footer', // Optional, footer for warning dialog
- * 'info' => 'example-filewarning-info', // Optional, text for more-information link (see below)
+ * // Required, module with messages loaded for the client
+ * 'module' => 'example.filewarning.messages',
+ * // Required, array of names of messages
+ * 'messages' => array(
+ * // Required, main warning message
+ * 'main' => 'example-filewarning-main',
+ * // Optional, header for warning dialog
+ * 'header' => 'example-filewarning-header',
+ * // Optional, footer for warning dialog
+ * 'footer' => 'example-filewarning-footer',
+ * // Optional, text for more-information link (see below)
+ * 'info' => 'example-filewarning-info',
* ),
- * 'link' => 'http://example.com', // Optional, link for more information
+ * // Optional, link for more information
+ * 'link' => 'http://example.com',
* )
*
* Returns null if no warning is necessary.
}
$len = unpack( 'Nlength/Noffset', substr( $content, 32, 8 ) );
- if ( !$len || $len['length'] < 4 || $len['offset'] < 0 || $len['offset'] > $len['length'] ) {
- $this->logger->info( __METHOD__ . 'Error reading extended XMP block, invalid length or offset.' );
+ if ( !$len ||
+ $len['length'] < 4 ||
+ $len['offset'] < 0 ||
+ $len['offset'] > $len['length']
+ ) {
+ $this->logger->info(
+ __METHOD__ . 'Error reading extended XMP block, invalid length or offset.'
+ );
return false;
}
* @throws RuntimeException
*/
private function endElementModeLi( $elm ) {
-
list( $ns, $tag ) = explode( ' ', $this->curItem[0], 2 );
$info = $this->items[$ns][$tag];
$finalName = isset( $info['map_name'] )
$this->results['xmp-' . $info['map_group']][$finalName]['_type'] = 'lang';
}
} else {
- throw new RuntimeException( __METHOD__ . " expected </rdf:seq> or </rdf:bag> but instead got $elm." );
+ throw new RuntimeException(
+ __METHOD__ . " expected </rdf:seq> or </rdf:bag> but instead got $elm."
+ );
}
}