Template:Chess diagram

(diff) ← Versione meno recente | Versione attuale (diff) | Versione più recente → (diff)

Syntax

```{{Chess diagram
| <alignment> (param #1)
| <a8> | <b8> | ... | <h8>  (#3 to ...
| <a7> | <b7> | ... | <h7>
...
| <a1> | <b1> | ... | <h1>  ( ... #66)
| <footer> (#67)
}}
```

Parameters:

• `<alignment>` – defines horizontal alignment (floating) of the whole table, must be `tright` or `tleft` (or nothing)
• `<header>` – the text which appears above the diagram, may be empty;
• `<a8>, <b8>, ... <h1>` – define corresponding squares of the chessboard, see below;
• `<footer>` – the text which appears beneath the diagram, may be empty; optional – can be left out (currently not in the other templates)

A square is defined by the name of piece or empty parameter. The names of the pieces are those given in algebraic notation:

• k = king
• q = queen
• r = rook
• b = bishop
• n = knight
• p = pawn

White pieces are uppercase, while black pieces are lowercase.

An empty square is written either using underscores, spaces, or nothing at all. One space is recommended.

• <space> = empty square

You can also use "x" for a cross and "o" for a black circle on an empty square.

• x = cross/x
• o = black circle

Examples

W. Langstaff, Chess Amateur 1922
Mate in two.
This problem uses partial retrograde analysis method.

```{{Chess diagram
| tright
| '''W. Langstaff''', ''Chess Amateur'' 1922
|=
8 | | | | |k| | |r|=
7 | | | | | | | | |=
6 | | | | | |B| |P|=
5 | | | |R| |K|p|P|=
4 | | | | | | | | |=
3 | | | | | | | | |=
2 | | | | | | | | |=
1 | | | | | | | | |=
a b c d e f g h

| '''Mate in two.''' <br> This problem uses ''partial retrograde analysis'' method.
}}
```