DokuWiki

It's better when it's simple

ユーザ用ツール

サイト用ツール


ja:devel:syntax_plugins

差分

このページの2つのバージョン間の差分を表示します。

この比較画面へのリンク

両方とも前のリビジョン前のリビジョン
次のリビジョン
前のリビジョン
最新のリビジョン両方とも次のリビジョン
ja:devel:syntax_plugins [2009-12-21 10:16] 130.158.152.134ja:devel:syntax_plugins [2009-12-23 09:34] wakuteka
行 1: 行 1:
 ====== Syntax Plugins ====== ====== Syntax Plugins ======
  
-構文プラグインはDokuwikiの構文を拡張する為の[[:ja:plugins]]です。新しい構文をDokuwikiに登録するために何が必要かはを理解するには[[Parser]]の処理を理解してください。+構文プラグインはDokuwikiの構文を拡張する為の[[:ja:plugins]]です。新しい構文をDokuwikiに登録するために何が必要かはを理解するには[[devel:Parser]]の処理を理解してください。
  
 自作の構文プラグインの為の詳細な情報は[[Syntax Plugins|syntax_tutorial]]を参照してください。 自作の構文プラグインの為の詳細な情報は[[Syntax Plugins|syntax_tutorial]]を参照してください。
行 13: 行 13:
   * **''getInfo()''** プラグイン情報のハッシュを返す。 [author, email, date, name, desc, url]   * **''getInfo()''** プラグイン情報のハッシュを返す。 [author, email, date, name, desc, url]
   * **''getType()''** このプラグインのsyntax typeを返す。 ([[#syntax_types|see below]])   * **''getType()''** このプラグインのsyntax typeを返す。 ([[#syntax_types|see below]])
-  * **''getSort()''** Returns a number used to determine in which order modes are added, also see [[parser#order_of_adding_modes_important|parser, order of adding modes]]+  * **''getSort()''** Returns a number used to determine in which order modes are added, also see [[parser#order_of_adding_modes_important|parser, order of adding modes]] and [[parser:getSort list]]
   * **''connectTo($mode)''** Doku_Parser_Modeを継承したメソッド ((''inc/parser/parser.php''で定義されています)). あなたの自作構文にマッチする正規表現はここで登録してください。   * **''connectTo($mode)''** Doku_Parser_Modeを継承したメソッド ((''inc/parser/parser.php''で定義されています)). あなたの自作構文にマッチする正規表現はここで登録してください。
   * **''handle($match, $state, $pos, &$handler)''** rendererメソッドでマッチした構文を使うための準備処理。   * **''handle($match, $state, $pos, &$handler)''** rendererメソッドでマッチした構文を使うための準備処理。
行 282: 行 282:
 And that's our plugin finished. And that's our plugin finished.
  
-<code php>+<code php syntax.php>
 <?php <?php
 /** /**
行 350: 行 350:
 Again, all fairly straightforward - and here it is. Again, all fairly straightforward - and here it is.
  
-<code php>+<code php syntax.php>
 <?php <?php
 /** /**
行 470: 行 470:
  
 So I need to detect the head tag "<color" "</color" "<box" "</box" in the method "render($mode, &$renderer, $data)" to be able to generate different results. So I need to detect the head tag "<color" "</color" "<box" "</box" in the method "render($mode, &$renderer, $data)" to be able to generate different results.
-How I find out in "render" if "color" or "box" is used :?:+How I find out in "render" if "color" or "box" is used :?:G
ja/devel/syntax_plugins.txt · 最終更新: 2023-08-17 19:29 by Klap-in

特に明示されていない限り、本Wikiの内容は次のライセンスに従います: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki