Adding ScrollBar in GridContainer | developer.brewmp.com Adding ScrollBar in GridContainer | developer.brewmp.com

Developer

Adding ScrollBar in GridContainer

Hi,

All ,is it possible to add a scrollbar in a GridContainer. Acutally I want to show some image widgets in the GridContainer and if the number of images are more, then I want scroll it(grid container).

I make the ScrollBar widget and wrap it with forms widget which contain the GridContainer. Everything is okey but the scroll bar does't appear.what could the reason behind it.

please reply...its urgent.

You need to wrap the container in a viewport, and wrap that in a scrollbar.
-Erik

You need to wrap the container in a viewport, and wrap that in a scrollbar.
-Erik

Hi, ebrowne
Quote:You need to wrap the container in a viewport, and wrap that in a scrollbar.
I have make a XYContainer which contains some text and static widgets.I added the scrollbar to the container widget successfully with the help of the ViewPort widget, but the problem is that when I press the AVK_DOWN key the scroll bar is working but I can't get focus on the text widgets for entery of data,and when I tried with IWIDGET_SetProperty(&pIWViewPort,PROP_INCREMENT,0) then when I reach the last displayable widget(on screen) the scrollbar is not working for rest of widgets which are hidden.
Now the question is that, how to override the viewport handler to get the required result. please post some code example.
waiting for replies.......

Hi, ebrowne
Quote:You need to wrap the container in a viewport, and wrap that in a scrollbar.
I have make a XYContainer which contains some text and static widgets.I added the scrollbar to the container widget successfully with the help of the ViewPort widget, but the problem is that when I press the AVK_DOWN key the scroll bar is working but I can't get focus on the text widgets for entery of data,and when I tried with IWIDGET_SetProperty(&pIWViewPort,PROP_INCREMENT,0) then when I reach the last displayable widget(on screen) the scrollbar is not working for rest of widgets which are hidden.
Now the question is that, how to override the viewport handler to get the required result. please post some code example.
waiting for replies.......

Set the VWF_DISABLEKEYHANDLING flag on the viewport to disable its automatic key handling. You will have to programatically scroll the viewport by calling IWIDGET_SetOffsetY().
-Erik

Set the VWF_DISABLEKEYHANDLING flag on the viewport to disable its automatic key handling. You will have to programatically scroll the viewport by calling IWIDGET_SetOffsetY().
-Erik