Questions tagged [rules]

{rules} is about drawing lines (also called rules). Popular packages are {booktabs} (which provides high quality table rules) and {dashrule}.

Some relevant packages:

  • booktabs — Provides high quality table rules
  • dashrule — Provides dashed rules
907 questions
283
votes
6 answers

Horizontal line spanning the entire document in LaTeX

I have used the \hrulefill command to create a horizontal rule, along with some other commands. In each case I have the rules extended up to the margin. I want the rule width to be controllable, i.e. I want them to span the entire page. How can this…
assemblylearner
108
votes
1 answer

Draw a horizontal line in latex

How can I draw this horizontal line like this picture in Latex? Thanks for your help.
Duy
  • 1,465
38
votes
1 answer

What is the thickness of \hrulefill

This seems like a simple question ... I know from this question that \hrule and presumably \hrulefill have a thickness of 0.4pt. I think \hrule is a primitive, so does that mean that you cannot change the thickness of \hrulefill?
StrongBad
  • 20,495
18
votes
4 answers

Raise or lower \hrulefill

I am editing a questionnaire that uses \hrulefill as a text entry "field". I would like to lower the \hrulefill a bit to give participants more room to write. For a fixed-length rule I would use something like \rule[-3pt]{#1}{0.6pt}. Can I raise or…
severin
  • 539
15
votes
2 answers

How to draw horizontal line with rubber length?

The \hrulefill command could draw rubber length underlines, like abc___def. I just want to draw line in the vertical centre of a text, like abc---def. Thanks.
Yun Huang
  • 859
9
votes
2 answers

insert text into hrulefill

Is there a simple way to have text that looks like this? --- text --- where the --- fills a certain width? I've tried \centerline{\rule{2cm}{.4pt}text\rule{2cm}{.4pt}} but here if "text" is "text_1" in one case and "text_123" in another, then the…
hatmatrix
  • 2,913
  • 6
  • 31
  • 41
9
votes
3 answers

Horizontal line not working?

I am trying to add a horizontal line in my document. \documentclass{report} \begin{document} \begin{center} \Huge CV \end{center} \line(1,0){250} \end{document} For some reason, \line(1,0){250} will generate a line that is unequal on your…
Lemon
  • 3,153
8
votes
1 answer

vertical dotfill

How can I make vertical dotfill? In other words, I need vertical (dashed) line which will fill all available vertical space. (I tried to make it via rules, but not successfully.)
7
votes
2 answers

Why does a \hrule need text around it to be drawn?

Why does a \hrule need text around it to work? Example that does not draw a line: \documentclass{article} \begin{document} %foo \hrule %bar \end{document} If one removes the % before %foo or %bar (or both) the line is drawn perfectly fine.…
Foo Bar
  • 13,247
7
votes
1 answer

Signature line with dots and name below

In my LaTeX report I want to include a dotted signature line and my name below that line. As in the image. Can someone help me with the LaTeX code for that?
user54172
  • 113
6
votes
2 answers

Adjusting the height of \vline

Is there a way to adjust the height of \vline?
Aurelius
  • 7,653
  • 10
  • 49
  • 103
6
votes
2 answers

create a horizonal line having the length of the text

I would insert two horizontal line here an example: ------- Foo ------- I had used hrulefill but the line has the length of the page.
Mazzy
  • 7,642
6
votes
4 answers

Center text between double horizontal rules

I'd like to do something like this: ==================== Text ==================== Where '===' represents two horizontal lines separated by 2pt. In other words, I'd like to center some text between double horizontal lines. I have found a…
6
votes
2 answers

escape underscores

I have to write a format using undescores like this But when I put antislash before every one to escape it, it doesn't look nice, the underscores looks seperated Is there a solution to escape the hole word
Hind Dev
  • 641
6
votes
1 answer

\hrulefill with customized rule

I created a new command to generate doubled rules. How can I use or create a new command similar to \hrulefill in order to force my doubled rules to fill the rest of the line. So far I have tried this but to no avail. \documentclass{article} %…
Maxence
  • 63
1
2 3 4 5