|
|
(30 versions intermédiaires par le même utilisateur non affichées) |
Ligne 1 : |
Ligne 1 : |
| = Text formatting markup =
| | page has been moved to [[:en:User:LMischler/EIG-wiki-syntax-2016|english wiki]] |
| | |
| {| class="wikitable"
| |
| ! Description !! You type !! You get
| |
| |-
| |
| | colspan="3" {{Table_HC1}} | '''Character (inline) formatting – ''applies anywhere'''''
| |
| |-
| |
| |Italic text
| |
| | <code><nowiki>''italic''</nowiki></code>
| |
| |''italic''
| |
| |-
| |
| | Bold text
| |
| | <code><nowiki>'''bold'''</nowiki></code>
| |
| |'''bold'''
| |
| |-
| |
| | Bold and italic
| |
| | <code><nowiki>'''''bold & italic'''''</nowiki></code>
| |
| |'''''bold & italic'''''
| |
| |-
| |
| |Escape wiki markup
| |
| | <code><nowiki><nowiki>no ''markup''</nowiki></nowiki></code>
| |
| |<nowiki>no ''markup''</nowiki>
| |
| |-
| |
| | colspan="3" {{Table_HC1}} | '''Section formatting – ''only at the beginning of the line'''''
| |
| |-
| |
| |Headings of different levels
| |
| | <pre>=level 1=
| |
| ==level 2==
| |
| ===level 3===
| |
| ====level 4====
| |
| =====level 5=====
| |
| ======level 6======</pre>
| |
| An article with 4 or more headings automatically creates a [[wikipedia:Wikipedia:Section#Table of contents (TOC)|table of contents]].
| |
| | |
| |<!-- hack to prevent TOC viewing for h1 - h6 elements: their style is hardcopied here -->
| |
| <div style="font-size: 188%; margin: 0; padding-top: .5em; padding-bottom: .17em; border-bottom: 1px solid #aaa">Level 1</div>
| |
| <div style="font-size: 150%; margin: 0; padding-top: .5em; padding-bottom: .17em; border-bottom: 1px solid #aaa">Level 2</div>
| |
| <div style="font-size: 132%; font-weight: bold">Level 3</div><!--
| |
| --><b>Level 4</b><!--
| |
| --><div style="font-size: 86%; font-weight: bold">Level 5</div><!--
| |
| --><b style="font-size: 80%">Level 6</b>
| |
| |-
| |
| |Horizontal rule
| |
| | <code>----</code>
| |
| |
| |
| ----
| |
| |-
| |
| |Bullet list
| |
| |
| |
| <pre>
| |
| * one
| |
| * two
| |
| * three
| |
| ** three point one
| |
| ** three point two
| |
| </pre>
| |
| Inserting a blank line will end the first list and start another.
| |
| |
| |
| * one
| |
| * two
| |
| * three
| |
| ** three point one
| |
| ** three point two
| |
| |-
| |
| | indent text
| |
| |
| |
| <pre>: Single indent
| |
| :: Double indent
| |
| ::::: Multiple indent</pre>
| |
| This workaround may be controversial from the viewpoint of accessibility.
| |
| |
| |
| : Single indent
| |
| :: Double indent
| |
| ::::: Multiple indent
| |
| |}
| |
| | |
| | |
| = Paragraphs =
| |
| | |
| MediaWiki ignores single line breaks. To start a new paragraph, leave an empty line. You can force a line break within a paragraph with the HTML tags <code><br /></code>.
| |
| | |
| | |
| = Titles, sub-titles ... =
| |
| | |
| The wiki page title (defined when creating a page) is using the first title level (h1)
| |
| | |
| So when the book content to migrate includes "paragraphs", "sub-paragraphs" ... their titles should use wiki syntax for level 2 (== title ==), level 3 (=== sub-paragraph ===) etc
| |
| | |
| | |
| = bullet lists - details =
| |
| | |
| {| class="wikitable"
| |
| |-
| |
| |Bullet list
| |
| |
| |
| <pre>
| |
| * one
| |
| * two
| |
| ** two point one
| |
| ** two point two
| |
| * three<p>continued</p>
| |
| ** three point one
| |
| * four<!--
| |
| --><p>continued with "nicer" source (visually closer to actual page result)</p><!--
| |
| --><p>several continued sentences is possible</p><!--
| |
| --><p>can also be used for an image that is part of bullet point</p><!--
| |
| --><p>[[File:Blogs icon.png|none]]</p>
| |
| ** four point one
| |
| </pre>
| |
| Inserting a blank line will end the first list and start another.
| |
| | |
| nota: there is a small bug with wiki CSS, so inside tables following text does not have proper font size ==> not a problem as should never happen in tables
| |
| |
| |
| * one
| |
| * two
| |
| ** two point one
| |
| ** two point two
| |
| * three<p>continued</p>
| |
| ** three point one
| |
| * four<!--
| |
| --><p>continued with "nicer" source (visually closer to actual page result)</p><!--
| |
| --><p>several continued sentences is possible</p><!--
| |
| --><p>can also be used for an image that is part of bullet point</p><!--
| |
| --><p>[[File:Blogs icon.png|none]]</p>
| |
| ** four point one
| |
| |}
| |
| | |
| '''It is not recommended to have more than 2 nested levels of bullet lists'''.
| |
| | |
| If there are more than 2 bullet list levels (maybe sometimes also for 2 levels), it is recommended to change the first level of bullet list to a sub-paragraph level
| |
| | |
| | |
| = Manual TOCs (table of contents) =
| |
| | |
| These small manual TOCs are used in "introductory pages", eg pages with a short text introduction (or not), followed by this small manual TOC = links to pages included in this "section"
| |
| | |
| syntax:
| |
| | |
| <nowiki>{{Manual_TOC |
| |
| * [[General method for cable sizing|General method for cable sizing]]
| |
| * [[Recommended simplified approach for cable sizing|Recommended simplified approach for cable sizing]]
| |
| * [[Sizing of busbar trunking systems (busways)|Sizing of busbar trunking systems (busways)]]
| |
| }}</nowiki>
| |
| | |
| example:
| |
| {{Manual_TOC |
| |
| * [[General method for cable sizing|General method for cable sizing]]
| |
| * [[Recommended simplified approach for cable sizing|Recommended simplified approach for cable sizing]]
| |
| * [[Sizing of busbar trunking systems (busways)|Sizing of busbar trunking systems (busways)]]
| |
| }}
| |
| | |
| | |
| = Images =
| |
| The syntax is now using templates, to facilitate and standardize the formating, as shown below
| |
| | |
| | |
| == Image = ONE FIGURE ==
| |
| | |
| <nowiki>{{FigImage|<fig-ID>|<fig-extension>|<fig-num>|<fig-title>}}</nowiki>
| |
|
| |
| example:
| |
|
| |
| <nowiki>{{FigImage|DB422002|svg|A11|Application du facteur de simultanéité (ks) à un immeuble de 4 étages + rez-de-chaussée (correspondant à la norme NF C 14-100)}}</nowiki>
| |
| | |
| where:
| |
| * '''<fig-ID>''' is like: DB422001 (= image file name, without the file extension)
| |
| * '''<fig-extension>''' is like: svg, jpg ...
| |
| * '''<fig-num>''' is like: A11, B42a ...
| |
| * '''<fig-title>''' is like: Application of the diversity factor (ks) to an apartment block of 5 storeys
| |
| | |
| result:
| |
| {{FigImage|DB422002|svg|A11|Application du facteur de simultanéité (ks) à un immeuble de 4 étages + rez-de-chaussée (correspondant à la norme NF C 14-100)}}
| |
| | |
| | |
| nota: '''<fig-title>''' normally is just text, and does not include any formatting, unless it is required, like to add a link inside the title. Example:
| |
| <nowiki>{{FigImage|<fig-ID>|<fig-extension>|A11|Circuit-breaker type <nowiki>'''[http://www.xxxxxxx Masterpact]'''</nowiki> from Schneider-Electric}}</nowiki>
| |
| | |
| | |
| == Image = ONE FIGURE with NOTES ==
| |
| | |
| <nowiki>{{FigImage|<fig-ID>|<fig-extension>|<fig-num>|<fig-title>|
| |
| add figure notes here ...<br>
| |
| ... more
| |
| }}</nowiki>
| |
|
| |
| example:
| |
| <nowiki>{{ FigImage|DB422002|svg|A11|Application du facteur de simultanéité (ks) à un immeuble de 4 étages + rez-de-chaussée (correspondant à la norme NF C 14-100)|
| |
| add figure notes here ...<br>
| |
| ... more
| |
| }}</nowiki>
| |
| | |
| | |
| Giving:
| |
| {{ FigImage|DB422002|svg|A11|Application du facteur de simultanéité (ks) à un immeuble de 4 étages + rez-de-chaussée (correspondant à la norme NF C 14-100)|
| |
| add figure notes here ...<br>
| |
| ... more
| |
| }}
| |
| | |
| | |
| == Image without frame and title ==
| |
| | |
| Syntax is very simple here:
| |
| <nowiki>[[File:<image-name-with-extension>]]
| |
|
| |
| example: |[[File:Pen-icon.png]]</nowiki>
| |
| | |
| Giving for exemple, if integrated in a small table:
| |
| {| class="wikitable"
| |
| |-
| |
| ! table header
| |
| ! header 2
| |
| |-
| |
| |[[File:Pen-icon.png]]
| |
| | This icon is a pen icon
| |
| |}
| |
| | |
| | |
| = Gallery of images =
| |
| | |
| | |
| '''''to be completed'''''
| |
| | |
| | |
| = Table =
| |
| | |
| | |
| == Tables without notes ==
| |
| | |
| The final syntax to use requires to REPLACE the usual starting and ending syntax of tables by specific templates with proper parameters:
| |
| | |
| <nowiki>{{TableStart|<table-ID>|<cols-in-book>}} IMPORTANT: This line is REPLACING the usual table starting syntax: {| class="wikitable"
| |
| ... table syntax as usual here ...
| |
| ... continued ...
| |
| {{TableEnd|<table-ID>|<fig-num>|<table-title>}} IMPORTANT: This line is REPLACING the usual table ending syntax: |}</nowiki>
| |
|
| |
| where:
| |
| <nowiki><table-ID> = table ID (Tab1001)</nowiki>
| |
| <cols-in-book> = 1col 2col 3col 4col or 5col, according to nr of "book columns" required for the table width in the book
| |
| <fig-num> = figure number (A5)
| |
| | |
| Example:
| |
| <nowiki>{{TableStart|Tab1001|2col}}</nowiki>
| |
| |-
| |
| ! header
| |
| ! header
| |
| |-
| |
| | the table syntax is as usual
| |
| | the rest is as usual I believe
| |
| |-
| |
| | another cell
| |
| <nowiki>{{TableEnd|Tab1001|A5|This is my table title}}</nowiki>
| |
| | |
| Result:
| |
| | |
| {{TableStart|Tab1001|2col}}
| |
| |-
| |
| ! header
| |
| ! header
| |
| |-
| |
| | the table syntax is as usual
| |
| | the rest is as usual I believe
| |
| |-
| |
| | another cell
| |
| {{TableEnd|Tab1001|A5|This is my table title}}
| |
| | |
| Nota: for a table WITHOUT TITLE:
| |
| <nowiki>{{TableStart|<table-ID>|<cols-in-book>}}</nowiki>
| |
| ... table syntax as usual here ...
| |
| ... continued ...
| |
| <nowiki>{{TableEnd}}</nowiki>
| |
| | |
| == Tables with TEXT-ONLY table notes ==
| |
| | |
| Syntax: the table start is the same, the table end similar but extended with the table notes
| |
| | |
| <nowiki>{{TableStart|<table-ID>|<cols-in-book>}}</nowiki>
| |
| ... table syntax as usual here ...
| |
| ... continued ...
| |
| <nowiki>{{TableEnd|<table-ID>|<fig-num>|<table-title></nowiki>
| |
| || The text of my note here. It can be long with several sentences. Do not use "br" in this text
| |
| <nowiki>|| ... do like this to continue text on a new line}}</nowiki>
| |
| | |
| Example:
| |
|
| |
| <nowiki>{{TableStart|Tab1002|2col}}</nowiki>
| |
| |-
| |
| ! header
| |
| ! header
| |
| |-
| |
| | the table syntax is as usual
| |
| | the rest is as usual I believe
| |
| |-
| |
| | another cell
| |
| <nowiki>{{TableEnd|Tab1002|A6|This is my table title</nowiki>
| |
| || The text of my note here. It can be long with several sentences. Do not use "br" in this text
| |
| <nowiki>|| ... do like this to continue text on a new line}}</nowiki>
| |
| | |
| Result:
| |
| {{TableStart|Tab1002|2col}}
| |
| |-
| |
| ! header
| |
| ! header
| |
| |-
| |
| | the table syntax is as usual
| |
| | the rest is as usual I believe
| |
| |-
| |
| | another cell
| |
| {{TableEnd|Tab1002|A6|This is my table title
| |
| || The text of my note here. It can be long with several sentences. Do not use "br" in this text
| |
| || ... do like this to continue text on a new line}}
| |
| | |
| | |
| == Tables with REFERENCES and table notes ==
| |
| | |
| This is for reference inside a table, like this in the book: 3.3<sup>(1)</sup>. These references in the book use numbers (1, 2, 3 ...) which have to be changed to small capital letters in the wiki: a, b, c, d ... to differentiate the table notes (added just after the table) from the footnotes (added at the end of the page).
| |
| | |
| Syntax to add a reference in the content of the table:
| |
| <nowiki>{{ TabRef | <table-ID> | <ref-letter> }} Example: {{TabRef|Tab1001|a}} to add a ref looking like: [a]</nowiki>
| |
| | |
| | |
| Complete example:
| |
|
| |
| <nowiki>{{TableStart|Tab1003|2col}}</nowiki>
| |
| |-
| |
| ! header
| |
| ! header
| |
| |-
| |
| | the table syntax is as usual
| |
| | the rest is as usual I believe
| |
| |-
| |
| | another cell
| |
| <nowiki>{{TableEnd|Tab1003|A7|This is my table title</nowiki>
| |
| |a|this is the text of my note a
| |
| |b|this is now the much longer text which is not a problem, for note b
| |
| || I can also mix with text only table notes. Don't forget to put the 2 <nowiki>||</nowiki> at the beginning<nowiki>}}</nowiki>
| |
| | |
| Result:
| |
| {{TableStart|Tab1003|2col}}
| |
| |-
| |
| ! header
| |
| ! header
| |
| |-
| |
| | here a cell with a ref{{TabRef|Tab1003|a}}
| |
| | the rest is as usual I believe
| |
| |-
| |
| | and another ref{{TabRef|Tab1003|b}}
| |
| {{TableEnd|Tab1003|A7|This is my table title
| |
| |a|this is the text of my note a
| |
| |b|this is now the much longer text which is not a problem, for note b
| |
| || I can also mix with text only table notes. Don't forget to put the 2 <nowiki>||</nowiki> at the beginning}}
| |
| | |
| = Footnotes =
| |
| | |
| '''''to be completed'''''
| |
| | |
| | |
| = Math formulas =
| |
| | |
| '''''to be completed'''''
| |
| | |
| | |
| == Special characters ==
| |
| | |
| Important: the following symbols are '''reserved characters''' that either have a special meaning under LaTeX or are unavailable in all the fonts. If you enter them directly in your text, they will normally not render, but rather do things you did not intend.
| |
| | |
| Important in particular for the % sign, which is used in some formulas (it works in the wiki, but then does not work during PDF exportation)
| |
| | |
| # $ % ^ & _ { } ~ \
| |
| | |
| These characters can be entered by adding a prefix backslash:
| |
| | |
| \# \$ \% \textasciicircum{} \& \_ \{ \} \~{} \textbackslash{}
| |
| | |
| = Specific French contents =
| |
| | |
| | |
| == Just for a small text ==
| |
| | |
| <nowiki>{{FR-specific-text|<this is the specific text>}}</nowiki>
| |
| | |
| {{FR-specific-text|this is the specific text}}
| |
| | |
| | |
| == For a long specific section ==
| |
| | |
| <nowiki>{{FR-specific-section-start}}</nowiki>
| |
| this is the migrated content wich is french specific ...
| |
| ... use usual syntax for wiki contents ...
| |
| ....
| |
| ....
| |
| <nowiki>{{FR-specific-section-end}}</nowiki>
| |
| | |
| | |
| {{FR-specific-section-start}}
| |
| this is the migrated content wich is french specific ...<br>
| |
| ... use usual syntax for wiki contents ...<br>
| |
| ....<br>
| |
| ....
| |
| {{FR-specific-section-end}}
| |
| | |
| | |
| This formatting is not 100% validated, see other tests here: [[Utilisateur:LMischler/TestFRSpecificFormats]]
| |
| '''NOTA: also need to fully validate the syntax, depending on final format chosen. For math formulas in particular, it will be a problem if we want to use a non-white background color in the FR-specific section
| |