{latex3} is about the new material being developed by the LaTeX3 Project. This includes the expl3 programming language along with higher-level concepts such as xparse.

learn more… | top users | synonyms

8
votes
1answer
132 views

A Couple of Tidbits about the LaTeX3 \tl_case:??? Function

On p. 95 of my interface3 documentation, dated July 28, 2013, the \tl_case:??? function is first introduced as having a signature \tl_case:NnnTF, but on its extended description for usage it appears ...
6
votes
1answer
134 views

Shell-escape with LaTeX 3

What is the LaTeX 3 equivalent to \write18 if there is one? I want to call lilypond from within my TeX document.
5
votes
1answer
113 views

About catcodes and Family in LaTeX3/expl3

This is not so much the display of an issue or problem I'm facing out of my wish to use as much LaTeX3/expl3 as possible in my TeX-based work, as a request for advice on the proper ways in that ...
7
votes
1answer
62 views

Confusion about Data Retrieval from a LaTeX3 Stack

I'm trying to perform a very simple processing task in LaTeX3, namely, defining a series of functions named in terms of the token lists retrieved from a clist as a stack. Each function will set ...
5
votes
1answer
148 views

Author firstname, Initials and Lastname values find and store in LaTeX3

I would like to store each authors firstname, initials and lastname values in newcommands. My MWE is: \documentclass{article} \usepackage{xparse} \makeatletter \def\author#1{\gdef\@author{#1} ...
5
votes
1answer
73 views

Confusing Problems with LaTeX3/expl3 \pdftex_if_engine:TF Switch

For a number of days I've been confused with some problems I had when using the \pdftex_if_engine:TF switch in a LaTeX3/expl3 class of my own. I thought it would be equivalent to the \ifpdf switch, ...
13
votes
1answer
174 views

Using calc-like (calc Package) Commands within LaTeX3/expl3

In my pursue to switch as much as possible from LaTeX2e code to LaTeX3/expl3, I got stuck with the usage of some of the calc package facilities. I've read of the l3calc package, but it seems it is ...
6
votes
1answer
62 views

LaTeX3: l3keys Multiple-Choices Keys and Startup Value for Predefined Choice Integer Variable

In the interface3 documentation it can be read (what follows is not a literal quotation) that the variable \l_keys_choice_int is available to be used as an index register for a multiple-choices key ...
3
votes
0answers
69 views

Difficulty saving formatting to a sequence to be called later in my code

I had an idea about how to answer this question and started putting some things together. I wanted to put something together that was fairly powerful and could handle simplification of linear ...
4
votes
1answer
111 views

I need a fully expandable function to expand in an “f” type argument

I really hope that I'm asking the correct question. What I'm actually working on if far more convoluted than what's happening in the MWE here. I think I've narrowed down things to real problem. I ...
7
votes
1answer
100 views

Driving the Options of a Given Package from Another Package or Class in LaTeX3/expl3

I'm afraid I still don't get how I'm supposed to handle the communication of options among packages in a LaTeX3/expl3 context. Let us say I have a package pkg1 where I define an option opt_pkg1 that ...
6
votes
1answer
101 views

Is there something like a scope of \NewDocumentCommand?

Following along the line of my (confused) post on xparse and expl3, but this time hopefully with no typos or missing characters, I've devised a small package just to check a l3keys-based definition ...
8
votes
1answer
95 views

Why is my list showing up twice

Why does the following code result in my list being strangely, but not quite duplicated? \documentclass{article} \usepackage{xparse} \ExplSyntaxOn \ExplSyntaxOn \clist_new:N \l_ae_number_clist ...
4
votes
1answer
127 views

Dazzled and confused about xparse and LaTeX3 Booleans

I'm just starting my journey with LaTeX3/expl3, and although fascinated by the great work that the LaTeX3 team is doing, and by the enormous difference it brings about with respect to "classical" ...
38
votes
3answers
955 views

LaTeX3-sensitive editors

I'm starting to embed LaTeX3 code in my custom classes and packages -- and enjoying it more the further I learn about it --, but at least to me it would make for an even better experience if, as it is ...
6
votes
1answer
105 views

Where can I report typographical errors for LaTeX3 documentation?

Following up on What can *I* do to help the LaTeX3 Project, there doesn't seem to be a definitive place to report a typo in any of the LaTeX3 documentation (e.g. texdoc interface3). Where can I ...
6
votes
1answer
188 views

Macro to calculate \baselineskip for given font

I want to write a macro that returns the \baselineskip multiplied with a fixed value for a given font spec. That seems to be harder than I would imagine... after some fiddling I came up with this: ...
9
votes
2answers
252 views

Giving arbitrary unicode characters, passed as arguments, a math-active definition?

I've been trying to write a LaTeX3 function to make arbitrary unicode characters math active and give them a definition. I'm using XeLaTeX. My solution inexplicably works for some examples but not for ...
5
votes
2answers
174 views

How can I use `catchfile` package to gobble first characters on a line

When using the fancyvrb environment Verbatim, you can gobble the first n characters of each line before printing it out. I'd like to be able to do something similar, but not via verbatim. In the ...
8
votes
1answer
124 views

Use LaTeX3 variables within TikZ picture

I’m new to LaTeX3 and don’t understand why the following doesn’t work \documentclass{article} \usepackage{xparse} \usepackage{tikz} \ExplSyntaxOn \tl_new:N { \g_tobi_color_tl } \tl_set:Nn { ...
8
votes
1answer
116 views

Where are the sources for LaTeX3 development in TeX Live?

I'd like to take a look at the sources for some of the LaTeX3 development to model after, but I'm having trouble finding them. Where might I find the sources for texdoc interface3, texdoc xparse, and ...
6
votes
3answers
177 views

White space unexpectedly lost when trimming a string

I'm trying to follow the example given here \documentclass{article} \usepackage{xparse} \ExplSyntaxOn \seq_new:N \l_ae_insertQuotedMatter_seq \tl_new:N \l_ae_insertQuotedMatter_trash_tl ...
3
votes
1answer
100 views

LaTeX3: insert macro after (unknown unknown number of) parameters?

I've just played with expl3 for a couple of hours. Many things are much more convenient than with 2e. There are functions for things that I thought to be impossible with LaTeX. However, I am missing ...
8
votes
1answer
95 views

How do the \xx_case: functions work?

In the process of answering expl3 switch for booleans: Is there a \bool_case:Nnn?, I tried to make sense of the various \xx_case: functions Expl3 provides. Here, for example, is \tl_case:Npn: ...
6
votes
2answers
149 views

expl3 switch for booleans: Is there a \bool_case:Nnn?

There's \int_case:Nnn, \tl_case:Nnn, \str_case:Nnn, but I can't find something like \bool_case:Nnn. I know I can write: \bool_if:NT \l__<mymodule>_<nameA>_bool { ... } \bool_if:NT ...
20
votes
1answer
315 views

Are there any typographical improvements planned for LaTeX3?

I have read a few posts about the changes to LaTeX in the upcoming "version", are there planned any changes to how LaTeX renders typography? Regarding kerning, spacing and all the "fancy" things ...
5
votes
2answers
127 views

Can I refer to key value in general code?

Related: keyreader: How to save choice key value to a macro. I’m using l3keys2e, but I suspect this might not be the ideal way to go about what I’m trying to do. I’m building a private package ...
6
votes
2answers
125 views

Generate l3keys meta key from subkey

I’ve created a simple package with options settable via l3keys2e. I was able to figure out how to make the syntax \usepackage[format = international]{phone} work, but I’d like to make the syntax ...
31
votes
2answers
264 views

What are the best practices for programmatic interaction between LaTeX3 and LaTeX2e?

I'm thoroughly enjoying using LaTeX3 for programming my LaTeX stuff and the more I use it, the easier it gets and the more I shudder at returning to LaTeX2e or even pure TeX! But every now and again ...
13
votes
1answer
123 views

How do I remove the next token from the stream in LaTeX3?

I want to remove a token from the stream from within a command (ignoring spaces). The next token will be a { (actually, I've just thought that it might not be ... but I'll continue as if it were). ...
6
votes
2answers
66 views

Inline Mapping Bug?

The enclosed document creates a sequence variable and then uses inline mapping to attach a sequence number to each item. The inline map then outputs the result and places it into a token list variable ...
33
votes
3answers
858 views

Using LaTeX3’s xtemplate

Relevant are the answers to Moving to LaTeX3 for package authors and What new bits have already been implemented in Latex3? Will my current documents (with many packages) still compile with Latex3? ...
7
votes
2answers
319 views

Rounding up decimal number using LaTeX 3

I would like to use LaTeX 3 to round up decimal numbers; I want something like the following: If I type \RoundingUpFunction{2.7} it should return 3 as output. Unfortunately, I haven't taken the ...
9
votes
2answers
131 views

Emulating \@ifnextchar in expl3

I would like to write an expl3 version of the following. \documentclass{article} \makeatletter \def\ie{i.e\@ifnextchar.{}{.\@{} }} \makeatother \pagestyle{empty} \begin{document} \noindent \ie ...
13
votes
1answer
131 views

How do I register the prefix of my expl3 package?

This question needs an easy to find answer here, so: I was told that I can and should register prefixes of my macro names in my expl3 using packages. How do I do that?
5
votes
2answers
120 views

Expl variable assignments not behaving as I expect

I don't get what I'm doing wrong here. Neither of the commented lines work as the uncommented version does. \begin{filecontents}{silly.tex} This is just a test. \end{filecontents} ...
8
votes
1answer
123 views

Sorting a clist in LaTeX3

I have a clist that I'd like to bubble sort. I'm sure this is a simple matter of something like \clist_bubblesort:N or something, but I don't know what the appropriate incantation is. A quick google ...
7
votes
1answer
306 views

\pdfstrcmp or \strcmp in pure TeX

I'm trying to get LaTeX3 working with an old e-TeX kernel, and it fails due to the lack of \pdfstrcmp (or XeTeX's \strcmp equivalent). Is there a pure TeX definition of \pdfstrcmp that I could insert ...
1
vote
1answer
163 views

Error compiling modiagram [closed]

EDIT: This question has been identified as a bug Consider the following MWE as t.tex from the modiagram manual: \documentclass[border=3mm]{standalone} \usepackage{modiagram} \begin{document} ...
11
votes
1answer
154 views

Index problem when using l3doc for LaTeX document writing

I use l3doc to write document for my package. In the document I need describe macros, environments and options of the package. I started using the environment function only. After the tip came from ...
35
votes
2answers
531 views

What do ExplSyntaxOn and ExplSyntaxOff do?

Related to the question What do \makeatletter and \makeatother do? for LaTeX2e, here related to LaTeX3 What do \ExplSyntaxOn and \ExplSyntaxOff do?
8
votes
2answers
202 views

Automating table creation

I have the following table that I need to recreate quite a few times Due to its size and complexity (yes, I am a tex novice) I am looking into ways of automating the creation of said table. I try ...
3
votes
1answer
312 views

Emulating amsmath's \varGamma…\varOmega with unicode-math

While recompiling old documents with XeLaTeX and unicode-math I have run into the two problems: The amsmath \varGamma...\varOmega macros for slanted uppercase Greek math characters are not defined. ...
8
votes
1answer
154 views

Working with clist indices in LaTeX3

Friends, I'm trying to port an old code of mine to a LaTeX3 implementation. Thanks to egreg, Joseph and David, I made a good progress! But then, I got stuck. From the link above, I'm porting my ...
3
votes
1answer
62 views

How do I create an expandable conditional with a loop inside?

I need to create an expandable conditional that uses a loop (that is, a ..._map_function:). It should either return true from inside the loop, or return false otherwise. In a 'normal' programming ...
21
votes
1answer
424 views

Grid typesetting with LaTeX3

Grid typesetting is something that is rather hard to achieve with LaTeX and as this question states there are currently two packages, e.g. grid and gridset, that can help to use grids. Unfortunately ...
16
votes
0answers
514 views

A flexible derivative macro with LaTeX3

In an earlier post I asked a question about writing a flexible derivative macro, and someone suggested that a LaTeX3 version might be easier to understand, so I decided to try my hand at writing one. ...
1
vote
0answers
77 views

flexisym incompatible with AMS classes since last expl3 update [closed]

It seems that since the last expl3 update (March 14, 2013), the flexisym package (used by breqn) is no longer compatible with the AMS document classes. Here is a minimal failing example: ...
14
votes
2answers
336 views

LaTeX3: How to get reliable control over the level of expansion?

Say you want to write LaTeX3 code that manages user data. Sometimes you want to process that data, but other times you just want to store it, move it around and return it unchanged (when developing a ...
6
votes
1answer
143 views

listings package and latex3 variable

I'm trying to change a custom environment from a lot of optional parameters to a ;-separated list (using this answer as a template and writing its main functionality as a latex3 macro). The macro ...