Questions tagged [lengths]

{lengths} is for questions dealing with measurements in TeX. If your question is about the spacing between document elements, use {spacing} instead.

Filter by
Sorted by
Tagged with
1
vote
1answer
32 views

Ifoddpage statement inside switch case

Continuation of topics tcolorbox: specific width and height settings for odd and even pages and Distance Variable in front or back pages. I'd like to set lengths conditionally based on the expansion ...
1
vote
1answer
112 views

How to make inductors larger?

I'm having a problem trying to make my cute inductors larger. I found a way of making them bigger with the /tikz/circuitikz/bipoles/length but that scales the entire inductor. I just want it to be ...
1
vote
1answer
58 views

Set length parameter based on KOMA \ifthispageodd

Background I'm using scrrept and titlesec (changing from titlesec to pure koma is on my todo list) any I've redefined \chapter to be a full page affair. The issue is when I'm using twosided. ...
1
vote
1answer
95 views

Width of minipage inside center environment

So I have three columns of content next to each other, using the minipage syntax, with the width specified in \textwidth, all of this placed in a center environment. Weirdly enough, if I make widths ...
1
vote
1answer
50 views

Problem with lengths

I'm trying to insert some space between the label and the form control in hyperref forms. The following example works: \documentclass{scrartcl} \usepackage{calc} \usepackage{hyperref} \newcommand\...
1
vote
1answer
82 views

Difference of lengths

This should be a very basic problem, but I can't find it anywhere: \documentclass[tikz,border=1pt]{standalone} \usepackage{fp} \usetikzlibrary{fixedpointarithmetic} \newlength{\radiustai} \...
1
vote
2answers
102 views

How to set a length to the min of two other lengths?

I have declared several lengths in my document: \bottomMargin \topMargin and \initialPaperHeight. Right now, I am doing this \AtEndDocument{% \global\paperheight\dimexpr\pagetotal + \bottomMargin + ...
1
vote
1answer
5k views

How to solve the Arithmetic overflow problem?

I was making an article and everything was going alright, when suddenly I got an error: The error: Arithmetic overflow. \calc@Acount l.78 ...qwe dqweqwrwf qewrfrQ aRF EFCas drfFR}{62} My article ...
1
vote
1answer
48 views

Problem with lengths and images

I'm trying a simple page with an image in the top of it as a header and an square image centered in the rest of the page. I would like the images to fill the full page width. After trying some ...
1
vote
1answer
35 views

Dynamic length name

I want to create something like in object, that saves it's own location in latex. Because I don't know how to create a objec in latex, I want to create a length with seperating name for each object. ...
1
vote
1answer
49 views

How to add an unit to a calculated value properly?

I have some trouble to understand how I ought to handle some values I calculated with fp to use them as length. It is obvious that I have to add an unit to the number to use it, but trying to do so, I ...
1
vote
1answer
972 views

Remove vertical space between two includegraphics, without random negative vspaces

everyone. I've lost hours on this dumb problem: if I write something like this \includegraphics{img}\\* \includegraphics{img} a noticeable vertical space appears between the two images when I'm ...
1
vote
2answers
293 views

\foreach and \StrLen

I don´t know how to make a foreach with a StrLen inside it, is it possible? \documentclass[a4paper,12pt,hidelinks]{article} \usepackage[utf8]{inputenc} \usepackage[brazil]{babel} \usepackage[T1]{...
1
vote
1answer
196 views

Is it possible to use mylatex or mylatexformat for documents with preambles almost the same?

I have documents of this form: \documentclass{article} \newlength{\variableLength} \setlength{\variableLength}{xxxx cm} \usepackage{package1} \usepackage{package2} \usepackage{package3} \...
1
vote
1answer
1k views

Calculating with different types of variables

Is there any way to calculate the height of a node in a tikz pictures and to divide a length by an another length to get a counter and to round it up? If yes where could i read after the subject of ...
1
vote
2answers
713 views

Table title to match table body (in terms of length)

I have a table with 4 columns and my title seems to be far bigger than the main body of the table. This does not look quite good. Is there anyway to have the length of those two be the same, or at ...
1
vote
1answer
285 views

How should I express my length calculation to minimize rounding errors?

I have an input file as follows. % Test.tex \documentclass{article} \usepackage{pstricks} \psset { linewidth=0.01 } \newcommand\All{0.1} \newcommand\Left{-\All} \newcommand\Right{\All} \newcommand\...
1
vote
0answers
39 views

calculate the title height and if the title height is above some number then add some space

calculate the title height and if the title height is above some number then add some space. when I use the code get the title, but when I use code like this \settoheight{\heightoftitle}{\vbox{\...
1
vote
0answers
46 views

showframe package exceeds few points in right side

My tags are follows: \documentclass{book} \usepackage{lipsum} \usepackage{showframe} \makeatletter \renewcommand\normalsize{% \@setfontsize\normalsize{10.9}{14}% \abovedisplayskip 7\p@ plus2\...
1
vote
1answer
103 views

Standalone build command does not capture all length

I am working with standalone sub-file in build mode. I would like to pass lengths from the main file to the sub-file. To do so, according to this answer , I put it in the command used by standalone to ...
1
vote
0answers
63 views

Adjust longtable length to caption length and vice versa

Is there any way to adjust the longtable length to the caption length and vice versa?
1
vote
0answers
130 views

Exact spacing between lines

Is there a way to get the exact spacing between different parts of a document? I know the question may sound a bit vague, so here's the context in which the question arose. Here there is a code ...
1
vote
0answers
70 views

How to find the length of a remaining line? [duplicate]

I'd like to put some lines on a page where a student can answer a question, and I'd like that line to go from the prompt to the right edge of the text. The most simpleminded and (therefore?) ...
1
vote
0answers
449 views

geometry's bindingoffset seems to be ignored

The geometry's documentation tells: page 9: "bindingoffset removes a specified space from the lefthand-side of the page for oneside or the inner-side for twoside.", page 10 (caption of Figure 6): "...
1
vote
1answer
255 views

Trim size as fundamental TeX value

What are the fundamental TeX length names, corresponding to trim size and offsets? I already know that \pdfpagewidth and \pdfpageheight will grab enough information to calculate the PDF MediaBox (in ...
1
vote
0answers
45 views

Maximum length of last line in paragraph [duplicate]

Is there a LaTeX parameter (e.g., a penalty parameter) or any complex solution that can be setup maximum length of the last line in the all paragraphs throughout the text? Let's say, 2 em horizontal ...
1
vote
0answers
147 views

What are skip values? [duplicate]

On page 5 of the titlesec manual (released on June 14, 2000), it is written that full skip values, including the plus and minus parameters can be abbreviated as * n. The example on page 24-25 (the ...
1
vote
2answers
68 views

Why is the width in nwu-lecture-style not working? [closed]

It seems that the code in nwu-lecture-style: \insertshortauthor[width=2cm-2pt,center,respectlinebreaks]\par% is not working? I tried: \insertshortauthor[width=2cm minus 2pt,center,respectlinebreaks]...
1
vote
0answers
29 views

Behavior of \global when used with xifthen package [duplicate]

I'm trying to calculate the sum of some numbers in my document. I want to allow non-integer values, so I'm using lengths, which works just fine. In my document it's often necessary to specify the ...
0
votes
2answers
31 views

rule length equal to length of item text paragraph

How can I get the width of the rule equal to the text for each item paragraph ? Any advice ? \documentclass[french,12pt]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{...
0
votes
1answer
53 views

negative character space (negative version of `\ `)

There is a negative thinspace \! which is a negative version of \,. Is there a negative version of normal character space \ too? I could not find it in: Lengths and when to use them, What commands ...
0
votes
1answer
32 views

Neat alignment of titlerule, text in tabular, and text in longtable

I'm having some trouble getting things to line up neatly. To be clear, I don't want everything to be the 'same length,' rather, I want it to fit aesthetically so that with multiple sections and ...
0
votes
2answers
230 views

Can't properly calculate column width

Please consider this MWE: \documentclass[11pt, a4paper]{article} \begin{document} \begin{table}[h] \begin{tabular}{|p{40mm}|p{100mm}|} Company & Head Quarters\\ \hline Foo Bar ...
0
votes
1answer
39 views

Cannot give length variable to crop package?

I don't understand why, but the following code fails with the error ! Missing \endcsname inserted. <to be read again> \myStock l.607 \AtBeginDocument {...
0
votes
3answers
41 views

Is there a way to update a length which has been computed from other lengths?

If I define a length by using others lengths, is there a way to update this length at a later point without giving the definition again? Let's say I define a few lengths as follows \newlength{\Test}\...
0
votes
2answers
189 views

Accuracy of distance measures in geometry

In the following MWE, I set the distance from the edge of the paper to the body text to be 25mm. \documentclass[a4paper]{article} \usepackage[showframe, paper = a4paper, tmargin = 25mm]{geometry} \...
0
votes
1answer
37 views

Is it possible to have a stretchable \parindent?

I thought that maybe some stretchability in the paragraph indentation may give TeX more freedom and help it at better typesetting some tough paragraphs. However, the following does not work. \...
0
votes
1answer
28 views

Format issues in longtable (left alignment of cells plus different cell lenght)

I got a longtable with rows containing more or less information. I want to achieve a left alignment because of justification errors plus different lengths in row size (horizontally). My current ...
0
votes
1answer
107 views

text justification/comments filling the space left from equation - flalign and paragraph mode

I have equations in a flalign environment and comments that may need to be multi-liner. \parbox seems fine except I can't tell it to automatically stretch in order to fill the space from the right-end ...
0
votes
1answer
152 views

\hrule length inconsistent

I'm using the tufte-book document class. When I use \hrule, sometimes it extends the text width (which I want), and other times it extends the full page width, apparently randomly. How can I get it ...
0
votes
1answer
58 views

Moving a TikZ drawn `mdframed` `frametitle` box vertically by a real amount?

Consider the following MWE: \documentclass{article} \usepackage[framemethod=TikZ]{mdframed} % noteboxes, boxes, etc. \usepackage{calc} \newcommand{\definebox}[2]{% \newcounter{#1} \...
0
votes
1answer
40 views

What is the rubber length of a float in the float package?

I try to place images with a fixed width from the section title. My question somehow is close to this one, though not covered in the response: How do I remove white space before or after the figures ...
0
votes
1answer
590 views

How to set \topsep=0pt on the latex standard list implementation inside an environment?

Two attempts which not worked Herein there are 2 examples which did not work. Each attempt has written over it % Not works: \PassOptionsToPackage{brazil,main=english}{babel} \documentclass[10pt,...
0
votes
1answer
101 views

Distances in TOC entry of section with mark

I try to customize TOC entry of section via redefining \l@section and defining \@section macros. My purpose was to add different mark (\sectiontitlemark) before section counter in main text as well ...
0
votes
1answer
82 views

How to parsing a length with skip/rubber/glue? [duplicate]

Others have asked about getting length as a number; the solutions there (using \strip@pt to remove the units, or using \number to convert to an integer number of sp units) work fine for a regular ...
0
votes
0answers
21 views

Measure the remainder of a page if it has a title and inserting that into a dynamic command

Okay, so I'm currently writing a report (in the article class) which has a section full of chemical spectra. I figured that two spectra per page is a good number, so I write \RequirePackage{calc} \...
0
votes
0answers
45 views

How to set white space under figure to specific figure?

I don't want to do this in the preamble to set it for all figures. I want to have this for one specific image / figure. Is this possible? If so, how can I do this? \setlength{\belowcaptionskip}{2ex} ...
0
votes
0answers
38 views

Evaluate combinations of page dimensions [duplicate]

For any given class and its specified page layout, I'd like to be able to combine (sum or subtract) a subset of the page dimensions, to obtain a length to work with, without specifying absolute values....
0
votes
0answers
382 views

How can I change the length of footnote line? [duplicate]

I need to change the length of the horizontal line that separates text body from footnotes. I want length of footnote line is as much as width of footnote text. I can the following codes: \def\...
0
votes
1answer
208 views

Text overflows into graphics at bottom of page

I want to include graphics on every page after the title page but on the 2nd page the text flows into the graphics and I also loose the page number on that page. Subsequent pages are fine. Here is my ...