This repository contains a LyX module to facilitate use of the algpseudocode.sty
style file, part of the algorithmx
LaTeX package. It is available under the GPLv2 open-source license.
The current (beta) version is 0.2.
The module provides the following paragraph styles:
- Algorithm to create an
algorithmic
environment; - Function and EndFunction to enter functions;
- Procedure and EndProcedure to enter procedures;
- Return to enter a return statement;
- State to enter a typical line of code;
- Call to enter procedure calls;
- If, Else if, Else and EndIf to enter conditional statements;
- For and EndFor to enter for loops;
- While and EndWhile to enter while loops;
- Repeat and Until to enter repeat loops;
- Loop and EndLoop to enter indefinite loops;
- Input block, Output block and Declare argument to declare inputs and outputs (with explanations) for an algorithm, function or procedure; and
- Ensure and Require to make assertions about algorithms;
There is also a paragraph style (corresponding to the \Statex
command from the LaTeX package) to insert a blank, unnumbered line.
In-line comments are supported by a custom inset.
A LyX document (pseudocode.lyx
) with some minimal instructions and examples is also provided.
This module is written for file format 66, the current format for LyX 2.3.1. You may be able to use it with (somewhat) older versions of LyX by manually editing the Format
line in the module.
Bug reports and feature requests are welcome, using the issue tracker for the repository.