Why can I place a fixed-size FXCanvas inside an FXScrollWindow?
The FXScrollWindow widget provides a very easy way to make any kind of window scrollable, but for some kinds of content it takes a little extra work. The difficulty has to do with FXScrollWindow’s implementation of the layout() member function, which calls getContentWidth() and getContentHeight() to determine the width and height of the FXScrollWindow’s single child window (its “content”). These calls to FXScrollWindow’s getContentWidth() and getContentHeight() member functions are in turn delegated to the content window’s getDefaultWidth() and getDefaultHeight() member functions. The purpose of the getDefaultWidth() and getDefaultHeight() member functions is to return the minimum width and height for a window, given its current state. For example, an FXLabel’s default width and height are based on its text string, icon, internal padding and frame style. For many widgets, however, there is no sensible value for the minimum width or height, and for those widgets the getDefaultWidth() an