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 coarse gridlines being half as wide every 8 bars. #7610

Merged
merged 1 commit into from
Dec 1, 2024

Conversation

regulus79
Copy link
Contributor

@regulus79 regulus79 commented Nov 30, 2024

Partially fixes #7305

This fixes the issue that every 8th bar line was half as wide. This was due to an off-by-one error where the very last bar line is not drawn. This works fine when the coarse grid lines are 1px wide, but in the default theme it is 2px, so the thinness every 8 bars is quite noticeable. This is fixed by changing < to <= in the loop condition.

Before:
Screenshot From 2024-11-30 12-50-10

After:
Screenshot From 2024-11-30 13-17-59

Note

This does not address the original issue's point that the grid lines are too thick. This simply makes them all uniform. However, the thickness can be changed in the theme style.css.

Also, I do have a fear that since floats are used in the loop, that simply changing < to <= may not fully solve the issue. In my tested, it appears to have solved it, but I don't know.

@Rossmaxx
Copy link
Contributor

Tbh, i can't see the difference between the two images.

@regulus79
Copy link
Contributor Author

Old:
old_coarse_lines
New:
new_coarse_lines

@Rossmaxx
Copy link
Contributor

Ohh i get now. Btw I don't think this fixes the actual issue, which is due to thicker lines. But thinning will confuse the user with the other lines which are also 1px.

@regulus79
Copy link
Contributor Author

It could, but they are also a different color from the fine grid lines, so it would still work well. Here is what it would look like if both coarse and fine grid lines were 1 px:
image

@Rossmaxx
Copy link
Contributor

I remember telling the person who made the song editor UI change to not use 1px because it felt like 1px wouldn't create much of a difference. It still doesn't seem like the coarse and fine lines are much different.

@rdrpenguin04
Copy link
Contributor

This seems like an easy merge; it's a one-character fix that objectively fixes a visual bug

Copy link
Contributor

@Rossmaxx Rossmaxx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Rossmaxx Rossmaxx merged commit f579750 into LMMS:master Dec 1, 2024
11 checks passed
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.

The accent line is very thick.
3 participants