Skip to content

Commit

Permalink
parsing / formatting tokens table & styling
Browse files Browse the repository at this point in the history
  • Loading branch information
crsmithdev committed Oct 13, 2013
1 parent 0b20afd commit bc89baa
Show file tree
Hide file tree
Showing 2 changed files with 90 additions and 0 deletions.
22 changes: 22 additions & 0 deletions docs/_themes/f6/static/f6.css
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,28 @@ table {
margin: 0 -0.5em 0 -0.5em;
}

table.docutils {
width: 100% !important;
margin-left: 2px;
border: 0;
}

table.docutils tbody tr td {
padding-top: 5px;
padding-bottom: 5px;
border: 0;
}

table.docutils thead tr th {
padding-top: 5px;
padding-bottom: 5px;
border: 0;
}

.row-even {
background-color: #F0F0F0;
}

table td, table th {
padding: 0.2em 0.5em 0.2em 0.5em;
}
Expand Down
68 changes: 68 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -361,6 +361,74 @@ Then get and use a factory for it:
>>> custom.days_till_xmas()
>>> 211
Tokens
======

Use the following tokens in parsing and formatting:

+--------------------------------+--------------+-------------------------------------------+
| |Token |Output |
+================================+==============+===========================================+
|**Year** |YYYY |2000, 2001, 2002 ... 2012, 2013 |
+--------------------------------+--------------+-------------------------------------------+
| |YY |00, 01, 02 ... 12, 13 |
+--------------------------------+--------------+-------------------------------------------+
|**Month** |MMMM |January, Febuary, March ... |
+--------------------------------+--------------+-------------------------------------------+
| |MMM |Jan, Feb, Mar ... |
+--------------------------------+--------------+-------------------------------------------+
| |MM |01, 02, 03 ... 11, 12 |
+--------------------------------+--------------+-------------------------------------------+
| |M |1, 2, 3 ... 11, 12 |
+--------------------------------+--------------+-------------------------------------------+
|**Day of Year** |DDDD |001, 002, 003 ... 364, 365 |
+--------------------------------+--------------+-------------------------------------------+
| |DDD |1, 2, 3 ... 4, 5 |
+--------------------------------+--------------+-------------------------------------------+
|**Day of Month** |DD |01, 02, 03 ... 30, 31 |
+--------------------------------+--------------+-------------------------------------------+
| |D |1, 2, 3 ... 30, 31 |
+--------------------------------+--------------+-------------------------------------------+
|**Day of Month** |dddd |Monday, Tuesday, Wednesday ... |
+--------------------------------+--------------+-------------------------------------------+
| |ddd |Mon, Tue, Wed ... |
+--------------------------------+--------------+-------------------------------------------+
| |d |1, 2, 3 ... 6, 7 |
+--------------------------------+--------------+-------------------------------------------+
|**Hour** |HH |00, 01, 02 ... 23, 24 |
+--------------------------------+--------------+-------------------------------------------+
| |H |0, 1, 2 ... 23, 24 |
+--------------------------------+--------------+-------------------------------------------+
| |hh |01, 02, 03 ... 11, 12 |
+--------------------------------+--------------+-------------------------------------------+
| |h |1, 2, 3 ... 11, 12 |
+--------------------------------+--------------+-------------------------------------------+
|**AM / PM** |A |AM, PM |
+--------------------------------+--------------+-------------------------------------------+
| |a |am, pm |
+--------------------------------+--------------+-------------------------------------------+
|**Minute** |mm |00, 01, 02 ... 58, 59 |
+--------------------------------+--------------+-------------------------------------------+
| |m |0, 1, 2 ... 58, 59 |
+--------------------------------+--------------+-------------------------------------------+
|**Second** |ss |00, 01, 02 ... 58, 59 |
+--------------------------------+--------------+-------------------------------------------+
| |s |0, 1, 2 ... 58, 59 |
+--------------------------------+--------------+-------------------------------------------+
|**Sub-second** |SSS |0, 1, 2 ... 8, 9 |
+--------------------------------+--------------+-------------------------------------------+
| |SS |0, 1, 2 ... 98, 99 |
+--------------------------------+--------------+-------------------------------------------+
| |S |0, 1, 2 ... 998, 999 |
+--------------------------------+--------------+-------------------------------------------+
|**Timezone** |ZZ |-07:00, -06:00 ... +06:00, +07:00 |
+--------------------------------+--------------+-------------------------------------------+
| |Z |-0700, -0600 ... +0600, +0700 |
+--------------------------------+--------------+-------------------------------------------+
|**Timestamp** |X |1381685817 |
+--------------------------------+--------------+-------------------------------------------+


---------
API Guide
---------
Expand Down

0 comments on commit bc89baa

Please sign in to comment.