It's good to keep that feature in mind but I don't think macro
developers will have a lot of time to develop their own insertion screen.
We should focus our priority more on having the right list of "field
types" in the definition system for macros.
On this subject here are my comments with a general +1 on the dialog:
0/ This system should support velocity macros right from the start. This
is the easiest way to write macros. We should even have a page in the
admin to manage the libraries (including the velocity macros) and add a
new one using a simple form. This would create a descriptor for the
library/macros and make the macro available right from the start. This
is a good way to make XWiki extensible. We could even have a button to
propose the macro for inclusing on
http://code.xwiki.org.
And the macro system should be connected to the Application Manager or
better name Extension Manager.
1/ Should category be category or should it be library (corresponding to
a set of macros provided by a installable library). Or should we have
both ?
For the sake of simplicity I think we could only have library and then
introduce a category later (but how is the category list managed).
2/ There should be a nice description for the library/category and a
link to documentation. This can appear as a toolip or it could be
possible to click on the category/library and the next screen would show
the list of macros with the description of the macro and at the top the
description of the category/library. The category/library could have a
screenshot or icon for visual indentification.
3/ There should be a description for each macro. This can appear as a
tooltip.
4/ Each param of a macro should have a description, a name, a pretty
name (language based), a default value and wether it is required. The
default value can be displayed under the field.
5/ The non editable macro bloc in the wysiwyg that would show the result
in wysiwyg is cool but could be a phase 2 feature.
6/ Even double clicking to reedit is a phase 2 feature.
Ludovic
Jerome Velociter a Ă©crit :
+1 for the general layout.
As a side note, I'd like we consider introducing a hook for macros to
provide their own insertion dialog (in place of the generic 2bis). This
would allow to have restrictions on parameter combinations. (for
example: user can define a value for param2 only if param1 has been set
to a specific value - this is the case for the map macro : we could say
width and height parameters are meaningless unless the size parameter
has been set to "custom"). I suppose we could also define those rules in
the rendering with new annotations and still use a generic dialog, but
it would probably be overkill compared to custom dialogs provided by the
macro itself.
Anyway, just an idea.
Jerome.
Jean-Vincent Drean wrote:
Hi,
I've made a mockup for the macro dialog in the WYSIWYG editor :
http://incubator.myxwiki.org/xwiki/bin/download/Mockups/WebHome/MacroDialog…
I've assumed that using a tree to browse macros was :
- Scalable.
- Consistent with link dialogs.
Shout if you think about another way of displaying them.
Note that the second dialog is generated dynamically and will vary a
lot according to macros needs (see 2 bis), its layout must remain as
simple as possible.
Here's my +1.
JV.
_______________________________________________
devs mailing list
devs(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/devs
_______________________________________________
devs mailing list
devs(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/devs
--
Ludovic Dubost
Blog:
http://blog.ludovic.org/
XWiki:
http://www.xwiki.com
Skype: ldubost GTalk: ldubost