xref: /dokuwiki/inc/Parsing/ParserMode/Emphasis.php (revision dba14ea3c4253d454e478f27d0ae9c47d2fa7aa6)
1<?php
2
3namespace dokuwiki\Parsing\ParserMode;
4
5class Emphasis extends AbstractFormatting
6{
7    /** @inheritdoc */
8    protected function getModeName(): string
9    {
10        return 'emphasis';
11    }
12
13    /**
14     * @inheritdoc
15     * @see https://github.com/dokuwiki/dokuwiki/issues/384
16     * @see https://github.com/dokuwiki/dokuwiki/issues/763
17     * @see https://github.com/dokuwiki/dokuwiki/issues/1468
18     */
19    protected function getEntryPattern(): string
20    {
21        return '//(?=[^\x00]*[^:])';
22    }
23
24    /** @inheritdoc */
25    protected function getExitPattern(): string
26    {
27        return '//';
28    }
29
30    /** @inheritdoc */
31    public function getSort()
32    {
33        return 80;
34    }
35}
36