Re: Re: Palette rememberance
- To: mathgroup at smc.vnet.net
- Subject: [mg45484] Re: [mg45454] Re: [mg45406] Palette rememberance
- From: Selwyn Hollis <sh2.7183 at misspelled.erthlink.net>
- Date: Sat, 10 Jan 2004 00:00:32 -0500 (EST)
- Sender: owner-wri-mathgroup at wolfram.com
Bruce, See the reply I got from John Fultz below. I think you could put something like what he describes in your init.m. Regards, ----- Selwyn Hollis http://www.math.armstrong.edu/faculty/hollis (edit reply-to to reply) Begin forwarded message: > From: John Fultz <jfultz at wolfram.com> To: mathgroup at smc.vnet.net > Date: January 8, 2004 12:50:53 PM EST > > Yes, you're correct. > > The AutoOpenPalettes option could be tweaked programmatically. If you > call > > SetOptions[$FrontEnd, AutoOpenPalettes->{...}] > > the results will automatically be saved in the FE preferences. So it's > simply a matter of a little kernel manipulation to mask in or out the > affected palette without affecting the others which are already in the > AutoOpenPalettes listing. E.g., to add a palette, you might do > something > like... > > Module[ > {palettes = AutoOpenPalettes /. Options[$FrontEnd, AutoOpenPalettes]}, > palettes = Union[Append[palettes, "MyPalette.nb"]]; > SetOptions[$FrontEnd, AutoOpenPalettes->palettes] > ] > > and to remove one, you might do... > > Module[ > {palettes = AutoOpenPalettes /. Options[$FrontEnd, AutoOpenPalettes]}, > palettes = Complement[palettes, {"MyPalette.nb"}]; > SetOptions[$FrontEnd, AutoOpenPalettes -> palettes] > ] > > Hope that helps. > > Sincerely, > > John Fultz > jfultz at wolfram.com > User Interface Group > Wolfram Research, Inc. > > > On Thu, 8 Jan 2004 09:06:21 -0500, Selwyn Hollis wrote: >> Thanks for pointing me in the right direction. Apparently the problem >> is that the palette in questioned is opened automatically when a >> package is loaded, and the value of AutoOpenPalettes is only changed >> when a palette is selected from the File > Palettes menus. Am I >> correct? If so, is there any way that a palette opened by other means >> can be remembered? >> >> Regards, >> >> ----- >> Selwyn Hollis >> http://www.math.armstrong.edu/faculty/hollis >> >> >> On Jan 8, 2004, at 1:17 AM, John Fultz wrote: >> >>> On Tue, 6 Jan 2004 04:17:12 -0500 (EST), Selwyn Hollis wrote: >>>> Should Mathematica remember ALL open palettes from one "session" to >>>> the >>>> next? Or does it remember only those in the primary path? I'm asking >>>> because one of my palettes that resides in an Addons/Applications/ >>>> ... >>>> /FrontEnd/Palettes directory has stopped appearing when I start up >>>> Mathematica. >>>> >>>> Please don't tell me I need to do the cache-clearing startup thing, >>>> because last time I did that, it took me hours to get everything >>>> back >>>> to normal. >>>> >>>> >>>> ----- >>>> Selwyn Hollis >>>> http://www.math.armstrong.edu/faculty/hollis >>>> (edit reply-to to reply) >>> >>> Mathematica uses the option AutoOpenPalettes to determine which >>> palettes >>> should open on startup. This option is updated whenever you open or >>> close >>> palettes which show up in the File->Palettes menu. So, if your >>> palette is >>> showing up there (based upon your description, I'd think it would >>> be), >>> then >>> it should work. >>> >>> Try evaluating... >>> >>> Options[$FrontEnd, AutoOpenPalettes] >>> >>> and see what gets returned, which may be enlightening. >>> >>> Sincerely, >>> >>> John Fultz >>> jfultz at wolfram.com >>> User Interface Group >>> Wolfram Research, Inc. > >