I want to create a figure caption cell style that prefixes a centred figure caption with Figure X, where X is an incremental number
I have seen two methods for automatically numbering figures:
Method 1: Use a CellDingbat to place the label in the left margin of the notebook
Cell[StyleData["FigureCaptionLeft"],
CellDingbat->Cell[
TextData[{"Figure ",
CounterBox["FigureCaptionNumbered"], "."}]],
TextAlignment->Left,
CounterIncrements->"FigureCaptionNumbered",
CellMargins->{{115,0},{0,0}},
MenuSortingValue->10000]
Method 2: Use CellFrameLabels to place the label above, below, left or right of the cell frame. Using this method I have not been able to obtain cell frame label and the caption on the same line.
Cell[StyleData["FigureCaptionCentred"],
CellMargins->{{65, 0}, {0, 0}},
CellHorizontalScrolling->True,
CellFrameLabels->{{None, None}, {None,
Cell[
TextData[{"FIGURE ",
CounterBox["FigureCaptionNumbered"], "."}]]}},
CellFrameLabelMargins->{{0, 0}, {0, 0}},
TextAlignment->Center,
CounterIncrements->"FigureCaptionNumbered"]
The image should illustrate the captions created from the described styles and my desired caption
Any ideas on how to create a style which prefixes centred text with a automatically generated number (with the number and text on the same line)?