Skip to content

Commit 6b532f4

Browse files
committed
[TASK] Normalize formatting of all XLF files
XLIFF files are now indented with 2 spaces References: TYPO3-Documentation/Changelog-To-Doc#1516 Releases: main
1 parent c9c3056 commit 6b532f4

File tree

1 file changed

+26
-9
lines changed
  • Documentation/CodingGuidelines/CglXliff

1 file changed

+26
-9
lines changed

Documentation/CodingGuidelines/CglXliff/Index.rst

Lines changed: 26 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
:navigation-title: XLIFF
2+
23
.. include:: /Includes.rst.txt
34
.. index::
45
pair: Coding guidelines; Xliff
@@ -10,27 +11,39 @@
1011
XLIFF coding guidelines
1112
=======================
1213

14+
.. versionchanged:: 14.0
15+
With TYPO3 14.0 the TYPO3 Core supports the XLIFF formats 1.2 and 2.0.
16+
1317
Language files are typically stored in `XLIFF <https://en.wikipedia.org/wiki/XLIFF>`__
1418
files. XLIFF is based on XML.
1519

20+
.. content:: Table of contents
21+
1622
.. seealso::
1723

1824
:ref:`xliff`
1925

26+
.. _cgl-xliff-filenames:
27+
2028
Directory and file names
2129
========================
2230

2331
* Files have the ending :file:`.xlf`.
32+
* Language files are located in the directory
33+
:file:`EXT:my_extension/Resources/Private/Language/`.
34+
* Historically language files where named `locallang.xlf` or with a `locallang_`
35+
prefix. This is not recommended anymore. For a standard translation name
36+
`messages.xlf` is suggested.
2437

25-
* Language files are located in the directory :file:`EXT:my_extension/Resources/Private/Language/`.
26-
27-
Format
28-
======
38+
.. _cgl-xliff-indentation:
2939

30-
* Use TABs, not spaces.
40+
Indentation in XLIFF files
41+
==========================
3142

32-
* TAB size is 4.
43+
.. versionchanged:: 14.0
44+
With TYPO3 14.0 the TYPO3 Core switched from indentation with tabs to spaces.
3345

46+
* Use 2 spaces for indentation.
3447

3548
.. tip::
3649

@@ -39,7 +52,6 @@ Format
3952

4053

4154
.. index:: Coding guidelines; XLIFF language keys
42-
.. _cgl-localization:
4355
.. _cgl-xliff-language-keys:
4456

4557
Language keys
@@ -50,6 +62,7 @@ thus be avoided unless there are some technical limitations (for example, some
5062
very early or low-level stuff where a :ref:`$GLOBALS['LANG'] <LanguageService-api>`
5163
object is not yet available).
5264

65+
.. _cgl-localization:
5366

5467
Defining localized strings
5568
--------------------------
@@ -87,6 +100,10 @@ files:
87100
blanks before some punctuation marks.
88101

89102
Once a localized string appears in a released version of TYPO3, it
90-
cannot be changed (unless it needs grammar or spelling fixes). Nor can
91-
it be removed. If the label of a localized string has to be changed, a
103+
cannot be changed (unless it needs grammar or spelling fixes).
104+
105+
A localization string can be deprecated in one major TYPO3 version and be
106+
removed with the next one
107+
108+
If the label of a localized string has to be changed, a
92109
new one should be introduced instead.

0 commit comments

Comments
 (0)