Search found 15 matches

by woj-k
Thu May 14, 2015 3:29 pm
Forum: Graphics, Figures & Tables
Topic: Subfloat references broken by hyperref's implicit=false
Replies: 0
Views: 2729

Subfloat references broken by hyperref's implicit=false

Hello all,

I am using the subcaption package with hyperref. If I allow hyperref to redefine LaTeX internals (implicit option set to true), everything works fine. If, however, I do not want a hyperlinked document and set hyperref's implicit=false option, subcaption's \subref macro generates errors ...
by woj-k
Thu Dec 25, 2014 1:32 pm
Forum: General
Topic: Best of two tests for empty argument
Replies: 2
Views: 5378

Best of two tests for empty argument

Hi everyone,

I'm recently using a lot of macros that have to check if an argument is supplied empty (usually an optional argument, but I don't suppose that matters). In other people's code I noticed two typical ways of doing it in plain LaTeX.

\documentclass{minimal}

\newcommand*{\detokenizetest ...
by woj-k
Tue Mar 18, 2014 9:36 am
Forum: Fonts & Character Sets
Topic: Steep accents over capitals in XeLaTeX
Replies: 0
Views: 2642

Steep accents over capitals in XeLaTeX

Hi everyone,

I am using XeLaTeX and Gentium Plus. I need to print lowercase-uppercase pairs of letters, some of which bear acute accents. However, acute accents are steeper on lowercase letters than they are on capitals. I understand why this is desirable in normal text, but in a table with the ...
by woj-k
Wed Jul 17, 2013 1:29 pm
Forum: Graphics, Figures & Tables
Topic: Float placement ignored when passed via macro
Replies: 2
Views: 3877

Re: Float placement ignored when passed via macro

It worked! Your solution is trivially integrated into the MWE and solves the problem.

I would probably spend a good few more weeks fooling around with \expandafter's; switching arguments around and reading+inserting the square brackets in a separate step is a new trick to me. I will think on how to ...
by woj-k
Sun Jul 14, 2013 3:08 pm
Forum: Graphics, Figures & Tables
Topic: Float placement ignored when passed via macro
Replies: 2
Views: 3877

Float placement ignored when passed via macro

Hello everyone,

I have come across an interesting problem with floats. As I was writing some wrapper environments, I noticed that the optional position argument cannot be processed correctly, if it is first stored and then retrieved from a temporary `storage' macro. In th MWE below, myfloatone ...
by woj-k
Mon Jun 17, 2013 2:26 pm
Forum: General
Topic: Wrapper for subcaptionbox: automatic vertical alignment
Replies: 1
Views: 5214

Wrapper for subcaptionbox: automatic vertical alignment

Fixed up a solution using the \VerbatimOut facility of the fancyvrb package, with export of each row to an external file and using the code twice---once to determine the size and once to print the correctly aligned row. It all happens on the same run. Had to redefine \panel for the size ...
by woj-k
Thu Jun 13, 2013 9:44 pm
Forum: General
Topic: Wrapper for subcaptionbox: automatic vertical alignment
Replies: 1
Views: 5214

Wrapper for subcaptionbox: automatic vertical alignment

Hello everyone,

I got stuck on designing easy-to-use command wrappers for multipanel floats (i.e. subfigures/subtables) built around the subcaption package. The problem has to do with vertical alignment of the individual panels of the float: the 'default' behaviour I have observed is bottom ...
by woj-k
Thu May 12, 2011 9:13 pm
Forum: Page Layout
Topic: Multicolumn Misalignment Problem
Replies: 1
Views: 2308

Multicolumn Misalignment Problem

With multicol it's important to keep track of any superfluous whitespace that's introduced (a linebreak in the .tex file counts as a space, etc.) The easiest way to avoid suprises is to end every line with a comment sign. Here you also need a \noindent, for obvious reasons.


\begin{multicols}{3 ...
by woj-k
Wed May 11, 2011 11:52 pm
Forum: Page Layout
Topic: Remove empty Page after ToC
Replies: 8
Views: 22119

Remove empty Page after ToC

The empty page isn't put there by the ToC, but by \mainmatter. If you look inside the file "book.cls", you will find a definition that goes

\newcommand\mainmatter{%
\cleardoublepage
\@mainmattertrue
\pagenumbering{arabic}}

All you need is redefine \mainmatter with \clearpage instead of ...
by woj-k
Sun Nov 28, 2010 7:21 pm
Forum: Fonts & Character Sets
Topic: Foreign characters and \write
Replies: 4
Views: 3262

Foreign characters and \write

Solved! (for the most part)

This is not nearly as cool as verbatim \write to a file would be, but it works in this particular case. I took advantage of only dealing with a finite set of control sequences, and I redefined each of them locally for the purpose of the \write command.

\def ...