Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Consider the following:

FirstOutput=Style["Test", FontSize -> 20]

SetOptions[Style, FontSize -> 20];

I would like the string "Test" to appear in SecondOutput as in FirstOutput. Why does SetOptions[Style, FontSize -> 20] not apply to SecondOutput?

Does anyone have an idea?

share|improve this question
up vote 4 down vote accepted

There are some functions that don't work with SetOptions. This Q&A provides a WRI tech support solution to finding functions that don't work with SetOptions but it appears that that method doesn't pick up Style (or StyleBox).

share|improve this answer

I think Mike Honeychurch has the gist of it. I don't know why Style doesn't use it's option values, but if you test it out, get display problems if you call

Style["test", Sequence @@ Options[Style]]

send the message:

The specified setting for the option OpenerBoxOptions, BaselinePosition cannot be used.

If you want something similar I suggest you simply define your own style call, which for the most case also nicely documents that you don't just want to call an empty Style[] on a piece of text, but want it to follow some personally defined styling.


I would personally expect Style["text"] to be the default style, which means that the call is redundant, since "text" in and of itself would have the default style.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.