discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: TextFieldCell, editWithFrame:inView:editor:delegate:self


From: Yen-Ju Chen
Subject: Re: TextFieldCell, editWithFrame:inView:editor:delegate:self
Date: Fri, 29 Aug 2003 10:52:11 -0400


 Toolbox support in-place editing in NSBrowser,
 and I forgot where I got it from, probably from GWorkspace.
If you are interested, you can check the source code (http://savannah.gnu.org/cgi-bin/viewcvs/toolbox/toolbox/),
 and ExtendedBrowser and ExtendedMatrix are all it need.

 Hope it help.

 Yen-Ju

From: Björn Giesler <giesler@ira.uka.de>
To: discuss-gnustep@gnu.org
Subject: TextFieldCell, editWithFrame:inView:editor:delegate:self
Date: Fri, 29 Aug 2003 14:00:59 +0100

Hi,

can anybody explain to me something in the text system that I don't understand?

I'm building a NSView subclass that is supposed to show address information on a person. Since the layout is greatly variable, I keep the information in NSTextFieldCells and do the layout in the view's drawRect: method (see http://giesler.biz/bjoern/Downloads/Contax/Contax-pre.jpg for a screenshot).

Now, when somebody clicks on a textfield cell, I want to start editing the cell, so I send it

[c editWithFrame: rect
     inView: aView
     editor: textView
     delegate: self
     event: event];

What I don't understand is: What exactly is aView supposed to be? Whatever it is, it gets resized to rect, so it can't be self. I've tried constructing a special view class, setting it to be a subview of self and using that as aView, which kind of works, but the cursor is not shown and the view is not updated while editing.

I guess I wouldn't be quite so clueless if I understood the purpose of this third view; it seems superfluous to me, since there's already a view involved (textView).

Please, can anyone clarify this?

Thanks a lot in advance,
                --Björn



_______________________________________________
Discuss-gnustep mailing list
Discuss-gnustep@gnu.org
http://mail.gnu.org/mailman/listinfo/discuss-gnustep

_________________________________________________________________
Get MSN 8 and enjoy automatic e-mail virus protection. http://join.msn.com/?page=features/virus





reply via email to

[Prev in Thread] Current Thread [Next in Thread]