mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-08 13:43:43 +00:00
docs: minor linguistic changes (#759)
This commit is contained in:
parent
bf2e9631bf
commit
d7cb87971b
2 changed files with 19 additions and 15 deletions
26
README.md
26
README.md
|
@ -170,7 +170,7 @@ ThorVG supports SVG (Scalable Vector Graphics) rendering through its SVG interpr
|
|||
to keep it lightweight, so it's useful for the embedded systems. Among the SVG Tiny specs, unsupported features in the ThorVG are the following:
|
||||
|
||||
- Animation
|
||||
- Fonts & Text
|
||||
- Fonts & Text
|
||||
- Interactivity
|
||||
- Multimedia
|
||||
- Scripting
|
||||
|
@ -264,20 +264,29 @@ ThorVG provides the resource verification tool for the ThorVG Engine. [ThorVG vi
|
|||
### SVG to PNG
|
||||
ThorVG provides an executable `svg2png` converter that generates a PNG file from an SVG file.
|
||||
|
||||
To use `svg2png`, you must turn on this feature in the build option:
|
||||
To use the `svg2png`, you must turn on this feature in the build option:
|
||||
```
|
||||
meson -Dtools=svg2png . build
|
||||
```
|
||||
Alternatively, you can add the `svg2png` value to the `tools` option in `meson_option.txt`. The build output will be located in `{builddir}/src/bin/svg2png/`.
|
||||
<br />
|
||||
|
||||
Examples of the usage of the `svg2png`:
|
||||
To use the `svg2png` converter you have to pass the `SVG files` parameter. It can be a file name with the `.svg` extension or a directory name. Multiple files or directories separated by a space are also accepted. If a directory is passed, the `.svg` file extension is searched inside it and in all of its subdirectories.
|
||||
|
||||
Optionally, the image resolution can be provided in the `WxH` format (two numbers separated by an `x` sign) following the `-r` flag.
|
||||
<br />
|
||||
The background color can be set with the `-b` flag. The `bgColor` parameter should be passed as a three-bytes hexadecimal value in the `ffffff` format. The default background is transparent.
|
||||
<br />
|
||||
Both flags, if provided, are applied to all of the `.svg` files.
|
||||
|
||||
The usage examples of the `svg2png`:
|
||||
```
|
||||
Usage:
|
||||
svg2png [svgFileName] [-r resolution] [-b bgColor]
|
||||
svg2png [SVG files] [-r resolution] [-b bgColor]
|
||||
|
||||
Flags:
|
||||
-r set output image resolution.
|
||||
-b set output image background color.
|
||||
-r set the output image resolution.
|
||||
-b set the output image background color.
|
||||
|
||||
Examples:
|
||||
$ svg2png input.svg
|
||||
|
@ -286,11 +295,6 @@ Examples:
|
|||
$ svg2png input1.svg input2.svg -r 200x200 -b ff00ff
|
||||
$ svg2png . -r 200x200
|
||||
```
|
||||
Multiple files or directories are accepted for `svgFileName`. If a directory is applied, subdirectories are also searched. Looking for `.svg` file extension.
|
||||
<br />
|
||||
Background color `bgColor` is three-bytes hexadecimal color value. Hash character can be skipped (both `#ffffff` and `ffffff` are accepted). Default background is transparent.
|
||||
<br />
|
||||
<br />
|
||||
[Back to contents](#contents)
|
||||
<br />
|
||||
<br />
|
||||
|
|
|
@ -756,7 +756,7 @@ public:
|
|||
*
|
||||
* The current point value is set to the last point from the sub-path.
|
||||
* For each command from the @p cmds array, an appropriate number of points in @p pts array should be specified.
|
||||
* If the number of points array is different from the number required by commands array, the shape with this path added is not displayed on the screen.
|
||||
* If the number of points in the @p pts array is different than the number required by the @p cmds array, the shape with this sub-path will not be displayed on the screen.
|
||||
*
|
||||
* @param[in] cmds The array of the commands in the sub-path.
|
||||
* @param[in] cmdCnt The number of the sub-path's commands.
|
||||
|
@ -1375,11 +1375,11 @@ public:
|
|||
~Saver();
|
||||
|
||||
/**
|
||||
* @brief Export the given @p paint data to the given @p path
|
||||
* @brief Exports the given @p paint data to the given @p path
|
||||
*
|
||||
* If the saver module supports any compression mechanism, it will optmize the data size.
|
||||
* If the saver module supports any compression mechanism, it will optimize the data size.
|
||||
* This might affect the encoding/decoding time slow down in cases, You can turn off the compression
|
||||
* if your system whole focuse on the speed.
|
||||
* if your system whole focus on the speed.
|
||||
*
|
||||
* @param[in] paint The paint to be saved with all its associated properties.
|
||||
* @param[in] path A path to the file, in which the paint data is to be saved.
|
||||
|
|
Loading…
Add table
Reference in a new issue