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

Milestone diamond can occlude Group label #79

Closed
kajuberdut opened this issue Nov 11, 2023 · 7 comments
Closed

Milestone diamond can occlude Group label #79

kajuberdut opened this issue Nov 11, 2023 · 7 comments

Comments

@kajuberdut
Copy link
Collaborator

kajuberdut commented Nov 11, 2023

If a milestone is placed in the same position on the X-axis of a group as the text of a group, the milestones diamond occludes the text of the group making it partially or wholly unreadable.

To some extent this can be mitigated by changing the alignment of the group text BUT it would be better if the text remained readable even when these overlap.

Possible solutions:

  1. The Milestone diamonds should probably be drawn behind the group text. This might be complicated as I'm not sure if Z level can be controlled with pillow or if this has to be achieved with the draw order.
  2. If it is possible to check if the diamond overlaps with text it might be possible to mitigate this by making the diamond smaller, only an outline, making the diamond transparent in a horizontal strip, or in some other way making it possible to read the text that the diamond overlaps.
  3. It might be possible to change the default y-axis offset of the diamond or the group text in such a way that this scenario is much less likely to happen or to occlude the text.
@kajuberdut kajuberdut changed the title Milestone Diamonds occlude group labels Milestone Diamonds occlude Group labels Nov 11, 2023
@kajuberdut kajuberdut changed the title Milestone Diamonds occlude Group labels Milestone diamond can occlude Group label Nov 11, 2023
@kajuberdut
Copy link
Collaborator Author

Example of text being occluded by diamond:
image

@kajuberdut
Copy link
Collaborator Author

I will make an attempt at a fix for this but wanted to log the issue in case there is already a plan for how to minimize this case.

@csgoh
Copy link
Owner

csgoh commented Nov 12, 2023

Thanks @kajuberdut for the suggestions to the issue. Would aligning the task text to the left or right or at certain px/percentage (as you have suggested in the pull request) resolve this in the short term?

I will need some time to think of a better approach for a permanent or long-term solution.

@kajuberdut
Copy link
Collaborator Author

kajuberdut commented Nov 12, 2023

Yes, currently changing the timeline size + font size and/or changing the text alignment can work around this.

csgoh added a commit that referenced this issue Apr 14, 2024
Optimized the drawing logic within the `Task` class by adjusting how box dimensions and positions are calculated, ensuring the exclusion of unwarranted gap spaces which addresses issue #79. Revised conditions for initiating drawing operations, now requiring all box dimensions and positions to be explicitly non-zero, which better aligns with expected drawing behavior. Additionally, updated the order in which tasks and milestones are rendered, ensuring milestones are drawn before task text to align with the changes planned for release v1.4.1. This adjustment not only enhances visual hierarchy but also aligns with user expectations for task-milestone representation.
@csgoh
Copy link
Owner

csgoh commented Apr 14, 2024

Hi @kajuberdut
This is now resolved in v1.5.0. The milestone marker is drawn before the text of the task.
image

Sorry for taking this long. I have been too busy with my work.

@kajuberdut
Copy link
Collaborator Author

This is wonderful and thank you!

@felix-seifert
Copy link
Collaborator

With PR #103, this issue can be closed.

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

No branches or pull requests

3 participants