The Stack Overflow podcast is back! Listen to an interview with our new CEO.

Questions tagged [stringstrings]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
4
votes
2answers
56 views

Lettrine + string manipulation + some fonts = errors and weird issues

I am encountering some weird behavior and errors when manipulating strings inside of \lettrine arguments: the code either doesn't compile or produces unexpected results. On top of that, it is font-...
1
vote
1answer
42 views

Automatically add parentheses if expression is composite

I'm trying to write a macro which automatically adds parentheses to an expression if the argument is composite. Specifically, I would like to define a command for the inner product of two vectors ...
0
votes
1answer
123 views

Split string variable by spaces

I am updating a custom latex class but I am a newbie with Latex and I need to parse a command like that \author{First Middle Last} into a new one \author{Last}{First Middle}. I cannot provide the \...
4
votes
3answers
210 views

Macro to capitalize all letters and change breaks to underlines

I'm trying to make a macro that will take an input phrase, capitalize all letters, and replace all breaks with underlines: \ctest{one word} => ONE_WORD I've been trying to use the stringstrings ...
1
vote
1answer
44 views

stringstrings package redefines math symbol(s)

I am loading stringstrings package in my document and the double vertical bar \| (in math mode) is printed as |0 (single vertical bar followed by zero). I checked the stringstrings.sty file and ...
2
votes
2answers
80 views

substring with calculated end position

I have a string and I would like to use only the first part of the string up to a specific position. So I wrote the \stringpart command using strinstrings' functions. The position of the searched ...
2
votes
3answers
121 views

How to use stringstrings to include braces in to-string

Macrons in LaTeX are typset with '\=' preceeding the character, for example '\=o' creates an 'o' with a macron. I would like to use stringstrings to define a newcommand to replace all '/' characters ...
2
votes
1answer
1k views

Automating Title Capitalization in Sections, Subsections, etc

I'm trying to automate the capitalization of titles in sections, subsections, etc. Basically, I'd like to format every title with \capitalize from the stringstrings package. One approach I've tried is ...
8
votes
2answers
894 views

Title case an acronym

Sometimes in my document I wish to use an acronym. Sometimes I want the acronym to appear in title case (for example if it appears in a title).* *I need this to work in all environments, not ...
2
votes
1answer
331 views

Character replacement in unicode string

I need a command to replace (erase) the characters · and | from a string. Consider the following naive code: \documentclass{article} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \...
4
votes
2answers
730 views

Replacing braces in strings

I know I should probably not want to, but say for the sake of discussion that I wanted to remove braces from a string for some purpose (background, now obsolete). From its package description, ...
5
votes
4answers
530 views

How to match last substring

I am working on displaying source code for which I pass a path to a macro. Now I am wondering if it is possible using xstring or stringstrings to match from after the last delimiter, i.e. / to the end ...
5
votes
2answers
173 views

Format a variable in math mode dependent on its case

I have a special kind of variable in my equations which I want to be formatted dependent on its case (lower or upper). I already tried using the package stringstrings, but there seem to be problems ...
3
votes
2answers
162 views

Trouble using convertchar and thestring inside a LaTeX command or table

I'm trying to generate page references inside a command that defines a row of a table, with the name of the label being referenced generated as a result of some string maniupulation using ...
3
votes
2answers
580 views

Converting an underscored string to camelcase

I would like to take a string containing underscores and convert it to CamelCase. I am attempting to do this using the stringstrings package. Here is my code: \documentclass[11pt]{report} \usepackage{...
3
votes
1answer
195 views

Remove two words

I'm writing a description of a method, where the title of each section is formatted like Step X: <step title>. Now, I want to reference the section as Step X ("<step title>"). I am aware ...