Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!sdd.hp.com!elroy.jpl.nasa.gov!decwrl!adobe!hawley From: hawley@adobe.COM (Steve Hawley) Newsgroups: comp.sys.mac.programmer Subject: Re: Icons in popup menus (like Std. File dialog)? Keywords: icons, popup menus Message-ID: <11707@adobe.UUCP> Date: 27 Feb 91 17:01:31 GMT References: <62972@bbn.BBN.COM> Reply-To: hawley@adobe.UUCP (Steve Hawley) Distribution: comp Organization: Adobe Systems Incorporated, Mountain View Lines: 45 In article <62972@bbn.BBN.COM> rmitchel@bbn.com (Rob Mitchell) writes: | [1] How does the "mini" icon get inserted into the popup menu | in the standard file dialog window? You know, the one | that looks like folder/files/appls/etc. I'd like to | insert an icon in my popup menu. Where do I get the | "mini" icon? From some "ICN#" rsrc? Do I append it to | menu item just before drawing (kinda like check marks)? Can't answer this exactly, but you get the small icon from the SICN resources in the system file (or your own file or wherever). To get them in a pop-up menu is something I've never tried. I image you'd have to write your own MDEF to handle that... | [2] I need to create a one-column, many-row list (using | List Mgr) but would like to have vertical lines to | "act" as column seperators. I know it sounds a little | strange, but ... Basically, each row displays a few | fields of a data structure and the user can double-click | on a row (the whole row needs to highlight) to bring | up dialog box to change entry's values. This isn't too hard. What you have to do is write an LDEF (a list definition function) for use in your application. Inside Macintosh Volume IV is pretty clear about how this is done. I wrote one in a day that interpretted embedded text formatting codes to dynamically change text styles within the text of a cell. You may wish to reconsider popping up a dialog box *every* time a user double clicks on a cell. If the dialog box presents no more information than is present in the list itself, all the time spent waiting for the dialog box to pop up and redraw and for the window to refresh when the dialog goes away will add up. Consider instead adding some Text Edit fields that get filled in when the user double clicks on a cell and will be used to replace the currently selected cell upon pressing a button (or a key equivalent). Another approach would be to pop up the Text Edit fields OVER the each field of the selected Cell itself (disable the list first), then make it go away upon confirm or cancel commands (again via buttons and key equivalents). Steve Hawley hawley@adobe.com -- "Did you know that a cow was *MURDERED* to make that jacket?" "Yes. I didn't think there were any witnesses, so I guess I'll have to kill you too." -Jake Johansen