I would like to design a particular layout using QTable inside of QTree. See the followng wireframe :
Is it possible to do this, knowing that in number :
The first node under Dialog 1 is seperated in 3 (or maybe four). The time, followed by an avatar icon, followed by a blue bubble with text and followed by a number (in my exemple, 75) So, first question, is it possible to have a tree node separated in four?
Section 2 is composed of leaf nodes and these nodes are QTable. So, question number 2, is it possible to create QTable embedded inside a QTree?
You can use the setItemWidget function in order to set the widget you wish for every tree widget item you wish.
In case of a QTreeView you should use the setIndexWidget function.
Related
I'm working with a CollectionView with a grid items layout. I would like to know if there's a way to show like empty "squares" (boxView/absoluteLayout...) depending on a minimum number of a source items (binding it using MVVM).
I want something like this:
The minimum number would be 14, my items source has a length of 8, I add 6 "empty squares".
Is it possible to do something like this easily?
You need two DataTemplates: one for the monkeys, the other for the empty box.
Make an interface ISquare, and implement it in a MonkeySquare and and EmptySquare.
Make the binded List of type ISquare and add 8 MonkeySquares and 6 EmptySquares.
In your Xaml make a DataTemplateSelector where you check if its the Cell is a MonkeySquare or a EmptySquare and return the belonging DataTemplate.
For more information regarding DataTemplateSelectors visit the official doc.
Hello
I want to show nodes to the columns, depending on their term.
Is it possible via single view (term with depth arg)?
It will be rather complicated to achieve this result using a single view. On the other hand, you could easily set up Panels and a view pane that gets some arguments from the pane's column container. There you could set the different terms you want to show in that column.
The tree should have a minimum row count of 4 and a maximum of 10 (beyond which it should display the scroll bars). So, I have a tree with rowCount="4" and I want rowCount to change up to "10" depending on the currently expanded nodes. In debug I can see two of the tree's properties which I could use:
- collectionLength
- numberOfRows
But these are not accessible from outside so I can't find a way to understand if the tree is expanded or not.
How can I do this?
Will I have to create a custom MyTree which inherits from Tree? I was trying to avoid this...
Thanks,
Nuno
Not sure if you already got this figured out but this should be all you need to determine what's open http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/mx/controls/Tree.html?filter_flex=4.1&filter_flashplayer=10.1&filter_air=2#openItems
Does anybody know how i can create a stacking list component (just like photoshop) where the first row starts at the bottom and the second on above the bottom and so on.
Normally the list component works like this.
0
1
2
3
what i need is a list component that works like this
3
2
1
0
To illustrated my question i have uploaded a picture of the component i need to build.
The rowindex of the inverted list component must start at the bottom.
meaning that the lowest row in the list is always zero.
Does anybody know how i can accomplish this?
Thanks
DJ
one way of doing this is to always add the row in the container using this.addChildAt(0);
by doing this every new row will be added to zero index and its order will be reverted from default order
Define a new layout to do this. This answer has some starting links.
Make sure you get the virtual layout working as well for the list control (I suggest just grabbing the VerticalLayout and changing the updateDisplayListReal.
obviously you are storing the layers information in array or something like this. just revers the the array before assigning it to list control.
that is
var a:Array = ["1","2","3"];
a.reverse();
now it will look like
// 3 2 1 when assigned to list control as data provider.
I wonder if it is possible to select item that belongs to one group, without selecting whole group.
What I trying to make is a group of items, that can be moved (all items are moved together) but none of them can't be moved individually. But I want also to be able to select items inside this group and then do something with them, like reordering, deleting, changing their color, etc.
The other problem is, there can be group of groups. I wish also to be able to select these groups inside parent group. I was thinking that this could be problem, because we are not able to determine which group users want to select. For demonstration purpose, lets say that we have graphic's scene composed of following items:
Group A which contains group B. The group B contains 3 lines.
If I press double click on group A, then I am then able to select group B. If I again press double click on B, then I am able to select lines inside group B. Pressing Esc does opposite as double click. The problem is, I have no idea how to do that, because all selection is routed to the parents, and than back to all its children.
You can't use QGraphicsItemGroup to do this because selecting one item in a group automaticaly selects all other memebrs of the group.
I'd subclass QGraphicsItem to create a 'RootItem' class. This class would contain two lists. One is a list of ordinary QGraphicsItems that make up the visual elements of the group itself, parented to this RootItem. The other list is of other RootItems that are parented to this one (e.g. Group B).
You would just need to make sure that you carefully controlled which items are selectable at any one time and how the interactions propagate between items.
Hope this helps.