Difference between revisions of "User:Esteis/Cheat sheet"

From Wiki
Jump to navigation Jump to search
(Add table example)
m
 
Line 28: Line 28:
  
 
== Tables ==
 
== Tables ==
A table with
+
A table that 
* top-aligned cell entries
+
* floats to the right
* left-aligned headers   
+
* has top-aligned cell entries
* nice borders
+
* has left-aligned headers   
* alternating row colors
+
* has nice borders.
  
 
There is no way to apply styles to columns, alas.
 
There is no way to apply styles to columns, alas.
  
<pre>
+
{| align="right" class="wikitable"
{| align=right" class="zebra wikitable"
+
|-  
|- style="text-align: left"
+
! style="text-align: left" | Header 1
! Header 1
+
! style="text-align: left" | Header 2
! Header 2
+
|- style="vertical-align: top"
 +
| Short entry
 +
| This is a rather wide <br /> multi-line entry
 
|- style="vertical-align: top"
 
|- style="vertical-align: top"
 
| Short entry
 
| Short entry
Line 46: Line 48:
 
|-  
 
|-  
 
|}
 
|}
</pre>
 
  
{| align=right" class="zebra wikitable"
+
<pre>
|- style="text-align: left"
+
{| align="right" class="wikitable"
! Header 1
+
|-  
! Header 2
+
! style="text-align: left" | Header 1
 +
! style="text-align: left" | Header 2
 +
|- style="vertical-align: top"
 +
| Short entry
 +
| This is a rather wide <br /> multi-line entry
 
|- style="vertical-align: top"
 
|- style="vertical-align: top"
 
| Short entry
 
| Short entry
Line 57: Line 62:
 
|-  
 
|-  
 
|}
 
|}
 +
</pre>

Latest revision as of 14:36, 31 May 2012

ConTeXt-related stuff

Categorize a command [[Category:Commands/subcat|the_command]]
Link directly to a category page: [[:Category:Commands/subcat|Subcat]]
Linkify a command (template) {{cmd|the_command}}
Linkify a command (tags) (deprecated) <cmd>the_command</cmd>
Syntax-highlighted code (not run) <texcode>...</texcode>
Syntax-highlighted code +

text in between + result

<context source="yes" text="bla">...</context>
To run the code as mkiv <context mode=mkiv>...</context>

To linkify a command you should use the the template form, because the tags don't create a working link.

Tables

A table that

  • floats to the right
  • has top-aligned cell entries
  • has left-aligned headers
  • has nice borders.

There is no way to apply styles to columns, alas.

Header 1 Header 2
Short entry This is a rather wide
multi-line entry
Short entry This is a rather wide
multi-line entry
{| align="right" class="wikitable"
|- 
! style="text-align: left" | Header 1
! style="text-align: left" | Header 2
|- style="vertical-align: top"
| Short entry
| This is a rather wide <br /> multi-line entry
|- style="vertical-align: top"
| Short entry
| This is a rather wide <br /> multi-line entry
|- 
|}