General ⇒ special toprule and bottom rule of table
special toprule and bottom rule of table
I need to have a table of the following shape:
Description
toprule
contents
bottomrule
where Description is left-aligned
toprule is a horzontal line with ends having angled-corners opposite to the ones in bottomrule
bottomrule is a horizontal line looks like (|_______________|) but connected (no spaces).
it is something like in the attached file. In fact I am not sure is it "box" or a "table".
thanks for help!
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
- localghost
- Site Moderator
- Posts: 9202
- Joined: Fri Feb 02, 2007 12:06 pm
special toprule and bottom rule of table
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
special toprule and bottom rule of table
localghost wrote: Maybe the arydshln package could be helpful.
thanx for the tip localghost. I was not aware of arydshln (good to know:-)). However, it does not help unless I do some workarounds like introducing table inside another..
Sami
special toprule and bottom rule of table
Code: Select all
\par\noindent{\rule[-5pt]{0.4pt}{5pt}\leaders\hrule\hfill\rule[-5pt]{0.4pt}{5pt}}\newline
The contents
\vspace*{-5pt}\par\noindent\textcolor{inputcol}{\rule{0.4pt}{5pt}\leaders\hrule\hfill\rule{0.4pt}{5pt}} \newline
any help?
special toprule and bottom rule of table
Code: Select all
\documentclass[12pt,letterpaper]{report}
\begin{document}
\newcommand{\mytoprule}[1]{#1\vspace*{-12pt}\par\noindent{\rule[-5pt]{0.4pt}{5pt}\leaders\hrule\hfill\rule[-5pt]{0.4pt}{5pt}}\newline}
\newcommand{\mybottomrule}{\vspace*{-1pt}\par\noindent{\rule{0.4pt}{5pt}\leaders\hrule\hfill\rule{0.4pt}{5pt}}\newline}
\mytoprule{{\flushleft S{\footnotesize YNTAX}E{\footnotesize XTENSION}}}
\begin{tabular}{ll}
$F\ ::=\ /\ |\ *\ |\ f $ & \textit{Field Pattern} \\
\end{tabular}
\mybottomrule
\end{document}
Sami