Help:目录
来自RPG Maker 编年史
目录 |
讨论
有必要科普一下维基讨论的格式。
- 每个页面最上面都有一个讨论页,对没错编辑它就可以了。
- 右上角有“编辑”和“添加话题”两个按钮,一般编辑用不到,只要选择添加话题,然后一句话概括一下,下面写正文,比如质疑什么的。
- 回复已有内容的时候,点那个话题的编辑,在那个段落下面后面换行,缩进然后写东西。
- 总的来说要记得签名。
- 例子看Help_talk:目录。
语法高亮
插件用的是 Extension:SyntaxHighlight_GeSHi - MediaWiki。
用法
你看,在页面里用“source”标签:
<source lang="php"> <?php $v = "string"; // sample initialization ?> html text <? echo $v; // end of php code ?> </source>
得到
<?php $v = "string"; // sample initialization ?> html text <? echo $v; // end of php code ?>
<source>
也许在某些代码中使用了。您可以用 <syntaxhighlight>
。
参数
-
lang="??"
-
line="GESHI_NORMAL_LINE_NUMBERS|GESHI_FANCY_LINE_NUMBERS"
- Type of line numbering to use. If you do not provide this parameter, then lines will not be numbered. Corresponds to enable_line_numbers the flag in GeSHi.
-
line start="??"
- Use together with the parameter "line". Define the start number of the line. If you type line start="55", it will start counting at 55, then 56,57,58... and so on. Corresponds to start_line_numbers_at method on GeSHi
-
highlight="??"
- Specifies which line is highlighted. Note that the parameter line start="??" doesn't affect how it counts the lines.
-
enclose="??"
- Specifies what container is used to enclose the source code. Takes values "pre" (default value), "div", "none". Corresponds to set_header_type method on GeSHi. Choosing "div" will cause text to wrap, which is helpful if text is extending off the edge of the screen, causing horizontal scrolling.
-
strict
- Type the name of the parameter to enable the strict mode. Corresponds to enable_strict_mode method on GeSHi.
More Usage
When line numbering is added with line, long code lines will be wrapped. See the example below. When text is the selected language, and numbering is used, the behaviour resembles the use of pre tags with numbering and long-line wrapping.
The following example shows how to color an HTML code listing:
<syntaxhighlight lang="html4strict" line start="100" highlight="5" enclose="div"> HTML module goes here... </syntaxhighlight>
A typical result is just:
<!--This is a comment. Comments are not displayed in the browser--> <table align=center style="background: ivory;color:maroon;font-style:italic;font-family:arial;font-weight:bold;font-size:10pt;"> <tr><th> Heading 1 </th><th> Heading 2 </th></tr> <tr> <td style="padding:10px;"> This is cell 1 text </td> <td style="padding:10px;"> This is cell 2 text </td> </tr> </table>