Upgrade to libvips v8.14.0-rc1

- Replace GIF 'optimise' option with 'reuse'
- Add 'progressive' option to GIF
- Add 'wrap' option to text creation
- Add 'formatMagick' property to *magick input metadata
This commit is contained in:
Lovell Fuller
2022-12-29 15:53:43 +00:00
parent 844deaf480
commit eac6e8b261
16 changed files with 151 additions and 38 deletions

View File

@@ -327,6 +327,13 @@ function _createInputDescriptor (input, inputOptions, containerOptions) {
throw is.invalidParameterError('text.spacing', 'number', inputOptions.text.spacing);
}
}
if (is.defined(inputOptions.text.wrap)) {
if (is.string(inputOptions.text.wrap) && is.inArray(inputOptions.text.wrap, ['word', 'char', 'wordChar', 'none'])) {
inputDescriptor.textWrap = inputOptions.text.wrap;
} else {
throw is.invalidParameterError('text.wrap', 'one of: word, char, wordChar, none', inputOptions.text.wrap);
}
}
delete inputDescriptor.buffer;
} else {
throw new Error('Expected a valid string to create an image with text.');