#14844 closed defect (fixed)

Fix ribbon bar initial scroll buttons issue

Reported by: wxBen Owned by:
Priority: normal Milestone:
Component: GUI-all Version: stable-latest
Keywords: ribbon bar scroll buttons Cc:
Blocked By: Blocking:
Patch: yes

Description

If you create a new ribbon bar you initially call Layout after adding everything to it. If a page is initially too wide to fit, it will create a right scroll button for it at this time, but the height of the bar and hence the scroll button will still be the initial default zero. If the user then flips to a page with such a scroll button, it will show those scroll bars, but since their size is zero, you get a black square or dirty left over to the far right where the scroll button normally sits. The page knows how big it should be and reserves that space but the scroll bar does not cover and paint it. These scroll buttons remain stuck with size zero unless you widen your application to make the scroll bars disappear (which deletes them) and then shrink it back down again (which recreates them with the right size).

The bar calls Layout continually which creates or destroys the scroll bars as necessary. This change tweaks that code slightly so that if scroll buttons are present on a page, it goes through the ShowScrollButtons method which now merely updates the scroll button sizes, rather than just create them if they are missing.

Attachments (1)

FixInitialScrolls.diff download (4.3 KB) - added by wxBen 20 months ago.
FixInitialScrolls.diff

Download all attachments as: .zip

Change History (2)

Changed 20 months ago by wxBen

FixInitialScrolls.diff

comment:1 Changed 20 months ago by VZ

  • Resolution set to fixed
  • Status changed from new to closed

(In [72998]) Fix ribbon bar scroll buttons visibility bug.

Fix scroll buttons update code in wxRibbonPage.

Closes #14844.

Note: See TracTickets for help on using tickets.