PDA

View Full Version : QML and QT integeration



nageshvk
8th December 2010, 06:06
Hi

Consider I have two QML files named 1.qml and 2.qml.
1.qml contains aaa,bbb,ccc as text.
2.qml contains ddd,eee,fff as text.

I have QT table with columns sno sname
sno| sname
------------
1| aaa
----------
2| bbb
----------
3| ccc

Now when user select a row for ex: aaa i am displaying parsing the QML files and diplaying the correspoing QML file using QDeclarative View.

My Requirement was...... I should display a RED BORDER in the display qml for the selected ID...in this case "aaa" must be in a red box.

I hope i have cleared mentioned my issue.

Regards
Nagesh

wysota
8th December 2010, 10:22
I hope i have cleared mentioned my issue.
No, not really.

What are you having problems with? The table view or the declarative view part? What did you already try to solve your problem?

nageshvk
8th December 2010, 10:54
Step1:
I have a table with few rows .
sno| sname
------------
1| aaa
----------
2| bbb
----------
3| ccc


Step2: When user selectes a row (for example "1". "aaa"). I am parsing all the QML files available in my workspace for the selected text. In this case "aaa" since "aaa" row is selected.

Step3:I am displaying the QML files as thumbnails that are having "aaa" text.

(My problem starts here)
Step4: On the thumbnail i need to show "aaa" in a red border/frame/underline/color whihc help the user to easily read when opens it as declarative view.
How to do that?

Regards
Nagesh

wysota
8th December 2010, 11:10
Write a delegate for your thumbnail view that will display a red border around the item when some condition is met.