Questions tagged [typography]

Challenges related to the arrangement, layout, or formatting of monospace plain text.

4
votes
2answers
216 views

Alignment of a string

This is similar to the alignment used in word. Task 3 inputs: A 1 line string, a positive integer k, and direction (left or middle or right) Your job is to ...
22
votes
9answers
3k views

Take CR and LF literally

As a celebration of good old Notepad, we are going to treat carriage returns and line feeds as what they originally meant, rather than what they are (ab-)used for today. Given a string consisting of ...
35
votes
49answers
3k views

Boustrophedonise

Related but very different. A boustrophedon is a text where every other line of writing is flipped or reversed, with reversed letters. In this challenge, we will just reverse every other line, but ...
16
votes
2answers
308 views

Fully-justify & hyphenate a block of text

Given a width and a block of text containing possible hyphen- ation points, format it fully- justified (in monospace). Fully justified means it is aligned ...
12
votes
10answers
618 views

Easier communication means… ○ circular edition!

Based on this, but I was asked[​1​],[​2​] to do a graphical edition. Task Generate a circular display of the text ...
30
votes
9answers
1k views

Between the Lines

While doodling around on square-ruled paper the other day, I came up with the above negative-space font for digits. In case you haven't spotted it yet, the spaces between the above shapes yield the ...
7
votes
3answers
338 views

LaTeX Table Generator

Write a function or program which, given a number of lines and columns, generates a corresponding tabular environment for LaTeX with no data in it. Table format ...
40
votes
24answers
3k views

Center The Text!

Center The Text! In this challenge you will be centering various lines. Examples Foo barbaz Foo barbaz ...
13
votes
7answers
491 views

Normal and inverted exclamation and question mark pairs

Challenge ¡We're going to give exclamation and question marks inverted buddies! Given a body of text containing sentences ending in ., ...
11
votes
5answers
210 views

Implement LaTeX accent macros

Introduction The LaTeX typesetting system uses macros for defining accents. For example, the letter ê is produced by \hat{e}. In this challenge, your task is to ...
18
votes
6answers
810 views

Reverse Boustrophedon Text

Boustrophedon is a type of bi-directional text where successive lines alternate between reading left-to-right and right-to-left. Character direction was also mirrored with respect to reading direction....
8
votes
2answers
207 views

Layout Text in Columns

Write a program or function that given some text, a number of columns, and the column width, formats the text into columns. This is plain text typography. Rules Input The text will be a string of ...
15
votes
3answers
322 views

Remove the hyphenation

Time for a new typography challenge! It’s a common problem when copy-pasting between various document formats: hyphenation. While it reduces the raggedness of a left-aligned layout or evens spacing in ...
12
votes
1answer
200 views

A most excellent proof, too small to fi—!

You sit at home, rubbing your hands in a most evil fashion. This time, I'll be able to set the community A-SPIN! I'll merely claim that I have proven this problem (which is of no doubt improvable) ...
21
votes
2answers
225 views

Format a Drop Capital

Introduction Write a program or function that adds a drop capital to a paragraph. The program will input the text to format, the column width, and the number of lines to drop the capital. The drop ...
10
votes
4answers
331 views

Align the text to a block

Task Your task is to write whole program, which will align given input to a block of given size. Input: ...
48
votes
7answers
3k views

Avoiding Rivers

Background In typography, rivers are visual gaps in a block of text, which occur due to coincidental alignment of spaces. These are particularly annoying since your brain seems to pick them up more ...
8
votes
2answers
402 views

Justify a text by adding spaces

Given this text Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ...