Hi
Thanks For reply. I can manipulate widget property through QDesignerPropertySheetExtension But where i have to provide my property in QDesignerCustomWidgetInterface . Can u plz elaborate what u r saying
Hi
Thanks For reply. I can manipulate widget property through QDesignerPropertySheetExtension But where i have to provide my property in QDesignerCustomWidgetInterface . Can u plz elaborate what u r saying
Did you read this example ?
Hi
I have just read the example .I think The only place where i can provide the compound Property is domxml function .But my Compound Property is not coming on the widget property editor so what i am missing .
I am giving u some design what i am doing
I have created a CustomProp Class Its Plugin CustomPropPlugin
Exteansion Class Subclassed from QDesignerPropertySheetExtension and the factory class derived from QExtensionFactory Ok
Now In the initialize function of plugin i am getting the extension class of Qt designer and throught that i register the manager class
I have also implemented just the method of QDesginerPropertyExtension in my Extension Class
So am i missing something or doing something wrong
How does your domXml() look?
return "<widget class=\"CustomWidgetPropertyShow\" name=\"customWidgetPropertyShow\">\n"
" <property name=\"geometry\">\n"
" <rect>\n"
" <x>0</x>\n"
" <y>0</y>\n"
" <width>100</width>\n"
" <height>100</height>\n"
" </rect>\n"
" </property>\n"
"</widget>\n";
Also if add something it will come as dynamic property .I have just checked with adding something but it gives the flavour of dynamic Property which i don't want .I wnat the custom struct to appear as static Property
May be I asked a wrong question, we should be looking at Extension class, did you properly implement these
Qt Code:
To copy to clipboard, switch view to plain text mode
Hi
I have not found very clear explanation of implementation of these function in the documenatation .so can provide me some stuff on this
Most of the functions should be clear enough, provided you understand how Qt Designer works. What did you implement in the virtual functions of Extension class?
All these virtual functions should be implemented properly for the widget custom properties to be displayed in Qt Designer.
for example if your widget has 2 QString properties "PRO1", "PRO2" then implementation would like this,
Qt Code:
int count() const { return 2; } { if(index == 0) return pro1; else if(index == 1) return pro2; } { }To copy to clipboard, switch view to plain text mode
note you need to implement all the functions properly..
Last edited by Santosh Reddy; 27th June 2011 at 12:04.
Hi
very very Thanks. I think that now i can implement the Custom (Compound Property ) On the Widget .
Hi,
If I implement my own property sheet extension so in this case i will miss the default property editor given by the widget or the qt designer . But i want to use the both property editor the one provided by the QT designer and other which is written by me So is there any way
I not very sure, but this should work, as per documentation
From the QDesignerFormEditorInterface object, get the previous property editor interface instance, and map the properties in your class, like map 0 to n properties from previous property editor, and n to m are your custom properties, as you know you can get and set the 0 to n properties using previous property editor interface instanceOriginally Posted by Qt Documnetation
Hi
The Problem is that how can i map those property becoz In the QDesignerPropertyEditorInterface No method is there ,also if i will go for meta object and get the Property through meta object i am not sure it will work .However i am doing work on this
By the way Thanks For Reply Sir
Bookmarks