Fix: ensure stroke is applied to all lines in multiline text with emojis#45
Open
Scr44gr wants to merge 1 commit intojay3332:2.0from
Open
Fix: ensure stroke is applied to all lines in multiline text with emojis#45Scr44gr wants to merge 1 commit intojay3332:2.0from
Scr44gr wants to merge 1 commit intojay3332:2.0from
Conversation
Ensure not setting stroke_width to 0 so that in the next iteration the text has its respective stroke_width.
Contributor
Reviewer's Guide by SourceryThis pull request fixes an issue with stroke application in multiline text containing emojis. The main change involves removing the reset of stroke_width to 0 and the passing of stroke_width to the getmask2 function. Class diagram for changes in stroke applicationclassDiagram
class Core {
+getink(fill)
}
Core : -stroke_width
Core : -getmask2(..., stroke_width, ...)
note for Core "Removed stroke_width reset and its usage in getmask2"
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Contributor
There was a problem hiding this comment.
Hey @Scr44gr - I've reviewed your changes - here's some feedback:
Overall Comments:
- Have you tested this change with various types of text input, including those without emojis? Please ensure comprehensive testing to avoid unintended side effects.
- Consider improving the commit message to clearly explain the problem this change is solving and why it's necessary. This will help future maintainers understand the reasoning behind the modification.
Here's what I looked at during the review
- 🟢 General issues: all looks good
- 🟢 Security: all looks good
- 🟢 Testing: all looks good
- 🟢 Complexity: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In the original implementation, there was logic that set
stroke_widthto 0 during the text rendering process in the getmask2 function call. This caused subsequent lines of text to lose their stroke, as the stroke width was effectively disabled after the first line.The fix involved removing the part where stroke_width was set to 0 after the stroke was applied. By doing this, the stroke_width parameter is preserved across all lines of the multiline text, ensuring that each line has its proper stroke.
Additionally, the
stroke_widthargument was removed from thegetmask2call. This ensures that the stroke is applied consistently throughout all iterations when rendering the text. Instead of resetting the stroke for each line, the value of stroke_width remains intact, allowing the stroke to be applied uniformly to each line of text, including those that come after the first line.This change ensures that the stroke is not lost when processing multiple lines of text, which was the core issue when rendering multiline text with emojis.
Summary by Sourcery
Bug Fixes: