Removing the Scrollbar from Horizontal List - apache-flex

I've got an Horizontal List. It contains 6 XML Nodes at the moment. But what I'd like to do is remove the scrollbar so that an button can function to scroll through the nodes instead.
Has anyone achieved this, if so how did you go about it?
Thanks in advance

You can usually remove the scroll bar by setting the horizontalScrollPolicy or verticalScrollPolicy to off.
After that, I believe you can scroll the list by setting the verticalScrollPosition or horizontalScrollPosition

Related

How to show several QTableViews(without scrollbar) in QListWidget(or other similar widgets)?

I have a problem with showing multiple tables(without their own scrollbars) under one scrollbar. Is there any workaround or a good way to resolve this issue in Qt?
I've tried to do what you ask, and found this. So, here is a solution:
add QScrollArea to a form
set the property widgetResizable to true
put QWidget to scroll area
right click on widget -> Set ancestor -> [your scroll area]
add vertical layout to a widget
scroll area will collapse, epand it with a mouse
insert into the widget as many tables as you want
set vertical size policy for each table to Minimum and set minimal vertical size.
Here is how it looks:

Flex: preventing tree's vertical scroll bar overlapping view

I have an mx:Tree, but when the vertical scroll bar appears, it overlaps the content of the tree (odd that the horizontal bar does not). That might be acceptable for the text, but the stripe that I create using the item renderer, for certain items, seems to make it an anathema to the QA guys. How can I keep this from happening?
I have an idea for a workaround: I could make use the item renderer to stop the drawing a little bit short of the right side of the view (not that I can reliably get the width of a scroll bar) but I can't even figure out how wide the displayable part of a tree is--all the properties of a tree seem to be about its entire width, which includes the entire area coverable using the horizontal scroll bar. However, the blue stripe signifying a selected item doesn't seem to have that problem--it stops short of the scroll bar. In any case, when trying to find the displayable region, I don't know if I could handle the added complication of when the horizontal scroll bar is moved. Much better if someone could tell me how to put the veritcal bar outside the displayable tree area (or shrink the displayable area, of course). Thanks.
I'm using the Flex 3.5 SDK
I was able to find the solution when researching horizontal scrollbar issue on list and tree component. The blog to which it links eventually shows a kind of hacky solution (in the readers' comments) that shows how to make sure that none of the drawing is done beyond a certain boundary.

Qt: Transparent scrollbar

I'd like to make a background of a scrollbar of QListView transparent. It should be painted over the content. Something like this. Is it possible?
Sure. Subclass it, override the paint event, and read this.
GUI style on screenshot is QML i think
I ended up with this hack. I just created a new vertical scroll bar, placed it onto viewport and connected it with the original scroll bar. Then I just hidden the original scrollbar :)
You can see the result: http://i.stack.imgur.com/wrQOQ.png

Displaying data horizontally with no scroll bar

I need to build a list of strings with a checkbox next to each one of them. I want to build it horizontally, but I don't want a horizontal scroll bar to appear. I was thinking of using either a Repeater or a DataList for the task, but how do I wrap the data to prevent a scroll bar to appear?
Try the CheckBoxList but set the repeatdirection to be horizontal and set the container to a specified width but not a specified height.
You can place all of your controls inside this Div
<div style="overflow:scroll;overflow-x:hidden; height:300px;"></div>
I Hope this will resolve your problem.

Centering item renderers in a HorizontalList

I am trying to center itemRenderers in a horizontal list if the number of items in the list is less than the maximum visible number. Has anyone found a good way to do this?
See an illustration of what I mean if it is hard to picture.
Thanks!
Override the measure() method - I've writen a blog entry here: http://flexmonkey.blogspot.com/2010/05/centre-aligned-horizontallist-in-flex.html
simon
One solution that comes to mind would be to add invisible renderers to achieve the same centering.
You might want to consider using a horizontal box or "Hbox" instead of a horizontal list component. This will allow you to use the horizontal align property to set center. If not, simply extend the horizontal list component to accept a center align property, and copy it from the hbox to your new extended component.
Would paddingRight or paddingLeft accomplish what you're looking for? If you combine it with setting the columnWidth and the columnCount, that would allow you to adjust where the items first appear.

Resources