New answers tagged

2

I think this is what you want: \documentclass{article} \usepackage{xparse} \usepackage{hyperref} \DeclareExpandableDocumentCommand{\foo}{smm}{% \texorpdfstring {\IfBooleanTF{#1}{\textsf}{\textit}{#2}--#3} {#2-#3}% } \begin{document} \section{This is \foo{A}{B}} \section{This is \foo*{A}{B}} \end{document}


0

All you needed was \string. \documentclass{article} \usepackage[english]{babel} \usepackage{xr-hyper} \usepackage[destlabel=true]{hyperref} \makeatletter \newcommand{\foo@star}[2]{\textsf{#1}-{#2}} \newcommand{\foo@plain}[2]{\textit{#1}-{#2}} \DeclareRobustCommand{\foo}{\@ifstar\foo@star\foo@plain} \makeatother \newcommand{\mysection}[1]{\section[\string ...


2

PDF/A is a standard for long-time archiving. It requires that all resources are embedded like fonts and color profiles. Also it restricts the language features. Advanced features like transparency or interactive features (JavaScript, some annotations, ...) are forbidden, which might be displayed differently in different viewers. A reasonable algorithm would ...


0

The problem seems to be connected to the Cyrillic font families not being properly selected. More like a side-effect than a bug, if you ask me. Adding the following two definitions to my template, actually helps me to solve the issue without removing the currently default \defaultfontfeatures{Ligatures=TeX,Scale=MatchLowercase}: % Define the main Cyrillic ...


1

Thérèse explained what happens (see comment and question's update section). The font doesn't have the simple parenthesis. A workaround I used for this: defined an english (the main language of the document) parenthesis with \textenglish to force the parenthesis from the Unicode Block "Basic Latin" LEFT PARENTHESIS (U+0028) and RIGHT PARENTHESIS (U+0029) to ...


2

The start macro \exercise is patched to catch the optional argument. hyperref already sets an anchor for the numbered exercise. The bookmark uses this anchor directly. Package bookmark is added to implement the previous point. Also the bookmarks are updated faster. Full example file: \documentclass[a4paper]{scrartcl} \usepackage[T1]{fontenc} ...


0

No. When a page of a PDF is included in a PDF by any of the TeX engines/device drivers it is always included completely; no destructive cropping or other manipulation is done.


2

From the PDF/A rules: Transparent objects and layers (Optional Content Groups) are not permitted. Link Try using a different cropping tool that removes the margins rather than moving them to an Alpha layer for transparency.


2

I extend Chris H's answer: I extented the pdfcolorsplit.py script with an option -r to reassemble all split parts again into a final pdf, by converting all b/w parts to grayscale before reassembling: use like (-p option worked the best) : ./pdfcolorsplit.py -p -v -s -r Report.pdf The code is here: #!/usr/bin/env python # Python 2 and 3 compatible. # ...


0

I would give a try to dvisvgm (part of TeXlive). You have to get a .dvi file with latex first and then you call dvisvgm. % This is file t.tex \documentclass{article} \usepackage[active,tightpage]{preview} \PreviewEnvironment{equation} \begin{document} \begin{equation} \dot x = f(x(t)) \end{equation} \begin{equation} x(t_0) = x_0 \end{equation} ...


0

Daniel's answer is great, but I missed the ability to move the smaller image (which in my case is a plot legend) horizontally as well as vertically. I'd also rather have the smaller image's size and coordinates defined in terms of the bigger one. So after a bit of tinkering I came up with the following macro: \newlength{\imagew} \newlength{\imageh} ...


2

The media9 package should be used instead of the obsolete movie15, as in the example below. Here is a JavaScript that cycles through the predefined views. The view changes every 5 seconds. As requested, the toolbar Play/Pause button can be used to pause/resume the animation. For further info about 3D JavaScript, see here. var time=0; var curViewIdx=0; ...


1

I've played with the EPS file you linked in the comment above. As you said, after conversion the white grid is showing up in the PDF and even in the PNG after using convert -density 300x300 branin.eps branin.png The only thing I know to get rid of the grid is to convert to a very high resolution PNG and then scale the PNG down. The white grid gets ...


0

Been a few months since I asked this question, so I figured would be good to give it closure, for anyone facing the same problem. The best solution I found is to install SumatraPDF. It is very lightweight and brings back the long lost user experience of opening a PDF almost instantly (I can't recall when Adobe's PDF Viewer last was so fast... maybe in ...


0

Protip: Don't have file names with empty space in them such as "Spider Man" Or "Dolly Parton" For whatever reason XeLatex compiler can't handle them.


2

You have to enclose each “page” in an environment: \documentclass[multi,crop,border=2]{standalone} \standaloneenv{my} \begin{document} \begin{my} Test1 \end{my} \begin{my} Test2 \end{my} \end{document}


1

For the ease of reading, any good typesetting software will make use of Ligatures. Means, it merges letters to simplify reading the text: (Source: Wikipedia) Since these composite-characters are not recognized by your text-editor software where you paste it, it (apparently) replaces them by line-breaks. If you're lucky, you might be able to use the ...


6

Short answer: No this is not possible Long answer: You might try what @samcarted suggested and just copy and paste everying and add the formatting manually. Alternatively you could mix the old and the new slides/pages together by using pdfpages (not sure whether you're using beamer or article or something else, but the example should translate to other ...


0

www.daz3d.com which is freeware (as in beer) may be of help.


1

Moving fonts, Windows 10, CS6 In Windows 10, using CS6, I could only find the fonts in Adobe Illustrator when putting the tex fonts into the folder below C:\Program Files\Adobe\Adobe Illustrator CS6 (64 Bit)\Support Files\Required\Fonts In Windows 10, it did not work to paste the tex files into C:\Program Files\Common Files\Adobe\FontsRecommended ...


1

As others have already answered, I like to use hyperref. However, as my documents often have \author and \title commands I do not want to repeat myself in the package parameters. Luckily, hyperref also has a parameter for that. If you want it to read the information from your \author and similar tags, simply include it like this: ...


2

\clearpage starts a new page and causes all floats (tables, figures, &c.) so far appeared to be placed. Then \if@twoside (tests if you're in a two-sided document; if yes, it proceeds)\ifodd\c@page(tests if current page is odd; if yes, does nothing) \else% \hbox{}% (if no, puts an empty box on the even page) \thispagestyle{empty} % Empty header ...


0

I recommend you to convert into .eps encapsulated postscript: MS Office 2003 (on Windows XP SP2) handles .eps. I guess that MS 2007 on Win 7 handles too :) The conversion process: pdfcrop <pdf file without ext>.pdf pdftops -f <page number> -l <page number> -eps "<pdf file without ext>-crop.pdf" rm "<pdf file without ...



Top 50 recent answers are included