List Info

Thread: Re: Making fields read-only




Re: Making fields read-only
user name
2007-05-11 07:23:00
Jakob Lechner wrote:

> On Tue, 2007-05-08 at 19:13 +0200, Mathias Bauer
wrote:
>> Mathias Röllig wrote:
>> > Sure? Perhaps, if the field can be protected
against deletion. But IMHO
>> > is this also only senseful if protected areas
can be protected by
>> > protecting the document with password like a
calc document.
>> 
>> Well, after some thinking I meanwhile believe that
the few cases where a
>> read-only field could make sense can be implemented
differently. So I
>> stand corrected. 
> 
> In my case the content of the fields is provided by a
C++ addon. If
> certain values are displayed the user shall be allowed
to modify the
> field content, if some other values are displayed the
user shouldn't be
> allowed to change the content.

So in fact you have two field types mixed into one. It's
more like an
input field that is prefilled and sometimes shouldn't be
modifiable.

Perhaps you can implement it in this way: make it an input
field and in
case you don't want to have it editable replace it by
something that
isn't editable? Though all text fields that come to my mind
are editable
somehow (but at least not directly).

Ciao,
Mathias


-- 
Mathias Bauer (mba) - Project Lead OpenOffice.org Writer
OpenOffice.org Engineering at Sun: http://blogs.sun.com/Gu
llFOSS
Please don't reply to "nospamformbagmx.de".
I use it for the OOo lists and only rarely read other mails
sent to it.

------------------------------------------------------------
---------
To unsubscribe, e-mail: dev-unsubscribeapi.openoffice.org
For additional commands, e-mail: dev-helpapi.openoffice.org


[1]

about | contact  Other archives ( Real Estate discussion Medical topics )