When above is used and a control is not within the viewable area and I call spanel.ScrollChildIntoView(child) and the scrolled panel has a horizontal scrollbar then the child is just barely viewable after the call.
I like to suggest the following change to fix this:
Original code at about line 125 (wx 2.8.11):
# if we need to adjust
if new_vs_x != -1 or new_vs_y != -1: #print "%s: (%s, %s)" % (self.GetName(), new_vs_x, new_vs_y)
self.Scroll(new_vs_x, new_vs_y)
Change:
# if we need to adjust
if new_vs_x != -1 or new_vs_y != -1: #print "%s: (%s, %s)" % (self.GetName(), new_vs_x, new_vs_y)
if self.HasScrollbar(wx.HORIZONTAL):
new_vs_y += 15
self.Scroll(new_vs_x, new_vs_y)
When above is used and a control is not within the viewable area and I call
spanel.ScrollChildIntoView(child) and the scrolled panel has a horizontal
scrollbar then the child is just barely viewable after the call.
I like to suggest the following change to fix this:
Original code at about line 125 (wx 2.8.11):
\# if we need to adjust
if new\_vs\_x \!= \-1 or new\_vs\_y \!= \-1:
\#print "%s: \(%s, %s\)" % \(self\.GetName\(\), new\_vs\_x, new\_vs\_y\)
self\.Scroll\(new\_vs\_x, new\_vs\_y\)
Change:
\# if we need to adjust
if new\_vs\_x \!= \-1 or new\_vs\_y \!= \-1:
\#print "%s: \(%s, %s\)" % \(self\.GetName\(\), new\_vs\_x, new\_vs\_y\)
if self\.HasScrollbar\(wx\.HORIZONTAL\):
new\_vs\_y \+= 15
self\.Scroll\(new\_vs\_x, new\_vs\_y\)
If I am understanding correctly the issue your seeing, your saying
that the scrolling doesn't account for the horizontal scrollbar at the
bottom of the screen obscuring part of the view?
It would be better to get the scrollbar size from the system settings
instead of using a hard coded 15, as this can vary from system to
system.
When above is used and a control is not within the viewable area and I call
spanel.ScrollChildIntoView(child) and the scrolled panel has a horizontal
scrollbar then the child is just barely viewable after the call.
I like to suggest the following change to fix this:
Original code at about line 125 (wx 2.8.11):
# if we need to adjust
if new_vs_x != -1 or new_vs_y != -1: #print "%s: (%s, %s)" % (self.GetName(), new_vs_x, new_vs_y)
self.Scroll(new_vs_x, new_vs_y)
Change:
# if we need to adjust
if new_vs_x != -1 or new_vs_y != -1: #print "%s: (%s, %s)" % (self.GetName(), new_vs_x, new_vs_y)
if self.HasScrollbar(wx.HORIZONTAL):
new_vs_y += 15
self.Scroll(new_vs_x, new_vs_y)
If I am understanding correctly the issue your seeing, your saying
that the scrolling doesn't account for the horizontal scrollbar at the
bottom of the screen obscuring part of the view?
It would be better to get the scrollbar size from the system settings
instead of using a hard coded 15, as this can vary from system to
system.
On Wed, Dec 1, 2010 at 8:58 AM, werner<wbruhin@free.fr> wrote:
When above is used and a control is not within the viewable area and
I call
spanel.ScrollChildIntoView(child) and the scrolled panel has a
horizontal
scrollbar then the child is just barely viewable after the call.
I like to suggest the following change to fix this:
Original code at about line 125 (wx 2.8.11):
# if we need to adjust
if new_vs_x != -1 or new_vs_y != -1: #print "%s: (%s, %s)" % (self.GetName(), new_vs_x, new_vs_y)
self.Scroll(new_vs_x, new_vs_y)
Change:
# if we need to adjust
if new_vs_x != -1 or new_vs_y != -1: #print "%s: (%s, %s)" % (self.GetName(), new_vs_x, new_vs_y)
if self.HasScrollbar(wx.HORIZONTAL):
new_vs_y += 15
self.Scroll(new_vs_x, new_vs_y)
If I am understanding correctly the issue your seeing, your saying
that the scrolling doesn't account for the horizontal scrollbar at the
bottom of the screen obscuring part of the view?
It would be better to get the scrollbar size from the system settings
instead of using a hard coded 15, as this can vary from system to
system.
On Wed, Dec 1, 2010 at 8:58 AM, werner<wbruhin@free.fr> wrote:
When above is used and a control is not within the viewable area and
I call
spanel.ScrollChildIntoView(child) and the scrolled panel has a
horizontal
scrollbar then the child is just barely viewable after the call.
I like to suggest the following change to fix this:
Original code at about line 125 (wx 2.8.11):
# if we need to adjust
if new_vs_x != -1 or new_vs_y != -1: #print "%s: (%s, %s)" % (self.GetName(), new_vs_x, new_vs_y)
self.Scroll(new_vs_x, new_vs_y)
Change:
# if we need to adjust
if new_vs_x != -1 or new_vs_y != -1: #print "%s: (%s, %s)" % (self.GetName(), new_vs_x, new_vs_y)
if self.HasScrollbar(wx.HORIZONTAL):
new_vs_y += 15
self.Scroll(new_vs_x, new_vs_y)
If I am understanding correctly the issue your seeing, your saying
that the scrolling doesn't account for the horizontal scrollbar at the
bottom of the screen obscuring part of the view?
It would be better to get the scrollbar size from the system settings
instead of using a hard coded 15, as this can vary from system to
system.