Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm looking to get a delimiter at an exact and user specified (point) size, rather than the default "a discrete size big enough to hold the contents" of \left( etc.

Is this possible? I've tried futzing around with the definitions of \big*,

\newlength{\vbraceheight}
\setlength{\vbraceheight}{50pt}
\def\vbig#1{{\hbox{$\left#1\vbox to\vbraceheight{}\right.\n@space$}}}
\def\vbigl{\mathopen\vbig}
\def\vbigr{\mathclose\vbig}

but these still have jumps as one varies \vbraceheight continuously (and I'm not really sure why).

share|improve this question
    
Does this answer help? –  Ian Thompson Aug 20 '12 at 16:04
    
@Ian, thanks, but is seems not -- as the final comment on the answer says: the size goes up in discrete jumps depending on the font size (I am not sure why this is the case) –  n00b Aug 20 '12 at 16:20
    
@n00b -- the reason for discrete jumps is that large braces are constructed from pieces, and the size of the extension pieces is a fixed vertical length. for a brace, two pieces are used, one in the top half and one in the bottom half. the glyph is located in font cmex10 at position hex 3E (octal 76). –  barbara beeton Aug 20 '12 at 18:35

2 Answers 2

up vote 7 down vote accepted

I would capture the contents of \vbig and resize vertically (keeping the aspect ratio) to \vbraceheight:

enter image description here

\documentclass{article}
\usepackage{graphicx}% http://ctan.org/pkg/graphicx
\makeatletter
\newlength{\vbraceheight}
\setlength{\vbraceheight}{50pt}
\def\vbig#1{{\resizebox{!}{\vbraceheight}{$\left#1\vbox to\vbraceheight{}\right.\n@space$}}}
\def\vbigl{\mathopen\vbig}
\def\vbigr{\mathclose\vbig}
\makeatother
\begin{document}
\[
  \setbox0=\hbox{$\displaystyle\vbigl\{\frac{1}{2}\vbigr\}$}\usebox0\ \mbox{has height \the\ht0}
\]
\end{document}
share|improve this answer

[Answer written by OP, moved from question]

Thanks for the comments and reply. I think I've got my head around why this is a difficult thing to do. I posted a similar question on comp.text.tex and received the following "manual construction" from Dan Luecking, I thought it worth sharing (I have made some minor spacing modification and include the code only for the left brace):

\DeclareMathSymbol{\bracetr}{\mathord}{largesymbols}{"38}
\DeclareMathSymbol{\bracetl}{\mathord}{largesymbols}{"39}
\DeclareMathSymbol{\bracebr}{\mathord}{largesymbols}{"3A}
\DeclareMathSymbol{\bracebl}{\mathord}{largesymbols}{"3B}
\makeatletter
\def\leftbracefill{%
  \setbox\z@\hbox{$\m@th\bracetr$}%
  \@tempdima=.5\wd\z@
  \advance\@tempdima-.6\p@
  \offinterlineskip
  \hbox{\kern-\@tempdima$\m@th\bracetr$}
  \leaders\hrule \@width 1.18\p@ \vfill
  \hbox{\kern-\@tempdima$\m@th\bracebl$}
  \kern-.5\p@
  \hbox{\kern-\@tempdima$\m@th\bracetl$}
  \leaders\hrule \@width 1.18\p@ \vfill
  \hbox{\kern-\@tempdima$\m@th\bracebr$}
}
\newcommand\leftbrace[1]{%
  \setbox\z@\hbox{$\m@th\bracetl$}%
  \@tempdima=.5\wd\z@
  \advance\@tempdima-.6\p@
  \vcenter{\m@th\everycr{}\tabskip\z@skip
    \hbox{\valign{##\crcr\noalign{\kern\@tempdima}
       \leftbracefill\crcr
       \hbox{$\m@th\displaystyle{#1}$}\crcr
    }}%
  }%
} 

This has the advantage that it does not depend on graphicx and one does not have the (admittedly small) discontinuities in the brace thickness which result from the \scalebox of Werner's solution. However, the above is much less flexible since it only uses one particular size of "brace piece" (so it only really works if the content is taller than 50pt), it depends completely on the computer modern fonts, and has artifacts in pdf viewers.

share|improve this answer

Your Answer

 
discard

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.