I am writing a resume using the scrartcl,currvita, and classicthesis packages. Everything else is fine but I have run into a problem correctly justifying some dates along the right side of the page. When I use the command '\NewEntry', as defined below, it leaves a small white space of about 0.5em at the right side of the page, even though I have used /hfill. If I add the line manually instead of using a function, it does not do this, as shown in the picture. I have attached all of the code that I think is relevant. Can someone explain to me why it is doing this? Obviously I could just hand code it every time or correct it with /hspace(-0.5em) but I would much prefer to use a function.  \documentclass[11pt]{scrartcl} \reversemarginpar % Move the margin to the left of the page   \usepackage[nochapters]{classicthesis}  \usepackage[LabelsAligned, NoDate]{currvita} \usepackage{marginnote} \usepackage{color}  \usepackage[letterpaper,top=0.35in, bottom=0.15in, left=1.5in, right=0.5in,marginparwidth=1in,marginparsep=0.25in]{geometry}  \newcommand{\NewEntry}[2]{\raggedright\noindent\hangindent=2em\hangafter=0 \textsc{\bf#1}  {\hfill\small\textit{#2}}  % Define a command for each new block - change spacing and font sizes here \vspace{0.15em}} % Add some white space after each new entry  \begin{document}   \pdfpageheight 11in  \pdfpagewidth 8.5in  \thispagestyle{empty} % Stop the page count at the bottom of the first page  \begin{cv}{}  ---------------  \NewEntry{University of the Pacific}{Expected May 2016}  \raggedright\noindent\hangindent=2em\hangafter=0 \textsc{\bf University of the Pacific} \hfill {\small\textit{Expected May 2016}}  \end{cv}  \end{document}
64992
I found two things peculiar in the common style of macro definitions:   Ending lines in macro definitions with '%'; Not wrapping a macro name in braces.   Example:  \newcommand\examplemacro{%     \somecommand%     \othercommand% }   Being a software engineer first and a LaTeX user a distant second, I would expect:  \newcommand{\examplemacro}{     \somecommand{}     \othercommand{} }   Is there a reason for doing it the former way, or is it merely a matter of habit?
79301
Consider the following code example:  \setuppapersize[A8,landscape][A8,landscape] \starttext \startformula     \startalign         \NC 1 \NC= 1\NR         \NC 2 \NC= 1\NR         \NC 3 \NC= 1\NR         \NC 4 \NC= 1\NR         \NC 5 \NC= 1\NR         \NC 6 \NC= 1\NR         \NC 7 \NC= 1\NR         \NC 8 \NC= 1\NR     \stopalign \stopformula \stoptext   Coming from a LaTeX background I would expect align to break over pages and  tells me     Somewhere between March and Arpril, \startalign lost the ability to break equations across pages. Hopefully, it will be added back soon.   So basically it is intended to have page breaks, isn't it? Question: How to enable them for align?
33461
I have long recognized that any set of whitespace in an HTML file will only be displayed as a single space.  For instance, this:  &lt;p&gt;Hello.        Hello. Hello. Hello.                       Hello.&lt;/p&gt;   displays as:  Hello.        Hello. Hello. Hello.                       Hello.  This is perfectly fine, as if you need multiple spaces of pre-formatted text you can just use the &lt;pre&gt; tag.  But what is the reason?  More precisely, why is this in the specification for HTML?
19012
I have a problem with the lstlisting package. I want to define an \newenvironment with one obligatory parameter, which will be the caption name for the lstlisting. I will also have other lstlisting environments, that is why I am trying to define them separately.  I am also having some difficulties with \lstinline command (I set up a \newcommand to gain easier coding), which typesets keywords in normal text. Why can't it be in captions and similar?  I suppose something could be wrong with the preamble, that's why all the packages used are listed.  \documentclass{book} \usepackage[a4paper, top=3cm, bottom=3cm, heightrounded, outer=3cm, inner=3cm, marginparwidth=1.5cm, marginparsep=0.5cm]{geometry}  \usepackage{tocloft} \usepackage{amsmath}  \usepackage{eurosym} \usepackage{url} \usepackage{array} \usepackage{tabularx} \usepackage{multirow}  \usepackage{multicol}  \usepackage{graphics} \usepackage[dvips]{graphicx}  \usepackage{epstopdf}  \usepackage[dvipsnames]{xcolor}  \usepackage{verbatim} \usepackage{fancyvrb}  \usepackage{fancyhdr} \usepackage{paralist}  \usepackage{listings}  \usepackage{pifont}  \usepackage{indentfirst}   \lstset{language=[Visual]Basic, % keywordstyle=\color{blue},commentstyle=\color{ForestGreen},stringstyle=\color{Maroon},% basicstyle=\ttfamily\normalsize, frame=lines, % showspaces=false, showstringspaces=false,% tabsize=4, aboveskip=10pt, belowskip=10pt, % lineskip=2pt, numbers=left, numberstyle=\tiny, stepnumber=1, numbersep=5pt,% numberblanklines=false, % breaklines, breakatwhitespace, prebreak=\_, breakindent=0pt % }  \lstset{morekeywords={Or, Loop, Until, To, As, Single, Module, Double, ByVal}}  \lstset{emph={Console}, emphstyle=\color{Aquamarine}}  \newenvironment{case}[1]{\renewcommand\lstlistingname{Case}% \begin{lstlisting}[caption={#1}]}% {\end{lstlisting}}  \newcommand{\code}[1]{\lstinline[basicstyle=\rmfamily\normalsize, prebreak=, keywordstyle=\ttfamily]{#1}}   \begin{document}  Example with inline, that works: \code{Console, Sub in Module}.  \begin{case}{Hello world} %doesn't work Module Module1     Sub Main()         Console.WriteLine("Hello World!")         Console.ReadKey() End Sub End Module \end{case}  \end{document}   Thank you in advance!
42327
I am writing my CV using moderncv package, everythig is nice but I have a problem with \cventry command. I have something like this:   (it means 2010 - now)  I would want to have this in one line, rather than in two lines. I tried looking into the moderncv style files but with no success. What can I do to achieve the effect I want?
66173
I am trying to learn how to use enumitem's keys to adjust a description list.  In this case, I would like to have my list items and description text both left aligned, but the description text should all start at the same horizontal position.  What I have below comes pretty close, but it seems that the setting of \labelwidth is being ignored, and that there is some other thing I need to add to get the correct value of leftmargin.  The tabular version produces that output I want, but would prefer to use the description list from enumitem.  \documentclass{article} \usepackage{enumitem} \usepackage{calc}  \newcommand*{\LongDescription}{This is a  long sentence to check that when it gets wrapped it is indented properly on the next line, but doesn't seem to when used in the list.}% \newcommand*{\ShortDescription}{A very short description.}%  \begin{document} \newcommand*{\LargestItem}{The Largest Named Item}% \newlength{\MaxWidth}% \settowidth{\MaxWidth}{\LargestItem}% \newlength{\MaxWidthPlusLabelSep}% \setlength{\MaxWidthPlusLabelSep}{\labelsep+\MaxWidth}%  \begin{description} [leftmargin=\MaxWidthPlusLabelSep,labelwidth=\MaxWidth] \item Small Name:     \ShortDescription \item The Largest Named Item: \LongDescription \item Larger Name:     \ShortDescription \end{description}   \hrule\medskip  I want something like this, but should be able to do this with a list:  \bigskip \begin{tabular}{l@{ }p{\linewidth-\MaxWidthPlusLabelSep}} Small Name:     &amp;\ShortDescription\\\\     The Largest Named Item:     &amp;\LongDescription\\\\     Larger Name:     &amp;\ShortDescription \end{tabular} \end{document}   I have tried the solutions on how to  and  but have not been able to adapt them to what I want.
69185
Inserting an \hphantom to indent a table row works in tabular, but in tabulary it produces extra vertical space instead.   Since these are left-aligned L columns I would expect the space at the left edge to be preserved, while the space on the right is variable. Why does this happen and how could I fix it?  \documentclass{article} \usepackage{tabulary}  \newcommand{\sator}{Sator arepo tenet opera rotas} \newcommand{\tabindent}{\hphantom{em}}  \begin{document}  \section{Tabular}  \begin{tabular}{ll} \sator  &amp; \sator\\ \tabindent\sator &amp; \tabindent\sator\\ \end{tabular}  \section{Tabulary}  \begin{tabulary}{\textwidth}{LL} \sator  &amp; \sator\\ \tabindent\sator &amp; \tabindent\sator\\ \end{tabulary}  \end{document}
34477
I want to write shell Code in my LaTeX document. I'm using the listings package, with a code sample adapted from :  \documentclass{report}  \usepackage{color} \usepackage{xcolor} \usepackage{listings}  \usepackage{caption} \DeclareCaptionFont{white}{\color{white}} \DeclareCaptionFormat{listing}{\colorbox{gray}{\parbox{\textwidth}{#1#2#3}}} \captionsetup[lstlisting]{format=listing,labelfont=white,textfont=white}  % This concludes the preamble  \begin{document}  \begin{lstlisting}[label=some-code,caption=Some Code]    NETWORKING=YES  HOSTNAME= f e −19. l o c a l d o m a i n  } \end{lstlisting}  \end{document}   The problem is that there is some extra space between every character when I generate a PDF. I would like the code without this space. The extra space is visible in the the part HOSTNAME=.
74443
I have a problem with scrarticle (and its option parskip=half), fontenc and algorithm2e:  \documentclass[parskip=half]{scrartcl} \usepackage{fontenc} \usepackage[boxed]{algorithm2e}  \begin{document} \begin{algorithm}     \KwData{test} \end{algorithm} \end{document}   If you compile this document (with pdflatex), then there is no padding between the text and the frame of the algorithm. If you remove parskip=half or \usepackage{fontenc} (or both), then everything is fine.  What is happening here? Did I do anything wrong? How to fix this problem?
11664
I am just curious that the following format looks good to you or not? The preamble I used is just   \documentclass[12pt,a4paper]{article}  \usepackage{amsmath} \usepackage{amsthm} \usepackage{amssymb}   I don't feel it's so good because the first paragraph has no indent but the second does. If the first paragraph is much longer, than it's fine. But if not, it looks strange. Should I leave it, or you have suggestions for this?
120383
I have this test file which is supposed to put Hello there. near the top of the page but it does not work in so far as there is still tons of vertical space at top. How can I fix this?  \documentclass{article} \begin{document} \vspace{-10cm} Hello there. \end{document}
54608
In the  manual on page 183 ,this example is given:  \begin{figure} \centering \hspace*{\fill} {ILLUSTRATION 1} \hfill {ILLUSTRATION 2} \hspace*{\fill} \caption{Example float with two illustrations} \label{fig:mult1} \end{figure}   I have tried to figure out, what the difference between \hspace*{\fill} and \hfill is!?  The  and  did not help me much.
37192
I have a document class that auto generates header from some user input. The problem is the first page should have a different page header than the others and the headline can be multi line. So \headheight is too small. Here is a demonstration of the problem:  \documentclass[twoside]{scrartcl} \newcommand{\longfirstpagehead}{% \begin{minipage}{10cm} some\\long\\text\\text\\text\\text\\text\\text \end{minipage}} \newcommand{\normalhead}{normal} \usepackage{scrpage2}  \newpagestyle{firstpage}{%     {\longfirstpagehead\hfill} %twoside links     {\longfirstpagehead\hfill} %twoside rechts     {\longfirstpagehead\hfill} %oneside     (\textwidth,1pt) }{%     {\pagemark\hfill} %twoside links     {\hfill\pagemark} %twoside rechts     {\hfill\pagemark} %oneside } %  \newpagestyle{normal}{%     {\normalhead\hfill} %twoside links     {\normalhead\hfill} %twoside rechts     {\normalhead\hfill} %oneside     (\textwidth,1pt) }{%     {\pagemark\hfill} %twoside links     {\hfill\pagemark} %twoside rechts     {\hfill\pagemark} %oneside } %    \pagestyle{normal} \AtBeginDocument{     \thispagestyle{firstpage}}  \usepackage{blindtext} \begin{document}     %\vspace*{1cm}     \blindtext      \blindtext     \pagebreak \end{document}   I tried to read the height with \settototalheight and:   add a \vspace at beginning of document (unnice hack):  still the bad box warning (of cause) first section has different alignment  manually change \headheight in pagestyle  text height and page foot is wrong (can't change this because some scoping?)  use Komascript in pagestyle  \recalctypearea warning  geometry in pagestyle  pretty much the same problem like the manual attemp    So I would like to change the \headheight for the pagestyle firstpage, but the page should still have the same page margins, etc. The problem is that this has to work with \thispagestyle. (Better Ideas are also welcome) Something like \thispagegeometry in geometry would be great. ;)
84071
I am writing my curriculum vitae, but I have one question.  In the first image, there are spaces between different sections.  (Between contact and phone, between education and Seoul~~,....)  Thus, I want to narrow down these gaps.  How can I solve this problem??  \documentclass[margin,line,letterpaper,11pt]{res}  \usepackage{times}  \usepackage{enumitem}   \setlength{\topmargin}{0.1in} \setlength{\textheight}{11in}  \setlength{\textwidth}{6in} \setlength{\oddsidemargin}{-.55in}  \setlength{\evensidemargin}{-.55in}  \oddsidemargin -.25in \evensidemargin -.49in \textwidth=5.4in  \newcommand{\ts}{\textsuperscript}  \newcommand{\block}[1]{     \vspace{.1in} \section{\sc #1} }  \newcommand{\subblock}[1]{     \vspace{-.2in}\subsection*{#1} }  \newenvironment{enum}{     \begin{enumerate}[leftmargin=5mm]     \setlength{\itemsep}{1mm} }{     \end{enumerate} }   \begin{document}   \name{\sc \LARGE  }   \begin{resume}  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%  \block{Contact} Phone:  \\ Email:  \\\vspace*{-6mm} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%  \block{Education}  University : \\  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%  \block{Other\\ Activities}  Club : \\   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%  \end{resume} \end{document}
66006
I am having trouble finding out why the white space between my paragraphs is variable. Sorry, I am not allowed to post images but sometimes there is no white space (like it should be), just an indent to denote that a new paragraph has started. While sometimes the paragraphs start with an indent AND there is (sometimes substantial and thus variable) white space between the last sentence of the previous paragraph and the first sentence of the new paragraph.  In my tex file, there is no difference between what I do in the first and second examples of my text: just two hard returns to denote the start of a new paragraph. I was wondering whether it could be due to placement of figures and footnotes but I have no idea how to change it. I don't mind a little variable white space between paragraphs but the above example is too extreme for my taste. Thanks for your advice!
27548
Update 3 It took me longer than I wanted, but I’ve got some updates for you on our s-prose component. You can see the  with my thinking over at our design system’s repo. It does the following:  Spreads s-prose headers out from paragraphs for better grouping. Tightens up s-prose paragraphs a bit, and made sure spacing under headings are more consistent. Replaces all s-prose margins internal to the component with a CSS variable var(--s-prose-spacing) so our users can more easily tinker with it in their browsers and user scripts. Kills trailing margins in s-prose  You can see  of content at our Stacks documentation.  Update 2 I’ve split the difference between the original 1.3 line-height and the proposed 1.6 line-height. We’re now at 1.5, with additional refinements to spacing between elements. I’ve also reduced line height within code blocks back to near the original value.  Update 1 This is now live.  We’re doing a bit of refactoring on our post formatting. Currently, we apply a single class with both layout and styling called .post-text. Our first goal is to separate layout from our text styles. Simple enough! However, our current post styling has a few missing spots and areas for improvements. Using our  as a sandbox, we’ve beefed up our styling and created a new component called .s-prose. It’s designed to offer styling for everything the  spec allows. This should allow us to add Stack Overflow-flavored styling anywhere we need to consume Markdown—questions and answers, of course, but also things like user profiles. Our .s-prose component adds:  Proper formatting for   Further header support and better spacing there  Additional blockquote refinements.  Refinements for revealing spoilers. We now reveal this on click / tap for a more consistent experience across devices—fewer accidental reveals as well, since it’s no longer a :hover interaction. Clicking again does not hide the spoiler. We also now add a badge to the top right corner. You can see how these work on our . It looks something like this:   This is a spoiler  It has two lines   General refinements to spacing including nested lists, images within lists  Sizing variations for different contexts. We offer xs, sm, and md variations of the .s-prose component.   As with everything, our prose component is a work in progress. We think we’ve got a heck of a start to a reusable component. We plan on going live with the new component network wide on Thursday, August 27, 2020. We’ll edit this post if that changes. If you see something funky, let us know. Some things are intended but might feel like regressions—images have a slightly different baseline—but others may have slipped through the cracks.
113645
I'm trying to choose the positions of my tables but I can't figure out the difference between [H] and [h]. I've seen both advised over my search. If I use [h] the row spacing is different than [H] use.