Last modified: 2011-03-13 18:06:17 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T12121, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 10121 - Just wanted to add a feature to MediaWiki, which will allow Roman Numerals in OL tags.
Just wanted to add a feature to MediaWiki, which will allow Roman Numerals in...
Status: RESOLVED WONTFIX
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
1.11.x
All All
: Lowest enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
: patch, patch-need-review
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-06-03 15:08 UTC by Chris Simmons
Modified: 2011-03-13 18:06 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Chris Simmons 2007-06-03 15:08:09 UTC
This change allows to use the ! exclamation mark to produce Roman Numeral style Ordered Lists. Placing a ! in the first character position of any line, with a space immediately after it, will produce i, ii, iii, iv and so forth instead of 1, 2, 3, 4, and so forth.

includes/Parser.php

Line 2002
Added:
else if ('!' == $char ) { $result .= '<ol class=roman><li>'; }

Line 2015
From:
if ( '*' == $char || '#' == $char ) { return '</li><li>'; }

To:
if ( '*' == $char || '#' == $char || '!' == $char) { return '</li><li>'; }

Line 2032
From:
else if ( '#' == $char ) { $text = '</li></ol>'; }

To:
else if ( '#' == $char || '!' == $char) { $text = '</li></ol>'; }

Line 2076
From:
$prefixLength = strspn( $oLine, '*#:;' );

To:
$prefixLength = strspn( $oLine, '*#:;!' );


In the CSS sheet being used, add the following line:

ol.roman { list-style-type: upper-roman; }
Comment 1 Aryeh Gregor (not reading bugmail, please e-mail directly) 2007-06-03 19:31:48 UTC
It would make more sense to have a generalized format for this, if anything (what about lower-roman, uppercase and lowercase letters, non-English conventions, ...?).  See bug 6539.  Since that was viewed as an unacceptable increase in wikitext complexity, probably this is too.
Comment 2 Brion Vibber 2007-06-04 19:37:37 UTC
Wiki formatting is meant to be simple for simple cases.

If the many many many additional possibilites of formatting are required, you can use the limited HTML subset for this (eg, with an <ol>)

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links