Specifically I want different versions of 'Item1Numbered'. For example one with a frame and another with a background colour. How is that done?


1 Answer 1


You need to add StyleDefinitions -> StyleData["ParentStyle"] as an option to the StyleData of your new style (in the stylesheet), where "ParentStyle" is whatever you want to inherit from.

In your case, go to Format > Edit Stylesheet and add the following styles:

    StyleData["MyItemStyle1", StyleDefinitions -> StyleData["ItemNumbered"]],
    CellFrame -> True

    StyleData["MyItemStyle2", StyleDefinitions -> StyleData["ItemNumbered"]],
    Background -> GrayLevel[0.8]

enter image description here

  • $\begingroup$ Is there a way to make the frame cover the number and make the colour cover all of the inside of the frame and not just the number and the text? $\endgroup$
    – Sofic
    Aug 7, 2013 at 20:26
  • $\begingroup$ @Sofic Not directly, but it is possible with some fiddling with the CellDingbat. The default definition for number is CellDingbat->Cell[ TextData[{ CounterBox["ItemNumbered"], "."}], FontWeight -> "Bold"], which is inherited from ItemNumbered. Now if you add CellFrame -> True also to the Cell used in CellDingbat, you will get a frame around the number. However, the two frames now overlap. To resolve this, you'll have to manually fiddle with the CellMargins (the left margin for the main cell and the right margin for the dingbat cell) to get a good appearance. $\endgroup$
    – rm -rf
    Aug 7, 2013 at 20:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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