New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
text tag #2246
base: main
Are you sure you want to change the base?
text tag #2246
Conversation
c250f1d
to
52eb54f
Compare
src/loaders/svg/tvgSvgLoader.cpp
Outdated
{ | ||
auto text = &loader->svgParse->node->node.text; | ||
if (text->text) free(text->text); | ||
text->text = strndup(content, length); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I recommend to use strDuplicate().
https://github.com/thorvg/thorvg/actions/runs/8961686765/job/24609564343?pr=2246#step:5:151
inc/thorvg.h
Outdated
@@ -1485,7 +1486,7 @@ class TVG_API Text final : public Paint | |||
* | |||
* @note Experimental API | |||
*/ | |||
Result fill(uint8_t r, uint8_t g, uint8_t b) noexcept; | |||
Result fill(uint8_t r, uint8_t g, uint8_t b, uint8_t a = 255) noexcept; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it has opacity() already ?
I'd like to suggest to dismiss these 2 patches in this PR.
Svg loader could apply the font size directly, as it is supposed to do. |
@mgrudzinska ping? I think it's easier to apply only with svg_loader updates. if there is a font size issue, we can deal with it separately. |
52eb54f
to
1a6b60d
Compare
@hermet I still have to figure out how to access the system fonts or how to deal without them |
@mgrudzinska Please handle the embedded font as expected for the issue. System fonts must be addressed separately based on the thorvg specifications. |
todo:
issue: #1897