Codeabdrucke
Mit einem Codeabdruck kann Programmiercode angezeigt werden, der sich über mehrere Zeilen erstreckt.
Example
Attribute
Das codelisting Element unterstützt die folgenden Attribute:
| Attribut | Typ | Standardwert | Beschreibung |
|---|---|---|---|
firstlinenumber |
xs:nonNegativeInteger |
1 |
The line number that gets assigned to the first line of code in the code listing which is displayed. By default, the line numbers start with one. |
highlight |
LineNumberRangeList |
A space-separated list of individual line numbers or line number ranges of the code to highlight. These lines are displayed differently than the other lines so that they can be distinguished by the user. By default, no lines are highlighted. | |
lang |
CodeLanguage |
plaintext |
Short string identifying the language of the code content, such as "plaintext" (no language), "xml", "java" or "cpp". |
name |
xs:Name |
- | Name des Elements. Dieser muss eindeutig unter allen Elementen in der Kursvariante sein. |
tags |
TokenList |
Durch Leerzeichen getrennte Liste von Etiketten, welches dieses Element haben soll. |