1 I'm using ikiwiki for a software project, and in the design process one of the things I sometimes write
2 algorithms. It doesn't happen much, but for components of functional nature it's very useful.
4 I've been thinking how to write them in the wiki. I can use a numbered list and manually make
5 keywords __bold__, but it's not optimal. I could also use plain text formatting and indent using tabs,
6 but again there is no highlighting of any keywords or formatting of structures.
7 Before I do that, I'd like to know if there are better options.
9 One option I know is LaTeX, which has some very nice packages. You write pseudo-code which looks
10 very much like source code, and the result looks great, very readable and high quality.
12 I saw the [[plugins/teximg]] plugin, but the explanation there is poor: Does the plugin handle things
13 that aren't formulas? Could it work with a LaTeX document or with an algorithm environment?
15 Of course, of you have other suggestions I'll be happy to hear. I want to make a careful choice before
16 I start writing many algorithms :-)
18 > You may try to see if you can select a pseudo-code languages in one of the
19 > highlight plugins ([[plugins/contrib/highlightcode]],
20 > [[plugins/contrib/sourcehighlight]], [[plugins/highlight]], other ?). The
21 > list of supported languages with the [[plugins/highlight]] plugin is
22 > [[here|http://www.andre-simon.de/doku/highlight/en/langs.php]], and if you
23 > cannot find your languages, I think you can define your own
24 > [[here|http://www.andre-simon.de/doku/highlight/en/plugins.php]].
28 >> Thanks, I looked at it. I don't think there's any special language for algorithms
29 >> (anyway I couldn't find any), but for the record I found the following possibilities:
31 >> 1. LaTeX: Not very readable in source form, but could be highlighted, didn't try
32 >> 2. Writing in a subset of Python/Pascal/Fortran and using their highlighting
33 >> 3. Define a new highlight syntax
35 >> What about [[plugins/teximg]]? If it can be used to generate algorithms from LaTeX, it would be
36 >> an easy excellent solution.
40 > [[plugins/teximg]] is the best thing that currently exists. Since it isn't
41 > enabled on this wiki, and the author's ikiwiki has disappeared, I put one of
42 > the test formulas into a private test wiki of mine. Here's a screenshot:
43 > <http://imgur.com/nT6mefx>
45 > I think it would be great if someone [[wrote a
46 > plugin for something nicer|todo/Add_nicer_math_formatting]]. -- [[Jon]]
48 >> [[plugins/teximg]] is fine for math (al least for GUI browsers, I didn't try with w3m etc.),
49 >> but what I'm looking for is a solution for formatting **algorithms**. If teximg can help
50 >> with that, great, otherwise there's the 3 workarounds I mentioned above.
52 >> Do you have any ideas not mentioned? :-)
54 >> -- [[fr33domlover]]