Re: [xwiki-users] macros and lists

2010-02-25 Thread Jeremie BOUSQUET
Thanks, meanwhile I realized that some macros had this behaviour (toc...), and that is was because they are Java macros ... ;-) 2010/2/25 Thomas Mortagne > On Wed, Feb 24, 2010 at 23:57, Jeremie BOUSQUET > wrote: > > If I can give my opinion, I think it would be more coherent if macro > > param

Re: [xwiki-users] macros and lists

2010-02-25 Thread Thomas Mortagne
On Wed, Feb 24, 2010 at 23:57, Jeremie BOUSQUET wrote: > If I can give my opinion, I think it would be more coherent if macro > parameters were defined like class properties are (lists, strings, numbers, > Dates, list of users or groups, and so on...). That's exactly how real (JAVA) macros are de

Re: [xwiki-users] macros and lists

2010-02-24 Thread Jeremie BOUSQUET
If I can give my opinion, I think it would be more coherent if macro parameters were defined like class properties are (lists, strings, numbers, Dates, list of users or groups, and so on...). But it would not be a requirement for me, just an interesting improvement. And I'm not sure about how this

Re: [xwiki-users] macros and lists

2010-02-23 Thread Sergiu Dumitriu
On 02/23/2010 10:33 AM, Stefan Bachert wrote: > > Hi Thomas, > > For me it looks that ALL parameter will be converted to STRING > Let's go into concrete > > How to be defined - > {{velocity}} > #set($list = $xcontext.macro.params.listX) > list = $list > #foreach($x in $list

Re: [xwiki-users] macros and lists

2010-02-23 Thread Thomas Mortagne
On Tue, Feb 23, 2010 at 10:33, Stefan Bachert wrote: > > Hi Thomas, > > For me it looks that ALL parameter will be converted to STRING > Let's go into concrete > > How to be defined - > {{velocity}} > #set($list = $xcontext.macro.params.listX) > list = $list > #foreach($x

Re: [xwiki-users] macros and lists

2010-02-23 Thread Stefan Bachert
Hi Thomas, For me it looks that ALL parameter will be converted to STRING Let's go into concrete How to be defined - {{velocity}} #set($list = $xcontext.macro.params.listX) list = $list #foreach($x in $list) item = $x #end {{/velocity}} How to apply

Re: [xwiki-users] macros and lists

2010-02-23 Thread Vincent Massol
On Feb 23, 2010, at 10:07 AM, Thomas Mortagne wrote: > On Tue, Feb 23, 2010 at 09:07, Stefan Bachert wrote: >> >> Ok, let's go into details. >> >> I want to create a macro which build a with its tag. >> Let call them {{buildSelect values=.. /}} >> For the option items I need a list of string

Re: [xwiki-users] macros and lists

2010-02-23 Thread Thomas Mortagne
On Tue, Feb 23, 2010 at 09:07, Stefan Bachert wrote: > > Ok, let's go into details. > > I want to create a macro which build a with its tag. > Let call them {{buildSelect values=.. /}} > For the option items I need a list of string values > calling > {{buildSelect values=["a","b","c"] /}} > does

Re: [xwiki-users] macros and lists

2010-02-23 Thread Stefan Bachert
Ok, let's go into details. I want to create a macro which build a with its tag. Let call them {{buildSelect values=.. /}} For the option items I need a list of string values calling {{buildSelect values=["a","b","c"] /}} does not work. Display values in the macro just shows "[". OK, there is a

Re: [xwiki-users] macros and lists

2010-02-22 Thread Thomas Mortagne
On Mon, Feb 22, 2010 at 10:50, stefan bachert wrote: > Hi, > > I figured out the macro capability. That is real powerful stuff. > > However, I failed to pass a list to macros. > Is this a bug or by design? It depends what you mean exactly by "pass a list to macros". > > Stefan Bachert > > >

Re: [xwiki-users] macros not executed?

2008-11-19 Thread Yishay Mor
itriu <[EMAIL PROTECTED]> Subject: Re: [xwiki-users] macros not executed? Yishay Mor wrote: > At > http://patternlanguagenetwork.myxwiki.org/ > I'm seeing a strange phenomena. Some macros ocasionaly appear literally in > the rendered page, and are only evaluated when I re

Re: [xwiki-users] macros not executed?

2008-11-18 Thread Sergiu Dumitriu
Yishay Mor wrote: > At > http://patternlanguagenetwork.myxwiki.org/ > I'm seeing a strange phenomena. Some macros ocasionaly appear literally in > the rendered page, and are only evaluated when I refresh. Where are the macros defined? Is it scripts.IndexPage? There is a problem in the way macros a

Re: [xwiki-users] macros

2008-08-29 Thread Marius Dumitru Florea
> > hello > if i wanna create a simple macro that shows an internal space link is this > correct? does not work: > //mymacros.vm > #macro(includeForm $doc.web) AFAIK, a macro parameter is a variable, not an expression. So why not write: #macro(includeForm $doc) or #macro(includeForm $space) >

Re: [xwiki-users] Macros

2008-05-16 Thread Sergiu Dumitriu
Mihails Agafonovs wrote: > I've defined a macro #make-div(), but it doesn't work! Even after I've > restarted Tomcat. > Ar cieņu, Mihails Try without -, it's not a valid character for a macro name. -- Sergiu Dumitriu http://purl.org/net/sergiu/ ___ use

Re: [xwiki-users] Macros in XWiki.org dev guide

2008-02-01 Thread Ludovic Dubost
At this point, #includeMacros is the way to go. We would need to see how to have velocity load wiki pages declared in the preferences as global Macros. But this is not yet available in XWiki. One trick which has some (very slight ) performance cost is to add your macros in your skin. This way

Re: [xwiki-users] Macros in XWiki.org dev guide

2008-01-31 Thread Jerome Velociter
>> -Original Message- >> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On > Behalf >> Of Jerome Velociter >> Sent: Wednesday, January 30, 2008 3:37 PM >> To: XWiki Users >> Subject: Re: [xwiki-users] Macros in XWiki.org dev guide >> &

Re: [xwiki-users] Macros in XWiki.org dev guide

2008-01-30 Thread Paul Grodt
> -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf > Of Jerome Velociter > Sent: Wednesday, January 30, 2008 3:37 PM > To: XWiki Users > Subject: Re: [xwiki-users] Macros in XWiki.org dev guide > > Hello, > > > The dev gu

Re: [xwiki-users] Macros in XWiki.org dev guide

2008-01-30 Thread Jerome Velociter
Hello, > The dev guides do a fine job explaining the use of groovy and velocity > code snippets. They also explain how to develop applications and > plugins by creating classes. However they don't do much to explain the > creation of macros; that or I'm failing to find this. > > I greatly prefer