On 09/05/2010 04:57 PM, Uwe Stöhr wrote:
Am 05.09.2010 09:05, schrieb Abdelrazak Younes:
Could you please try to use InsetParamsWidget for new dialogs instead
of GuiDialog? Each time I
migrate a dialog, some others are popping up...
InsetParamsWidget is easier to use and will results in much less
lines of code. Look at GuiHSpace or
GuiVSpace as an example.
I started the dialog from GuiHspace but the result was much more code
than that I have now.
This is really weird... if you still have it could you post the patch?
What is the problem of using InsetCommandParams?
- serialisation/deserialisation:
using InsetParamsWidget will get the info directly from the cursor
position not from where the dialog was launched.
- GuiDialog means hard connection between the inset and the dialog.
- InsetParamsWidget will give an uniform to all inset dialogs by being
used in InsetParamsDialog.
- InsetParamsWidget could be used in another dialog container. Right now
for example, it is very easy to create one dialog (or Dock widget) that
will offer more than one inset configuration.
Where do you think I can save code in my latest patch? I cannot think
of less code for a dialog than what I currently have.
True, the dialog is simple.
My point is that if all InsetParams used InsetParamsWidget we would have
a lot more consistency and configurability.
Abdel.