Re: [Wicket-user] Adding Support for optgroup
For the other choice objects (The singleselectchoice, dropdownchoice) we could have a list of optgroups and the optgroup has a list of its choices So you are just makeing one line with choices and optgroups (with again a list of choices) johan On 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote: havent decided what the best way to do this is. one problem i see with passing a list of optgroups is that the optgroup will have to have an IModel for its label in case someone wants to i18n it, but then how do we handle attaching and detaching that model since its not attached to any component. maybe separate components like check and checkbox are the best way, and have an optgroup that works exactly like dropdown choice to simplify things. still thinking, thoughts? -Igor On 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote: yeah sorry, think of it as pseudo html :) -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: It would be similar to Check/CheckGroup because you could create a Select object, which is like the CheckGroup object, and an Option object, which is similar to the Check object. By doing that, then I can manually insert the optgroup tag either directly in the HTML or using a WebMarkupContainer in the JavaCode if the label needs to be dynamic. However, your thought about having an OptGroup object and extending the current DropDownChoice (and it makes sense to do the ListMultipleChoice too as you can use OptGroup with a select box that allows multiple choices) intrigues me. Maybe that is the smoothest way to go because it will reuse what's already available and would only add the one OptGroup component. I like it. By the way, your html should look like below, your HTML above is not correct:select wicket:id=selectGroup optgroup label=Label 1 option/option option/option /optgroup optgroup label=Label 2 option/option option/option /optgroup/select--AndrewOn 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote:I dont really understant what you mean. If you want to do it like the Check/CheckGroup is done you would have a SelectGroup and Select components that you would put into your html and then you can manually insert optgroup ie select wicket:id=selectGroup optgroupwicket doesnt care/optgroup select wicked:id=choice1 select wicket:id=choice2 /optgroup /select But then you are talking about making it a single component, so that is not like the Check/CheckGroup work. If i was going to build it as a single component I would use the embedded objects like you mentioned, not a map. Ie class OptGroup { List choices; IModel title; } and my component would take a list of optgroups. OR maybe something smoother would be to do extend the current DropDownChoice to do an instanceof check on the item its rendering and if its an OptGroup object write out the OptGroup. Thoughts? -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: I'm sure this is Igor's territory, but I was wondering if, like how Check/CheckGroup and Radio/RadioGroup was done, if we could also add something to permit optgroups. My thought was to have something like a Select object which takes a list of OptGroup components. The OptGroup component then takes a list of SelectOption components. The other way I was thinking about it was to add a constructor to DropDownChoice and ListMultipleChoice which takes a Map. Then each Map key could be the optgroup value and the value could be a list of what should appear within that optgroup. Thoughts?--Andrew
[Wicket-user] Unexpected behaviour when using AjaxHandler's getBodyOnloadContribution()
I encountered somewhat unexpected behavior when I tried using getBodyOnloadContribution(). When adding custom Ajaxhandlers to components I noticed that the getBodyOnloadContribution() is not called when I added the handler to an Image or a Label. It was however called upon loading the page when I added my handler to a WebMarkupContainer. Is this method meant to hehave this way? If so, I did not find it in the documentation. I think it is logical that the method is also called for Components like Label and Image. I am not really familliar with AjaxHandler's internal code however. Marco --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Adding Support for optgroup
Igor, why wouldn't the model be attached to the OptGroup object? Each OptGroup takes a model which is used for the for attribute.On 11/4/05, Johan Compagner [EMAIL PROTECTED] wrote: For the other choice objects (The singleselectchoice, dropdownchoice) we could have a list of optgroups and the optgroup has a list of its choices So you are just makeing one line with choices and optgroups (with again a list of choices) johan On 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote: havent decided what the best way to do this is. one problem i see with passing a list of optgroups is that the optgroup will have to have an IModel for its label in case someone wants to i18n it, but then how do we handle attaching and detaching that model since its not attached to any component. maybe separate components like check and checkbox are the best way, and have an optgroup that works exactly like dropdown choice to simplify things. still thinking, thoughts? -Igor On 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote: yeah sorry, think of it as pseudo html :) -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: It would be similar to Check/CheckGroup because you could create a Select object, which is like the CheckGroup object, and an Option object, which is similar to the Check object. By doing that, then I can manually insert the optgroup tag either directly in the HTML or using a WebMarkupContainer in the JavaCode if the label needs to be dynamic. However, your thought about having an OptGroup object and extending the current DropDownChoice (and it makes sense to do the ListMultipleChoice too as you can use OptGroup with a select box that allows multiple choices) intrigues me. Maybe that is the smoothest way to go because it will reuse what's already available and would only add the one OptGroup component. I like it. By the way, your html should look like below, your HTML above is not correct:select wicket:id=selectGroup optgroup label=Label 1 option/option option/option /optgroup optgroup label=Label 2 option/option option/option /optgroup/select--AndrewOn 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote:I dont really understant what you mean. If you want to do it like the Check/CheckGroup is done you would have a SelectGroup and Select components that you would put into your html and then you can manually insert optgroup ie select wicket:id=selectGroup optgroupwicket doesnt care/optgroup select wicked:id=choice1 select wicket:id=choice2 /optgroup /select But then you are talking about making it a single component, so that is not like the Check/CheckGroup work. If i was going to build it as a single component I would use the embedded objects like you mentioned, not a map. Ie class OptGroup { List choices; IModel title; } and my component would take a list of optgroups. OR maybe something smoother would be to do extend the current DropDownChoice to do an instanceof check on the item its rendering and if its an OptGroup object write out the OptGroup. Thoughts? -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: I'm sure this is Igor's territory, but I was wondering if, like how Check/CheckGroup and Radio/RadioGroup was done, if we could also add something to permit optgroups. My thought was to have something like a Select object which takes a list of OptGroup components. The OptGroup component then takes a list of SelectOption components. The other way I was thinking about it was to add a constructor to DropDownChoice and ListMultipleChoice which takes a Map. Then each Map key could be the optgroup value and the value could be a list of what should appear within that optgroup. Thoughts?--Andrew
Re: [Wicket-user] Unexpected behaviour when using AjaxHandler's getBodyOnloadContribution()
That should work. Might be a bug. Could you pls try to step into it? Eelco On 11/4/05, Marco van de Haar [EMAIL PROTECTED] wrote: I encountered somewhat unexpected behavior when I tried using getBodyOnloadContribution(). When adding custom Ajaxhandlers to components I noticed that the getBodyOnloadContribution() is not called when I added the handler to an Image or a Label. It was however called upon loading the page when I added my handler to a WebMarkupContainer. Is this method meant to hehave this way? If so, I did not find it in the documentation. I think it is logical that the method is also called for Components like Label and Image. I am not really familliar with AjaxHandler's internal code however. Marco --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Adding Support for optgroup
you mean for the label attribute? Optgroup in this case wouldnt be a component so the IModel provided needs to be attached to some component so that it is detached properly, so the user needs to worry about attaching it somewhere, and the more optgroups you have the trickier that gets. -Igor On 11/4/05, Andrew Berman [EMAIL PROTECTED] wrote: Igor, why wouldn't the model be attached to the OptGroup object? Each OptGroup takes a model which is used for the for attribute.On 11/4/05, Johan Compagner [EMAIL PROTECTED] wrote: For the other choice objects (The singleselectchoice, dropdownchoice) we could have a list of optgroups and the optgroup has a list of its choices So you are just makeing one line with choices and optgroups (with again a list of choices) johan On 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote: havent decided what the best way to do this is. one problem i see with passing a list of optgroups is that the optgroup will have to have an IModel for its label in case someone wants to i18n it, but then how do we handle attaching and detaching that model since its not attached to any component. maybe separate components like check and checkbox are the best way, and have an optgroup that works exactly like dropdown choice to simplify things. still thinking, thoughts? -Igor On 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote: yeah sorry, think of it as pseudo html :) -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: It would be similar to Check/CheckGroup because you could create a Select object, which is like the CheckGroup object, and an Option object, which is similar to the Check object. By doing that, then I can manually insert the optgroup tag either directly in the HTML or using a WebMarkupContainer in the JavaCode if the label needs to be dynamic. However, your thought about having an OptGroup object and extending the current DropDownChoice (and it makes sense to do the ListMultipleChoice too as you can use OptGroup with a select box that allows multiple choices) intrigues me. Maybe that is the smoothest way to go because it will reuse what's already available and would only add the one OptGroup component. I like it. By the way, your html should look like below, your HTML above is not correct:select wicket:id=selectGroup optgroup label=Label 1 option/option option/option /optgroup optgroup label=Label 2 option/option option/option /optgroup/select--AndrewOn 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote:I dont really understant what you mean. If you want to do it like the Check/CheckGroup is done you would have a SelectGroup and Select components that you would put into your html and then you can manually insert optgroup ie select wicket:id=selectGroup optgroupwicket doesnt care/optgroup select wicked:id=choice1 select wicket:id=choice2 /optgroup /select But then you are talking about making it a single component, so that is not like the Check/CheckGroup work. If i was going to build it as a single component I would use the embedded objects like you mentioned, not a map. Ie class OptGroup { List choices; IModel title; } and my component would take a list of optgroups. OR maybe something smoother would be to do extend the current DropDownChoice to do an instanceof check on the item its rendering and if its an OptGroup object write out the OptGroup. Thoughts? -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: I'm sure this is Igor's territory, but I was wondering if, like how Check/CheckGroup and Radio/RadioGroup was done, if we could also add something to permit optgroups. My thought was to have something like a Select object which takes a list of OptGroup components. The OptGroup component then takes a list of SelectOption components. The other way I was thinking about it was to add a constructor to DropDownChoice and ListMultipleChoice which takes a Map. Then each Map key could be the optgroup value and the value could be a list of what should appear within that optgroup. Thoughts?--Andrew
Re: [Wicket-user] Adding Support for optgroup
unless of course we just pass in a string instead of imodel and leave i18n to the user... -Igor On 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote: you mean for the label attribute? Optgroup in this case wouldnt be a component so the IModel provided needs to be attached to some component so that it is detached properly, so the user needs to worry about attaching it somewhere, and the more optgroups you have the trickier that gets. -Igor On 11/4/05, Andrew Berman [EMAIL PROTECTED] wrote: Igor, why wouldn't the model be attached to the OptGroup object? Each OptGroup takes a model which is used for the for attribute.On 11/4/05, Johan Compagner [EMAIL PROTECTED] wrote: For the other choice objects (The singleselectchoice, dropdownchoice) we could have a list of optgroups and the optgroup has a list of its choices So you are just makeing one line with choices and optgroups (with again a list of choices) johan On 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote: havent decided what the best way to do this is. one problem i see with passing a list of optgroups is that the optgroup will have to have an IModel for its label in case someone wants to i18n it, but then how do we handle attaching and detaching that model since its not attached to any component. maybe separate components like check and checkbox are the best way, and have an optgroup that works exactly like dropdown choice to simplify things. still thinking, thoughts? -Igor On 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote: yeah sorry, think of it as pseudo html :) -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: It would be similar to Check/CheckGroup because you could create a Select object, which is like the CheckGroup object, and an Option object, which is similar to the Check object. By doing that, then I can manually insert the optgroup tag either directly in the HTML or using a WebMarkupContainer in the JavaCode if the label needs to be dynamic. However, your thought about having an OptGroup object and extending the current DropDownChoice (and it makes sense to do the ListMultipleChoice too as you can use OptGroup with a select box that allows multiple choices) intrigues me. Maybe that is the smoothest way to go because it will reuse what's already available and would only add the one OptGroup component. I like it. By the way, your html should look like below, your HTML above is not correct:select wicket:id=selectGroup optgroup label=Label 1 option/option option/option /optgroup optgroup label=Label 2 option/option option/option /optgroup/select--AndrewOn 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote:I dont really understant what you mean. If you want to do it like the Check/CheckGroup is done you would have a SelectGroup and Select components that you would put into your html and then you can manually insert optgroup ie select wicket:id=selectGroup optgroupwicket doesnt care/optgroup select wicked:id=choice1 select wicket:id=choice2 /optgroup /select But then you are talking about making it a single component, so that is not like the Check/CheckGroup work. If i was going to build it as a single component I would use the embedded objects like you mentioned, not a map. Ie class OptGroup { List choices; IModel title; } and my component would take a list of optgroups. OR maybe something smoother would be to do extend the current DropDownChoice to do an instanceof check on the item its rendering and if its an OptGroup object write out the OptGroup. Thoughts? -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: I'm sure this is Igor's territory, but I was wondering if, like how Check/CheckGroup and Radio/RadioGroup was done, if we could also add something to permit optgroups. My thought was to have something like a Select object which takes a list of OptGroup components. The OptGroup component then takes a list of SelectOption components. The other way I was thinking about it was to add a constructor to DropDownChoice and ListMultipleChoice which takes a Map. Then each Map key could be the optgroup value and the value could be a list of what should appear within that optgroup. Thoughts?--Andrew
[Wicket-user] simple bookmarkable url
Is there a way to create bookmarkable page without embedding any of the Wicket implementation details in the url? For example, the template example page 2 url is: http://www.wicket-library.com/wicket-examples/template?bookmarkablePage=wicket.examples.template.Page2 However,"bookmarkablePage=wicket.examples.template" is a Wicket implementation detail thatis used because Wicket needs itand not because it is relevant to theurl. It would begood if the url could be simpler like: http://www.wicket-library.com/wicket-examples/template/Page2 Now I realize that Wicket needs to knowhow to map "Page2" to "wicket.examples.template.Page2". One wayto accomplish this could beto add a method to WebApplicationlike addAlias(String alias, Class page). For example: public class TemplateApplication extends WicketExampleApplication{ public TemplateApplication() { getPages().setHomePage(Page1.class); addAlias("Page1", Page1.class); addAlias("Page2", Page2.class); }} Here are some articles that recommend keeping implementation details outof urls: http://www.w3.org/Provider/Style/URI http://www.useit.com/alertbox/990321.html Thanks, JeffJeff Miller[EMAIL PROTECTED] Yahoo! FareChase - Search multiple travel sites in one click.
Re: [Wicket-user] Re: Previewing html only, including nested components html
The fact that one cannot preview html only using panels without running a web server means that java code it is mandatory. Do you think this is a drawback to Wicket (as well as Tapestry) that claims that designers and coders can work almost independently? 2005/11/3, Laurent PETIT [EMAIL PROTECTED]: On 11/3/05, Juergen Donnerstag [EMAIL PROTECTED] wrote: in order to be pre-viewable the html editor must be able to find the css file without the help of wicket. The easiest way to accomplish it is to put the css into your source path and by means of wicket:link (autolinks) wicket is able to find them at runtime. Ok, I understand that. But this does not solve the second issue, as you stated: And also, I'd like to have this preview include the markup of nested panels, Is it possible in development mode ? A html editor can not do it. The html editor does not know anything about wicket and panel. Oh sorry, I just re-thought about it, and I clearly understand it cannot work. This should be great, because it is hard to decompose a page into logical parts without the hassle of maintaining in synch two tag bodies or two wicket:remove elements. ?!?! What is the question? No more questions, since I had the evidence that what I was thinking of isn't at all possible (since, of course, the associated panel markup is bound to the class of the panel, and in the parent markup, there is nothing special but a wicket:id attribute, which isn't sufficient to deduce the right nested markup file ...) Sorry for this one, -- Laurent --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Re: Previewing html only, including nested components html
I use wicket:remove around relative paths to the CSS in the webapp directory. So this looks like: html head style type=text/css src=style/style.css / wicket:remove style type=text/css src=../../../../../../webapp/style/style.css / /wicket:remove The same can be done for JavaScript libraries that aren't part of a component. Martijn On 11/3/05, Juergen Donnerstag [EMAIL PROTECTED] wrote: I don't know how to correctly preview a markup html only when it refers to css, javascript files, that are meant to be relative to the webapp context. in order to be pre-viewable the html editor must be able to find the css file without the help of wicket. The easiest way to accomplish it is to put the css into your source path and by means of wicket:link (autolinks) wicket is able to find them at runtime. I think this should be done by viewing the html markup from a running instance of the webapp only ? And also, I'd like to have this preview include the markup of nested panels, Is it possible in development mode ? A html editor can not do it. The html editor does not know anything about wicket and panel. This should be great, because it is hard to decompose a page into logical parts without the hassle of maintaining in synch two tag bodies or two wicket:remove elements. ?!?! What is the question? Juergen --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- Living a wicket life... Martijn Dashorst - http://www.jroller.com/page/dashorst Wicket 1.1 is out: http://wicket.sourceforge.net/wicket-1.1 --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
[Wicket-user] Re: Previewing html only, including nested components html
It wouldn't be a drawback, since nobody does it better. But anyway, you can preview a component (in isolation) just fine in the component template without a web server. You can also preview the fake version in the page template without a server, though it's easy for that to get out of synch with the real thing. Your designers have to understand where everything is, but I think the preview (or, you can use an HTML editor) claim holds up. Nathan Eduardo Rocha wrote: The fact that one cannot preview html only using panels without running a web server means that java code it is mandatory. Do you think this is a drawback to Wicket (as well as Tapestry) that claims that designers and coders can work almost independently? --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Re: Previewing html only, including nested components html
Yes, that's simple and that works, indeed. Thanks for the idea. On 11/4/05, Martijn Dashorst [EMAIL PROTECTED] wrote: I use wicket:remove around relative paths to the CSS in the webapp directory. So this looks like: html head style type=text/css src=style/style.css / wicket:remove style type=text/css src=../../../../../../webapp/style/style.css / /wicket:remove The same can be done for JavaScript libraries that aren't part of a component. Martijn On 11/3/05, Juergen Donnerstag [EMAIL PROTECTED] wrote: I don't know how to correctly preview a markup html only when it refers to css, javascript files, that are meant to be relative to the webapp context. in order to be pre-viewable the html editor must be able to find the css file without the help of wicket. The easiest way to accomplish it is to put the css into your source path and by means of wicket:link (autolinks) wicket is able to find them at runtime. I think this should be done by viewing the html markup from a running instance of the webapp only ? And also, I'd like to have this preview include the markup of nested panels, Is it possible in development mode ? A html editor can not do it. The html editor does not know anything about wicket and panel. This should be great, because it is hard to decompose a page into logical parts without the hassle of maintaining in synch two tag bodies or two wicket:remove elements. ?!?! What is the question? Juergen --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- Living a wicket life... Martijn Dashorst - http://www.jroller.com/page/dashorst Wicket 1.1 is out: http://wicket.sourceforge.net/wicket-1.1 --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Re: Previewing html only, including nested components html
The problem at hand was : how to still have an html preview -before having all the logic implemented- for a complex page, when the page is technically separated into multiple parts/panels. But now I see this question has no answers, and that is normal, due to the fact that the real types of the panels composing my complex page are not embarqued in the page itself. Since the wiring of the panels to the page is not done in the html markup itself, there's no way out. And I can see it's due to the fact that it is the components that drive their markups, and not the contrary, and that's great : much more power. Oh wait! Maybe I just ended to understand what is said in the Features page, when one writes about the difference between the Wicket JSF philosophy ? On 11/4/05, Eduardo Rocha [EMAIL PROTECTED] wrote: The fact that one cannot preview html only using panels without running a web server means that java code it is mandatory. Do you think this is a drawback to Wicket (as well as Tapestry) that claims that designers and coders can work almost independently? 2005/11/3, Laurent PETIT [EMAIL PROTECTED]: On 11/3/05, Juergen Donnerstag [EMAIL PROTECTED] wrote: in order to be pre-viewable the html editor must be able to find the css file without the help of wicket. The easiest way to accomplish it is to put the css into your source path and by means of wicket:link (autolinks) wicket is able to find them at runtime. Ok, I understand that. But this does not solve the second issue, as you stated: And also, I'd like to have this preview include the markup of nested panels, Is it possible in development mode ? A html editor can not do it. The html editor does not know anything about wicket and panel. Oh sorry, I just re-thought about it, and I clearly understand it cannot work. This should be great, because it is hard to decompose a page into logical parts without the hassle of maintaining in synch two tag bodies or two wicket:remove elements. ?!?! What is the question? No more questions, since I had the evidence that what I was thinking of isn't at all possible (since, of course, the associated panel markup is bound to the class of the panel, and in the parent markup, there is nothing special but a wicket:id attribute, which isn't sufficient to deduce the right nested markup file ...) Sorry for this one, -- Laurent --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Re: Previewing html only, including nested components html
On 11/4/05, Nathan Hamblen [EMAIL PROTECTED] wrote: But anyway, you can preview a component (in isolation) just fine in the component template without a web server. You can also preview the fake version in the page template without a server, though it's easy for that to get out of synch with the real thing. Yes, that was that problem of how to still have both of the two worlds : how to keep the fake version markup embarqued in the parent page, and the real component markup in synch. I now think this can at most be done depending on the features of the designers tools. --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] wicket:link always throws me an class not found exception
Is the class in the same package? -Igor On 11/4/05, Manuel Corrales [EMAIL PROTECTED] wrote: I have a link like this on a page, but it keeps telling me that Bienvenido class does not exists. pwicket:linka href=""> The class Bienvenido exists and the page too (in fact, it was the page i came from) should i implement something special on this class or in the html?? Thanks.
[Wicket-user] wicket:link always throws me an class not found exception
I have a link like this on a page, but it keeps telling me that Bienvenido class does not exists. pwicket:linka href=""> The class Bienvenido exists and the page too (in fact, it was the page i came from) should i implement something special on this class or in the html?? Thanks.
Re: [Wicket-user] Help understanding component creation
To quote from the discussion (not the exact wording, but the basic idea): First we introduce markup parameters (which then need to be parsed, could become any OGNL expression), then we want conditional markup, loops in your markup, and finally we end up with Wicket Server Pages: JSP in another language. Having the expressions in one place and one place only is one of Wickets strengths: it is clear, simple and sensible. Martijn On 11/4/05, Eelco Hillenius [EMAIL PROTECTED] wrote: Though there has been much debate about allowing such markupdriven configuration (with me being in favor for allowing it to some extend), configuring components like that is not 'the Wicket way'. Rather, you would do any configuration in your code. Contrairy to most alternative frameworks, Wicket is largely unmanaged, hence you are in charge of component and initialization yourself. Thus, you would do: MyComponent c = new MyComponent(); c.setParam1(...) c.setXX(.. add(c); To get a better idea, please take a look at Wicket's examples. Eelco On 11/3/05, David Leangen [EMAIL PROTECTED] wrote: Hello! I have read the doc and looked at the examples, but there are still a few things that I don't get. Probably, I have the Tapestry approach stuck too much in my head... How do I write a component that takes parameters? This is an example of what I'd like to do: span wicket:id=myComponent param1=someValue param2=ognl:com.package.SomeClass/ public class MyPanel extends Panel { private String m_param1; private SomeClass m_someClass; public MyPanel( final String id ) { super( id ); } public void setParam1( final String param1 ) { m_param1 = param1; } public String getParam1() { return m_param1; } public void setSomeClass( final SomeClass someClass ) { m_someClass = someClass; } public SomeClass getSomeClass() { return m_someClass; } } Thanks for any advice you can give! --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- Living a wicket life... Martijn Dashorst - http://www.jroller.com/page/dashorst Wicket 1.1 is out: http://wicket.sourceforge.net/wicket-1.1 --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Help understanding component creation
I know the danger. I agree with the danger, and I agree with /not/ implementing it when other people are against. It is just that /I/ think it is powerful to be able to create high level components that you can add with a single line in your java code, and then configure the rest in your markup. And that would be the basis of combining it with wicket:component, so that you put such components in your markup anywhere you like to circumvent one of the drawbacks of Wicket, namely that you have to keep your component nesting and markup nesting in sync. Again, potentially dangerous, but a powerful tool for the users that can handle it. We're not especially targetting rooky programmers with Wicket too. Eelco On 11/3/05, Martijn Dashorst [EMAIL PROTECTED] wrote: To quote from the discussion (not the exact wording, but the basic idea): First we introduce markup parameters (which then need to be parsed, could become any OGNL expression), then we want conditional markup, loops in your markup, and finally we end up with Wicket Server Pages: JSP in another language. Having the expressions in one place and one place only is one of Wickets strengths: it is clear, simple and sensible. Martijn On 11/4/05, Eelco Hillenius [EMAIL PROTECTED] wrote: Though there has been much debate about allowing such markupdriven configuration (with me being in favor for allowing it to some extend), configuring components like that is not 'the Wicket way'. Rather, you would do any configuration in your code. Contrairy to most alternative frameworks, Wicket is largely unmanaged, hence you are in charge of component and initialization yourself. Thus, you would do: MyComponent c = new MyComponent(); c.setParam1(...) c.setXX(.. add(c); To get a better idea, please take a look at Wicket's examples. Eelco On 11/3/05, David Leangen [EMAIL PROTECTED] wrote: Hello! I have read the doc and looked at the examples, but there are still a few things that I don't get. Probably, I have the Tapestry approach stuck too much in my head... How do I write a component that takes parameters? This is an example of what I'd like to do: span wicket:id=myComponent param1=someValue param2=ognl:com.package.SomeClass/ public class MyPanel extends Panel { private String m_param1; private SomeClass m_someClass; public MyPanel( final String id ) { super( id ); } public void setParam1( final String param1 ) { m_param1 = param1; } public String getParam1() { return m_param1; } public void setSomeClass( final SomeClass someClass ) { m_someClass = someClass; } public SomeClass getSomeClass() { return m_someClass; } } Thanks for any advice you can give! --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- Living a wicket life... Martijn Dashorst - http://www.jroller.com/page/dashorst Wicket 1.1 is out: http://wicket.sourceforge.net/wicket-1.1 --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net
Re: Re: [Wicket-user] Re: Wicket 1.1 line endings bug?
And a very good one at that :) Envy isn't that one of the seven deadly sins? Martijn On 11/4/05, David Leangen [EMAIL PROTECTED] wrote: Sounds to me like envy. Admit it, you all wish you had a Mac and are jealous of those of us who do! (My one and only useful(??) contribution to this list...) On Thu, 2005-11-03 at 09:04 -0800, Igor Vaynberg wrote: TORCH IT...FIRE FIRE! -Igor On 11/3/05, Adam Chesney [EMAIL PROTECTED] wrote: +1 also. I think that settles it... Martijn... if you would be so kind as to destroy your Mac immediatly and post some photos to the list to prove that you have done so. A sledgehammer ought to suffice. Thanks, Adam. - Original Message - From: Igor Vaynberg To: wicket-user@lists.sourceforge.net Sent: Thursday, November 03, 2005 4:15 PM Subject: [Norton AntiSpam] Re: [Wicket-user] Re: Wicket 1.1 line endings bug? +1 on stopping the use of the mac :) -Igor On 11/3/05, Johan Compagner [EMAIL PROTECTED] wrote: You should just stop using youre mac yes. That would be make everything much better :) On 11/3/05, Martijn Dashorst [EMAIL PROTECTED] wrote: I don't change the line endings, CVS does that for me. So basically you are suggesting I should stop using my mac ;-). Long live the differences between Mac, Linux and Dos... CR/LF/CRLF. Just curious, why don't you use CVS diff's? Check out Wicket 1.1 from CVS, and compare it to another version. I know most IDE's support that. Martijn On 11/3/05, jan_bar [EMAIL PROTECTED] wrote: Filled as #1347101. Thanks for your work on Wicket. It would be nice if you don't change line endings in Wicket sources (this is not related to the reported bug) between releases of Wicket. When I use source comparing just to see differences between versions, all files differ. Thanks, Jan Martijn Dashorst [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I don't know... It could be that because the 1.1 build was done on my Mac, and the RC builds were done on my MS laptop. Can you file a bug report, with a more precise description on what you think is wrong? Martijn On 11/3/05, jan_bar [EMAIL PROTECTED] wrote: Hi, I compared results of rendered page from Wicket 1.1-rc2 and final 1.1. In one page the 1.1 version mixes unix and microsoft line endings (it worked well with 1.1-rc). Is this know bug? Jan --- SF.Net email is sponsored by: Tame
Re: [Wicket-user] Wicket 1.1 line endings bug?
Anyhow, now I'm confused. Should I make the next (1.1.x) release with my Mac or with my laptop? Doing it on my mac gives you consistent results comparing with 1.1. Doing it on my laptop gives you PC line endings. Martijn On 11/3/05, jan_bar [EMAIL PROTECTED] wrote: Hi, I compared results of rendered page from Wicket 1.1-rc2 and final 1.1. In one page the 1.1 version mixes unix and microsoft line endings (it worked well with 1.1-rc). Is this know bug? Jan --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user -- Living a wicket life... Martijn Dashorst - http://www.jroller.com/page/dashorst Wicket 1.1 is out: http://wicket.sourceforge.net/wicket-1.1 --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
[Wicket-user] The Wicktor Situation (AJAX DropDownChoice)
Hi, for porting an existing web application to Wicket I needed to refresh the contents of DropDownChoice without a new request (for speedy selection). As this is a common technique for selecting categories (things like Computer - Hardware - RAM - DDR or Branch / Company / Person) I decided to create a reusable Wicket component exactly for this. And as having Wicket saved my a lot of time the last weeks I thought I should contribute that back. Well, here are the facts: - I did a component called WicktorDropDownChoice. It's exactly the same as Wickets original DropDownChoice except for a little method called connectListForAjaxRefresh(WicktorDropDownChoice choice). Every list that is connected somehow this way gets reloaded automatically using JavaScript / AJAX at runtime - It works for the current version of IE, Firefox and Safari but it doesn't have a non-JavaScript fallback. So if you want to use it for a public web application some work is still needed - You can download it from http://www.dreivier.net/wicktor.zip , it includes the component sources and a simple example page - Little extra: WicktorCheckBox and HideableWebMarkupContainer. You can connect the HideableWebMarkupContainer to the WicktorCheckBox and the container gets shown/hidden by state state of the checkbox at the client side. Warning: these two work, but I'm not very proud about the way they work. I have the feeling this could be done in a more elegant way... Any ideas? - Yes, I'm sorry for the stupid name. Wicktor is my wicket-test project for playing around with wicket. - Any feedback/ideas is highly appreciated. Good night :) Regards, Ralf Ebert --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Adding Support for optgroup
Yes my bad, I meant the label attribute, I got it confused with the label tag's for attribute. I'm not sure what the best solution is either. Passing a string in definitely works, but it's not really consistent with the rest of the Wicket components (except Label which just takes the string and creates a new model with it). Nevertheless, I use i18n in my app and I use the getString(...) method all over the place, so passing in a String is, IMHO, not a bad thing. Ok, what if we made OptGroup a component just like DropDownChoice, as you mentioned. Then couldn't we just do a test in the DropDownChoice/MultiChoice constructors to see if the list/model contains OptGroups? The only problem is what does the ChoiceRenderer passed into the DropDownChoice refer to at that point? How to display the optgroup or display the options? Should optgroup take in a ChoiceRenderer? --AndrewOn 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote: unless of course we just pass in a string instead of imodel and leave i18n to the user... -Igor On 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote: you mean for the label attribute? Optgroup in this case wouldnt be a component so the IModel provided needs to be attached to some component so that it is detached properly, so the user needs to worry about attaching it somewhere, and the more optgroups you have the trickier that gets. -Igor On 11/4/05, Andrew Berman [EMAIL PROTECTED] wrote: Igor, why wouldn't the model be attached to the OptGroup object? Each OptGroup takes a model which is used for the for attribute.On 11/4/05, Johan Compagner [EMAIL PROTECTED] wrote: For the other choice objects (The singleselectchoice, dropdownchoice) we could have a list of optgroups and the optgroup has a list of its choices So you are just makeing one line with choices and optgroups (with again a list of choices) johan On 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote: havent decided what the best way to do this is. one problem i see with passing a list of optgroups is that the optgroup will have to have an IModel for its label in case someone wants to i18n it, but then how do we handle attaching and detaching that model since its not attached to any component. maybe separate components like check and checkbox are the best way, and have an optgroup that works exactly like dropdown choice to simplify things. still thinking, thoughts? -Igor On 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote: yeah sorry, think of it as pseudo html :) -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: It would be similar to Check/CheckGroup because you could create a Select object, which is like the CheckGroup object, and an Option object, which is similar to the Check object. By doing that, then I can manually insert the optgroup tag either directly in the HTML or using a WebMarkupContainer in the JavaCode if the label needs to be dynamic. However, your thought about having an OptGroup object and extending the current DropDownChoice (and it makes sense to do the ListMultipleChoice too as you can use OptGroup with a select box that allows multiple choices) intrigues me. Maybe that is the smoothest way to go because it will reuse what's already available and would only add the one OptGroup component. I like it. By the way, your html should look like below, your HTML above is not correct:select wicket:id=selectGroup optgroup label=Label 1 option/option option/option /optgroup optgroup label=Label 2 option/option option/option /optgroup/select--AndrewOn 11/3/05, Igor Vaynberg [EMAIL PROTECTED] wrote:I dont really understant what you mean. If you want to do it like the Check/CheckGroup is done you would have a SelectGroup and Select components that you would put into your html and then you can manually insert optgroup ie select wicket:id=selectGroup optgroupwicket doesnt care/optgroup select wicked:id=choice1 select wicket:id=choice2 /optgroup /select But then you are talking about making it a single component, so that is not like the Check/CheckGroup work. If i was going to build it as a single component I would use the embedded objects like you mentioned, not a map. Ie class OptGroup { List choices; IModel title; } and my component would take a list of optgroups. OR maybe something smoother would be to do extend the current DropDownChoice to do an instanceof check on the item its rendering and if its an OptGroup object write out the OptGroup. Thoughts? -Igor On 11/3/05, Andrew Berman [EMAIL PROTECTED] wrote: I'm sure this is Igor's territory, but I was wondering if, like how Check/CheckGroup and Radio/RadioGroup was done, if we could also add something to permit optgroups. My thought was to have something like a Select object which takes a list of OptGroup components. The OptGroup component then takes a list of SelectOption components. The other way I was thinking about it was to add a constructor to DropDownChoice and ListMultipleChoice which takes a Map. Then each Map key could be the
Re: [Wicket-user] wicket:link always throws me an class not found exception
Yes, the class is on the same package. As soon as i can i post some code and the error description. Any other idea of what can be?? I've tried the examples and work perfect. Have no clue. Thanks.On 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote:Is the class in the same package? -Igor On 11/4/05, Manuel Corrales [EMAIL PROTECTED] wrote: I have a link like this on a page, but it keeps telling me that Bienvenido class does not exists. pwicket:linka href=""> The class Bienvenido exists and the page too (in fact, it was the page i came from) should i implement something special on this class or in the html?? Thanks.
Re: [Wicket-user] wicket:link always throws me an class not found exception
May we have the stack trace and may be the (stripped down) sources as well. Thanks Juergen On 11/5/05, Manuel Corrales [EMAIL PROTECTED] wrote: Yes, the class is on the same package. As soon as i can i post some code and the error description. Any other idea of what can be?? I've tried the examples and work perfect. Have no clue. Thanks. On 11/4/05, Igor Vaynberg [EMAIL PROTECTED] wrote: Is the class in the same package? -Igor On 11/4/05, Manuel Corrales [EMAIL PROTECTED] wrote: I have a link like this on a page, but it keeps telling me that Bienvenido class does not exists. pwicket:linka href=Bienvenido.htmlVolver/a/wicket:link/p The class Bienvenido exists and the page too (in fact, it was the page i came from) should i implement something special on this class or in the html?? Thanks. --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user