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

HRangeScrollBar and VRangeScrollBar +/- handle backgrounds not shown upon initialization #5

Open
sjaehn opened this issue May 27, 2023 · 1 comment

Comments

@sjaehn
Copy link
Owner

sjaehn commented May 27, 2023

The background of the two handles "+" and "-" are not shown in HRangeScrollBar and VRangeScrollBar when initialized and added to the main window. They only become visible (and stay visible) once the scrollbar is changed (e.g., dragged). Note, the labels "+" and "-" and all the rest is/are correctly shown all the time.

@sjaehn
Copy link
Owner Author

sjaehn commented May 27, 2023

The problem is caused by HRangeScrollBar and VRangeScrollBar drawing to child widgets (Frames button1 and button2) surfaces upon call of update() (wich is called if the parent scrollbar is clicked, dragged, resized or changed in any way). However, the just drawn child widget surface is overwritten when the child widgets update() method is called. This happens upon composite widget (like HRangeScrollBar and VRangeScrollBar) initialization when the child widgets are added to the parent composite widget.

Solutions:

  1. Always call update() to all composite widgets after the start (ugly solution).
  2. Use a functional drawing solution (to be implemented, see roadmap).

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

1 participant