Path: utzoo!attcan!uunet!lll-winken!elroy.jpl.nasa.gov!sdd.hp.com!zaphod.mps.ohio-state.edu!julius.cs.uiuc.edu!apple!agate!ucbvax!THUMPER.BELLCORE.COM!nsb From: nsb@THUMPER.BELLCORE.COM (Nathaniel Borenstein) Newsgroups: comp.soft-sys.andrew Subject: Re: problems with menulists Message-ID: Date: 19 Oct 90 16:08:39 GMT References: <9010191054.AA10459@lazy.qt.IPA.FhG.de> Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 27 Ah, I'm sorry, I should have read it more carefully. I think the real problem may be that you're chaining your menus together at the wrong point. The generally recommended way to do it is to chain them together in the PostMenus method. If you have a copy of my book on ATK, this is explained (at least in part -- it doesn't use the "bind" package) in Section 4.3 and 4.4, with an example piece of code. I'm not really sure how your code managed to get the menu to show up at all, nor am I sure why it core dumped when you selected it, but I'd recommend, as a first pass to fixing it, that you try moving your ChainAfter into a PostMenus method. If, however, as your message seems to indicate, you're not actually creating a new subclass of textview, then you've got a different problem -- obviously you don't have a PostMenus method to put this into! In that case, your best bet might be to use menulist_AddToML directly on the textview's menulist (i.e. to use menulist_AddToML(nextextView->menus, "New Menu Card,Insert Strings", proc, 0, 0) after first defining proc as an appopriate proctable entry. Obviously this is all non-standard, and since I haven't tried it I can't swear it will work, but it would probably be what I would try if I were you. Good luck, and don't hesitate to ask more questions if this wasn't enough... -- Nathaniel PS -- Actually, it's also possible to achieve some of these effects using the initfile mechanism, too, without any C programming at all. That might be worth looking into, too. -- NSB