Commit Graph

37 Commits

Author SHA1 Message Date
Alex Schroeder
58e9a1e240 use v5.10 everywhere + enabled test in meta.t 2015-08-18 10:48:03 +02:00
Aleks-Daniel Jakimenko
df87ff82c3 No more redundant 'package OddMuse;' 2015-04-27 17:41:59 +03:00
Aleks-Daniel Jakimenko
c7bd5617ff No more trailing whitespace 2015-04-17 01:39:47 +03:00
Aleks-Daniel Jakimenko
6f8d281d79 No more "use vars"! 2015-04-10 13:31:28 +03:00
Aleks-Daniel Jakimenko
4492ede096 "use strict;" in modules (some modules have problems) 2015-03-27 03:01:01 +02:00
Aleks-Daniel Jakimenko
62c7553d82 'return undef' changed to 'return'
This command was used:
find . -type f -print0 | xargs -0 sed -i 's/return undef/return/g'

The idea behind this commit is described on http://oddmuse.org/wiki/Refactoring page.
In short: 'return undef' returns (undef) in list context (a list with one element),
which is wrong.
2015-02-27 12:10:18 +02:00
Alex Schroeder
5aba2ae56f Fixed typo in AddModuleDescription sub name 2014-08-21 22:23:23 +02:00
Alex Jakimenko
ee932dee37 Automatically reformatted modules 2014-08-21 07:29:46 +03:00
Alex Schroeder
f11e2a8731 getting rid of $Id$ tags in $WikiDescription
Replaced the $Id$ tags in $WikiDescription for all the modules and wiki.pl itself with a link to the source and an appropriate wiki page, if possible. This is shown in action=version and should help users figure out what another wiki has installed.
2012-04-19 02:18:45 +02:00
Alex Schroeder
c592f6fb6a ($CreoleAdditionIndentedParagraphs):
New option.
(CreoleAdditionRule): Implement indented paragraphs rule.
2009-03-02 17:54:20 +00:00
Weakish Jiang
c2680f103e Use simple pattern match of dl. Actually a rollback to the dl pattern match in r1.14. Fixed the bug reported by bib. 2009-02-11 18:14:17 +00:00
Weakish Jiang
fd0ff5a59e Now multi urls within dt also work.
I'm wondering the usage of [^:] in the pattern matching.  Unlike mediawiki,
we don't allow dt and dd in the same line, thus maybe [^:] is not necessary.
2009-02-11 17:48:51 +00:00
Weakish Jiang
c6ab3e8317 t/creoleaddition.t: test for http://xxx in dt in definition list 2009-02-11 17:25:35 +00:00
Brian Curry
609cb49f86 * wiki.pl (PrintWikiToHTML): Slightly reordered function calls,
so as to optimize a few edge cases.
2008-11-16 01:00:04 +00:00
Brian Curry
52a47946a6 * wiki.pl (RegisterBlockLevelElement): Renamed to
SetHtmlEnvironmentContainer (and changed in every other module,
where called).
2008-11-15 21:24:32 +00:00
Brian Curry
7cfe623133 * wiki.pl (AddHtmlEnvironment): Corrected a minor regression.
Probably not a genuine issue... but one can never tell.
* modules/creole.pl (CloseHtmlEnvironmentsCreole): Removed.
* modules/creoleaddition.pl (CloseHtmlEnvironmentsCreoleAddition):
Removed.
* modules/poetry.pl (CloseHtmlEnvironmentsPoetry): Removed.
2008-11-15 12:53:25 +00:00
Brian Curry
0b38a69cd0 * modules/creole.pl (CreoleRule): Simplified implementation and
integrated with improvements to CreoleHeaderRule().
(CreoleHeaderRule): Improved -- remarkably. Header markup may now
include all other (non-bol) markup, with exception of link markup
producing a dirty HTML block. ("Dirty" link markup in header
markup is stripped out, as appropriate.)
(CreoleListAndNewlineRule): Simplified implementation.
(CreoleRuleRecursive): Supported the global @HtmlAttrStack.
(GetCreoleLinkHtml): New function, reducing code-bloat.
* modules/creoleaddition.pl (CreoleAdditionRule): Simplified
implementation; and handled small caps markup properly, now.
2008-11-06 10:11:02 +00:00
Brian Curry
f583456681 * wiki.pl (ApplyRules): Ensure the regular expression match
position returns the length of the matched string on finishing
application of all rules. ("creole.pl" and "creoleaddition.pl" now
depend on this; it notifies them that rules are now finished.)
* modules/creoleaddition.pl (CreoleAdditionRule): Injected a sanity
check, to ensure closure of blockquotes at the end of a page.
* modules/creole.pl ($CreoleTableCellsAllowBlockLevelElements): New
option.
* modules/creole.pl (CreoleRule): The last, one hopes, of all Creole
table markup modifications (for the moment). The rather complex
table markup code has been modified so as to use the new option, has
been refactored for robustness and strict conformance to the Wiki
Creole standard, and has been well-documented.
* modules/creole.pl (CreoleGetTableHtmlAttributes): Deleted function.
2008-10-06 06:11:20 +00:00
Brian Curry
0fd92d4419 * modules/creole.pl (CreoleRuleRecursive): New function. Permits embedding
of Wiki Creole syntax within Wiki Creole syntax. (Yes... This is confusing?)
* modules/creole.pl (CreoleRule): Used the new function. Specifically, you
can now embed Creole and CreoleAddition syntax (such as bold, italics, small
caps, and so on) within URL and Wiki link text, ala
  "[[Some_Page|Wow! **Quite** an //%%interesting page%%// page, here]]."
* modules/creoleaddition.pl (CreoleAdditionRule): Renamed function from
"CreoleAdditionRules" to this.
2008-10-04 03:30:50 +00:00
Brian Curry
ea6ff73796 (CreoleAdditionRules): Corrected the definition list term's regular expression, which I'd quite munted with an earlier commit. 2008-10-02 00:12:04 +00:00
Brian Curry
674cb60c3d * modules/creole.pl: "There be dragons, here." This module now
supports a significantly stabler, more robust syntax--including:
multiline table cells, block level elements in table cells, CSS
stylization for images and image links, simpler, more efficient
regular expressions, new perldoc-style documentation, and a subtle
slew of other bug fixes. "Huzzah!"
* modules/creoleaddition.pl (AddOrCloseCreoleAdditionEnvironment): New
function.
(CreoleAdditionRules): Usage of the new function.
* t/creole.pl: Corrected all non-XPath-dependent tests.
* t/creoleaddition.pl: Corrected all non-XPath-dependent tests.
2008-10-01 07:54:44 +00:00
Brian Curry
097244fedc * modules/creoleaddition.pl (CreoleAdditionRules): Corrected most of the previously failing test cases. 2008-09-30 07:56:18 +00:00
Brian Curry
a80c361a82 * modules/creoleaddition.pl: New perldoc-style documentation.
($CreoleAdditionSmallCaps): New option.
(CreoleAdditionInit): New function.
(CreoleAdditionRules): Improved handling of existing markup rules,
so as to allow markup nesting; and implemented handling of the new
%%small caps%% markup rule.
2008-09-30 06:32:32 +00:00
Weakish Jiang
ed148f4ce9 Oh, I forgot to add $ to qw again 2008-04-11 16:35:01 +00:00
Weakish Jiang
b61470e09b * add monospace support 2008-04-11 16:04:22 +00:00
Weakish Jiang
ba6b347e5c * Fix the bug $CreoleAdditionDefList and $CreoleQuote cannot be set
by users in config. ( I just forgot to add them in qw. )
2008-04-11 15:59:39 +00:00
Weakish Jiang
801106cdfd Remove out of date comments. 2008-04-05 17:52:34 +00:00
Weakish Jiang
ab5f357909 * (CreoleAdditionRules) refine regexp * change sub name: from CreoleAdditionRule to CreoleAdditionRules. 2008-02-23 16:12:20 +00:00
Weakish Jiang
2643ac51f5 rollback to 1.6 2008-02-23 15:35:50 +00:00
Weakish Jiang
0c759cd3cf * overwrite mistake commit 2008-02-23 15:19:03 +00:00
Weakish Jiang
bec6fd1c1b * (CreoleAdditionRule) refine code 2008-02-23 15:17:44 +00:00
Weakish Jiang
ea72e20c8e * (CreoleAdditionRule) refine code 2008-02-23 14:57:09 +00:00
Weakish Jiang
146210f00a * (CreoleAdditionRule) add simple blockquote syntax * (CreoleAdditionRule) change quote syntax from "" to '' 2008-02-23 14:30:28 +00:00
Weakish Jiang
b106213ac7 * (CreoleAdditionRule) add new syntax quote 2008-02-23 13:17:20 +00:00
Weakish Jiang
84ae6ba7a5 * (CreoleAdditionRule) one term can have move than one description now. \n * (CreoleAdditionRule) remove some useless code 2008-02-22 19:38:36 +00:00
Weakish Jiang
1c26127829 * (CreoAdditionRule) add syntax for definition lists 2008-02-22 18:29:26 +00:00
Weakish Jiang
ced0f08cc9 * Add supscript and subscript syntax from Creole Addition. 2008-02-22 10:59:07 +00:00