Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

palettes: Mathematica input

2 views
Skip to first unread message

alexxx...@gmail.com

unread,
Jun 30, 2009, 6:38:02 AM6/30/09
to
Trying to write a palette, I found very tiring to rewrite some very
common patterns, e.g. I'd like my custom palette to contain also all
the lower/uppercase greek letters.
There is some quick way to have the Mathematica input used to
generate an already-existing palette?
E.g. I have all the letters ready in the palette "Basic Typesetting",
and I thought that right-click -> "Generate Notebook" was what I
wanted, but it simply copies the palette in a notebook, while I need
all the lines "ButtonBox["..."] // DisplayForm;" ....


alessandro


Bob F

unread,
Jul 1, 2009, 6:32:33 AM7/1/09
to
On Jun 30, 4:38 am, "alexxx.ma...@gmail.com" <alexxx.ma...@gmail.com>
wrote:

Try putting //InputForm after the palette you just created from the
right-click "Generate Notebook" -- and you get all the code that it
takes to generate the palette. But for some reason when you re-execute
this code you don't get back as good a looking palette as what the
original was - can someone explain why that is?

-Bob

Pillsy

unread,
Jul 1, 2009, 6:32:01 AM7/1/09
to
On Jun 30, 6:38 am, "alexxx.ma...@gmail.com" <alexxx.ma...@gmail.com>
wrote:
[...]

> E.g. I have all the letters ready in the palette "Basic Typesetting",
> and I thought that right-click -> "Generate Notebook" was what I
> wanted, but it simply copies the palette in a notebook, while I need
> all the lines "ButtonBox["..."] // DisplayForm;" ....

NotebookGet[] will get you what you're asking for, but this is so easy
to do with a Mathematica command I'm not sure I'd recommend that. For
instance, a palette for pasting in lowercase Greek letters:

CreatePalette[Grid[Partition[
(PasteButton[ToExpression[#1, StandardForm, Defer]] & ) /@
CharacterRange["\[Alpha]", "\[Omega]"], 4]]]

Cheers,
Pillsy

alexxx...@gmail.com

unread,
Jul 2, 2009, 7:14:31 AM7/2/09
to

thank you everybody,
that's what I needed!

alessandro

0 new messages