c# - .net scrollbar autoscroll problem -


I'm writing an app in .NET which uses AutoCrol for a layout panel in a dialog. It seems that whenever I change the size of the window so that the vertical scrollbar is visible, the horizontal scrollbar appears automatically. Looking at it closely, the second scrollbar now allows me to scroll the window with 16 pixels (the width of the second scrollbar). So windows feel that I need the client area, which is the least widespread because it was before the vertical scrollbar.

If I widen the window size by 16 pixels (so that my window area was as wide as was in front of the scrollbar), the scrollbar goes away. Now if I resize it, then it will stay away. is.

So it will appear to me that there is a bug in the system where the minimum width can be sticky in some way, but moving upwards and downjijing window (with the mouse, and touch scrollbar related APIs Without) condition clears

Is anyone aware of an alternate solution, or am I doing something to travel to Windows?

Yes, I think that you have already correctly diagnosed this problem, say it The vertical scrollbar needs more space, this is a bad side effect to reducing the available client area. Too small to fit in control, is still visible to the horizontal scrollbar. It is actually bi-constant, horizontal strip can flicker and close in some cases.

To avoid this effect, the layout engine must pass several through the layout, dealing with the changing client area. It only gives one pass that looks intelligent, this can never be a potential end to a loop, I do not know a decent fit for it. Your user can resize windows adequately to get rid of at least one scrollbar.


Comments