Re: SelectedNotebook[ ] under Mac OSX gives wrong answer
- To: mathgroup at smc.vnet.net
- Subject: [mg41444] Re: [mg41427] SelectedNotebook[ ] under Mac OSX gives wrong answer
- From: John Fultz <jfultz at wolfram.com>
- Date: Tue, 20 May 2003 03:23:44 -0400 (EDT)
- Reply-to: jfultz at wolfram.com
- Sender: owner-wri-mathgroup at wolfram.com
My guess is that you probably want to use InputNotebook[] instead of SelectedNotebook[]. On other operating systems, it is possible to select a notebook which will not take keyboard input; palettes would be the most common case of this. This is useful for targeting the option inspector and using the Generate Notebook From Palette command, but all other commands and keystrokes go to the InputNotebook[] (i.e. the notebook currently accepting keyboard input), not the SelectedNotebook[] (on a side note, this seems terribly inconvenient for palette developers, and it is, but the idea is to make life easy for users of palettes, not developers of palettes). Because MacOS X has special rules about how palette windows work and doesn't allow you to "select" palettes in the same way other OS"s do, a problem occurs in figuring out how to compute SelectedNotebook[]. We're trying to figure out what to do; if you really needed to be able to manipulate palettes as well as regular notebooks, I'm afraid you'll have to find some means other than SelectedNotebook[] to do it. Sincerely, John Fultz jfultz at wolfram.com User Interface Group Wolfram Research, Inc. On Mon, 19 May 2003 05:10:39 -0400 (EDT), Michael Mazilu wrote: >I am using Mathematica 4.2 on Mac OSX 10.2.6 and I have the following >problem. When having a palette open and running SelectedNotebook[ ] in a >normal notebook in gives the palette's name as an output instead of the >notebooks name. > >Hope there is solution to this problem. > >Thanks, > >Michael