Dear LyX Developers and Users,
> I'm trying to create custom insets and environments for the document class
> features. One environment that has me stumped though, is how to create an
> inset for the memoir "sidecaption" feature.
>
> The sidecaption environment allows you to typeset the caption of your figure
> in the margin (similar to the way that the Tufte handout and book classes
> work), and the style guide for this class calls for their use. This is how an
> example in LaTeX would work.
So I need to RTFM a little more often. After a bit of head scratching, I've
been able to create a workable Side Caption style. You simply place it inside
of the figure or table float and then use the Opt inset to add the caption.
Very smooth and easy to use, and I'm quite happy.
Here's the definition I used:
Style Side_Caption
Category Special_Commands
Margin Static
LatexType Environment
LatexName sidecaption
NextNoIndent 1
TopSep 0.5
ParSep 0.5
BottomSep 0.5
Align Block
AlignPossible Block, Left, Right, Center
LabelType No_Label
HTMLTag sidecaption
HTMLItem p
RequiredArgs 1
End
I've had a questions come up, though:
I'm not very happy telling a user to go to "Insert > Short Title" in order to
add a caption. This seems confusing, from a usability standpoint. I would
prefer to have a custom inset that they can add that says
"Custom:Side_Caption". Is there any way to create a custom "opt" inset? Even
after RTFMing, I was not able to find one.
Thoughts would be appreciated.
Cheers,
Rob