Skip to content
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

fix selected single line appearance #649

Merged
merged 1 commit into from Jul 24, 2023
Merged

Conversation

secretfork
Copy link

The previous logic added a pen stroke at the top 3 pixels wide, and 5 pixels at the bottom. Probably because the lower pen stroke is misaligned (too far down) and needs a larger stroke width to compensate for this misalignment, which causes part of that stroke (the lower part) to be cut of by the next line (but not if the selection is on the last line).

This causes different effects both at lines selected in the middle of the log as well as the end of the log (last line) in different ways.

It also re-added pen several times after changing the width of the pen, which is simply unnecessary (and may have added to this effect of increasing color intensity in the original version)

The fix simple removes unnecessary lines of code as well as adjusting the position of the lower stroke and removing the previous attempt to compensate for it with stroke width.

Last line (before fix):
1-b

Line in the middle of document (before fix):
2-b

Last line (after fix):
3-b

Line in the middle of document (after fix):
4-b

The previous logic added a pen stroke at the top 3 pixels wide, and 5 pixels at the bottom. Probably because the lower pen stroke is misaligned (too far down) and needs a larger stroke width to compensate for this misalignment, which causes part of that stroke (the lower part) to be cut of by the next line (but not if the selection is on the last line).

This causes different effects both at lines selected in the middle of the log as well as the end of the log (last line) in different ways.

It also re-added pen several times after changing the width of the pen, which is simply unnecessary (and may have added to this effect of increasing color intensity in the original version)

The fix simple removes unnecessary lines of code as well as adjusting the position of the lower stroke and removing the previous attempt to compensate for it with stroke width.
@variar
Copy link
Owner

variar commented Jul 24, 2023

Thanks, that does look a lot nicer!

@variar variar merged commit 68f1506 into variar:master Jul 24, 2023
@variar variar added this to the 2023.09 milestone Jul 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants