On Tue, Apr 30, 2013 at 7:58 PM, Vincent Massol <vincent(a)massol.net> wrote:
Hi Denis,
On Apr 30, 2013, at 1:26 PM, Denis Gervalle <dgl(a)softec.lu> wrote:
Hi devs,
I have a very bad feeling with proposal 3, since it split the identifier,
which makes its main part to loose its meaning when taken alone. So you
cannot comunicate the whole information easily on different channels
(think
about copy/pasting such reference ?). This is
also really verbose,
sometime
it looks odd, and I found it to be complex from a
user view point.
Moreover, it could not be easily applied in other situation than links,
while ressource identification is not limited to links (think about a
macro
arguments ?, see MotionComposer macro that
imitate image: for an
example).
I know it is hard, but I am currently -1 for this
proposal.
If we look at large, what we really need and intend to achieve is to have
an extensible syntax to identify ressources in XWiki. There is obviously
a
ready made standardized syntax for such purpose:
URN. Proposal 1 is
really
near that specification (but too verbose for
URL), but I agree with
Thomas
that users will complains to be forced to use
doc: everywhere. This is
precisely why I made proposal 2, which will fully avoid that constrains
for
user of single wikis (a lot of our user since XE
was our mostly
downloaded
distribution until now).
So my vote are (sorry Vincent, but your request to have a truly single
vote
is far too restrictive for this matter)
+1 to really conform with a URN syntax as much as possible (remove the
useless verbosity for URL).
Proposal 1: +0
Proposal 2: +1
Proposal 3: -1
I also prefer URIs but my problem with solution 2 is having to prefix with
"doc:" for links to subwikis. This is pretty common.
I do not see why this is so annoying, we type http:// to start URLs, and I
do not feel anyone has ever complains. So, solution 1 is not that bad, and
solution 2 is only a feature over it, for those who use very basic feature.
It compare to the omnibox of chrome that try to be clever and works in most
situations, but some still require you to enter the http:// prefix.
I had proposed another solution in the other thread
with a different
notation for proper URI notations. The idea was to use the shortcut
notation when you wanted to use document references for simplicity reasons
and use the proper syntax when you use proper URIs.
Maybe that solution wasn't that bad. I'm putting it again here (with a
difference using [[[…]]] instead of >>> as I had said since that doesn't
work for images):
* Shortcut notation for doc refs: [[label>>docref]]
* General notations for URIs: [[[label>>type:reference]]]
* Shortcut notation for images: [[image:docref]]
* General notation for URIs in images: [[[image:type:reference]]]
It looks clunky at first but it isn't really since it represents what we
want:
* shortcut notation for doc URIs
* full notation for any URI
WDYT?
This again increase complexity (from a user POV) for very little benefit
IMO. It look odd and again it cannot be applied anywhere, like in macros.
So I see this fourth solution not much better than solution 3.
Thanks
-Vincent
Thanks,
On Tue, Apr 30, 2013 at 12:30 PM, Vincent Massol <vincent(a)massol.net>
wrote:
> Typos below.
>
> On Apr 30, 2013, at 11:02 AM, Vincent Massol <vincent(a)massol.net>
wrote:
>
>> Hi devs,
>>
>> Following this thread
http://markmail.org/thread/vw3derowozijqalr it
> seems clear that we need to introduce a better syntax for links and
images
> in XWiki Syntax 2.2 (in order to cope with
use cases such as
>
http://jira.xwiki.org/jira/browse/XRENDERING-290).
>>
>> The need is to be able to plug new reference type handlers without
> breaking backward compatibility in XWiki Syntax 2.2 (since right now
with
> XWiki Syntax 2.0 and 2.1 adding a new type
reference handler would break
> backward compatibility).
>>
>> So here are various proposals to that effect for XWiki Syntax 2.2 (I've
> only kept the interesting proposals from the previous thread). Please
vote
> for the one you prefer or add new solutions
if you have other better
ideas.
>>
>> Proposal 1
>> =========
>>
>> Force XWiki Syntax 2.2 to *ALWAYS* use the full form when creating a
> link or image, i.e. all links would need to be written:
> [[label>>type:reference]]
>>
>> Examples:
>> * [[label>>doc:space.page]]
>> * [[label>>doc:wiki:space.page]]
>> * [[label>>path:/some/path]]
>> * [[
label>>url:http://xwiki.org]]
>> * [[label>>user:evalica]]
>> * [[image:doc:wiki:space.page@image.png]]
>> * [[image:icon:someicon.png]]
>>
>> CONS:
>> * Harder to write links to documents which is the main use case
>>
>> Proposal 2
>> =========
>>
>> Same as with XWiki Syntax 2.1 but for links or images to subwikis force
> the user to use the "doc:" notation
>>
>> Examples:
>> * [[label>>space.page]] or [[label>>doc:space.page]]
>> * [[label>>doc:wiki:space.page]]
>> * [[label>>>path:/some/path]]
>
> Should be [[label>>path:/some/path]]
>
>> * [[
label>>http://xwiki.org]] or [[
label>>>url:http://xwiki.org]]
>
> Should be [[
label>>http://xwiki.org]] or [[
label>>url:http://xwiki.org
]]
>
>> * [[label>>user:evalica]]
>> * [[image:doc:wiki:space.page@image.png]]
>> * [[image:icon:someicon.png]]
>>
>> PRO:
>> * Still easy to reference docs and images in the current wiki
>> * Close to current XWiki Syntax 2.1
>>
>> CONS:
>> * Harder to write links to documents in subwikis (for workspaces users
> for example, see example of
xwiki.org)
>>
>> Proposal 3
>> =========
>>
>> Always define the type as a link or image parameter, i.e. separate
> subwiki notation from type.
>>
>> Examples:
>> * [[label>>space.page]] or
[[label>>space.page||type="doc"]]
>> * [[label>>wiki:space.page]] or
[[label>>wiki:space.page||type="doc"]]
>> * [[label>>>/some/path||type="path"]]
>
> Should be [[label>>/some/path||type="path"]]
>
>> * [[
label>>http://xwiki.org]] or [[
label>>>http://xwiki.org
> ||type="url"]]
>
> Should be [[
label>>http://xwiki.org]] or [[
label>>http://xwiki.org
> ||type="url"]]
>
> Thanks
> -Vincent
>
>> * [[label>>evalica||type="user"]]
>> * [[image:wiki:space.page@image.png]] or
> [[image:wiki:space.page@image.png||type="doc"]]
>> * [[image:someicon.png||type="icon"]]
>>
>> PRO:
>> * Still easy to reference docs
>> * Clear separation between subwiki and types
>>
>> CONS:
>> * Harder to write typed links
>> * Harder to write references in non xwiki/2.x syntax that would not
> support link parameters
>>
>> Thanks
>> -Vincent
_______________________________________________
devs mailing list
devs(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/devs
--
Denis Gervalle
SOFTEC sa - CEO
eGuilde sarl - CTO