Re: How to make TextBox read only but look normal

new topic     » goto parent     » topic index » view thread      » older message » newer message
bernie said...
DerekParnell said...

The user must have a visual clue that the field is not editable. You cannot just stop accepting events in the field because the user will not know that the program has changed state. You really have to show the user that the field is a no-go area. This GUI 101.

The simpliest way is to use setEnable(..., 0) and have the background colour change from the normal input scheme. That is why I suggest that during the program's form creation step, it should call setDisableBg() to set which colour to show when it's been disabled. That is all that has to be done! No fancy footwork or behind ther scenes redirecting of events.

There are many ways you can give visual hints that the field is disabled, but this is by far the easiest. I also suggested that one can change the colour of the text itself, but you could change the font/border/whatever..., but you have to do something.

Any field that looks like an input field should be editable. If it's not editable then it should not look like an input field.

Derek: Couldn't they just setup a tooltip that would warn the user
when the users mouse hovers over the text box ?

A good application does not rely on using a mouse. The user could attempt to use the TAB key to get to the field. If the cursor gets there and they can't type anything, then that is bad. If they can't TAB there but the field looks like an input field, then that is also bad.

No, there must be a visual clue that one can see just by looking at the form.

Can I recommend a book called "About Face" by Alan Cooper.

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu