Timo Schmidt wrote:
> On Wed 26.06.2013 07:30, Richard W. Adams wrote:
>>
>> We have a customer requirement that disabled form buttons be grayed out 
>> rather than Wicket's default behavior of making them invisible.
> 
> In my experience, disabled form elements are rendered with the disabled
> attribute. They are not invisible.

And the rest of the thread tracks the problem that that's not the
case with your example.

But I'd like to add information about "graying out":

>> Google has a lot of discussion on the topic, but I didn't see
>> a "best practice" solution. Does Wicket provide a way to gray
>> out buttons (or any form control, for that matter)?
>>
>> If we have to override something like onRender(),
>> onBeforeRender(), etc. where would be the best place to do
>> this?
> 
> By using CSS yoy may style disabled elements as you like:
> 
> button[disabled], input[disabled], select[disabled], textarea[disabled] {
>    ...
> }

If you've got CSS predefined and can't change it, there's the
callback method onDisable(ComponentTag) on your form components
that can be overriden to change CSS class of the emittet markup.

        Joachim

-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Joachim Schrod, Roedermark, Germany
Email: jsch...@acm.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to