66
77When building a console application it may be useful to display tabular data:
88
9- .. code-block :: text
9+ .. code-block :: terminal
1010
1111 +---------------+--------------------------+------------------+
1212 | ISBN | Title | Author |
@@ -54,7 +54,7 @@ You can add a table separator anywhere in the output by passing an instance of
5454 array('80-902734-1-6', 'And Then There Were None', 'Agatha Christie'),
5555 ));
5656
57- .. code-block :: text
57+ .. code-block :: terminal
5858
5959 +---------------+--------------------------+------------------+
6060 | ISBN | Title | Author |
@@ -78,7 +78,7 @@ In this example, the first column width will be ``10``, the last column width
7878will be ``30 `` and the second column width will be calculated automatically
7979because of the ``0 `` value. The output of this command will be:
8080
81- .. code-block :: text
81+ .. code-block :: terminal
8282
8383 +---------------+--------------------------+--------------------------------+
8484 | ISBN | Title | Author |
@@ -117,7 +117,7 @@ The table style can be changed to any built-in styles via
117117
118118This code results in:
119119
120- .. code-block :: text
120+ .. code-block :: terminal
121121
122122 ISBN Title Author
123123 99921-58-10-7 Divine Comedy Dante Alighieri
@@ -132,7 +132,7 @@ You can also set the style to ``borderless``::
132132
133133which outputs:
134134
135- .. code-block :: text
135+ .. code-block :: terminal
136136
137137 =============== ========================== ==================
138138 ISBN Title Author
@@ -259,7 +259,7 @@ To make a table cell that spans multiple columns you can use a :class:`Symfony\\
259259
260260This results in:
261261
262- .. code-block :: text
262+ .. code-block :: terminal
263263
264264 +---------------+---------------+-----------------+
265265 | ISBN | Title | Author |
@@ -282,7 +282,7 @@ This results in:
282282
283283 This generates:
284284
285- .. code-block :: text
285+ .. code-block :: terminal
286286
287287 +-------+-------+--------+
288288 | Main table title |
@@ -313,7 +313,7 @@ In a similar way you can span multiple rows::
313313
314314This outputs:
315315
316- .. code-block :: text
316+ .. code-block :: terminal
317317
318318 +----------------+---------------+---------------------+
319319 | ISBN | Title | Author |
0 commit comments