]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - doc/plugins/contrib/album.mdwn
disambiguate
[git.ikiwiki.info.git] / doc / plugins / contrib / album.mdwn
index 745a44e8b8c82ca691fe0b504963c234cd8ef8a0..d6e79d7c52b96a80b5ab9486517c80439565cf0f 100644 (file)
@@ -11,40 +11,25 @@ This plugin automatically enables the [[filecheck]], [[img]], [[inline]],
 [[trail]] and [[transient]] plugins. The [[meta]] plugin is also
 recommended.
 
-## Changing the templates
-
-When a viewer page is generated or inlined into an album, the template can
-contain these extra variables:
-
-* `<TMPL_VAR ALBUM>` - page name of the album
-* `<TMPL_VAR ALBUMURL>` - relative URL to the album
-* `<TMPL_VAR ALBUMTITLE>` - title of the album, usually taken from
-  a [[ikiwiki/directive/meta]] directive
-* `<TMPL_VAR CAPTION>` - caption for the image
-* `<TMPL_VAR THUMBNAIL>` - a small [[ikiwiki/directive/img]] for the image
-* `<TMPL_VAR IMAGEWIDTH>` - width of the full-size image in pixels
-* `<TMPL_VAR IMAGEHEIGHT>` - height of the full-size image in pixels
-* `<TMPL_VAR IMAGEFILESIZE>` - size of the image, e.g. `1.2 MiB`
-* `<TMPL_VAR IMAGEFORMAT>` - format of the image, typically `JPEG`
-
-The template for the viewer page can also contain:
+## Demo
 
-* `<TMPL_VAR IMG>` - a large [[ikiwiki/directive/img]] to display the image
-* `<TMPL_VAR PREV>` - a link to the previous viewer, typically with a
-  thumbnail
-* `<TMPL_VAR NEXT>` - a link to the next viewer, typically with a
-  thumbnail
+* [HTML page of thumbnails](http://ikialbum.hosted.pseudorandom.co.uk/album/)
+  as an entry point to the album
+* Each thumbnail links to
+  [a "viewer" HTML page](http://ikialbum.hosted.pseudorandom.co.uk/album/img_0120/)
+  with a full size image, optional next/previous thumbnail links, and
+  optional [[plugins/comments]]
 
-## Including album entries elsewhere
+### Altered Demo
 
-To display images from elsewhere in the wiki with the same appearance as
-an [[ikiwiki/directive/album]] or [[ikiwiki/directive/albumsection]],
-you can use an [[ikiwiki/directive/inline]] with the `albumitem`
-template:
+[[!template id=gitbranch branch=cbaines/album]]
+This uses the album plugin, with some altered css, and with the css applied to
+all of the themes.
 
-       \[[!inline pages="..." sort="-age" template="albumitem"]]
+* [Simple album, rendered using mutiple themes](http://cbaines.net/projects/ikiwiki/album/dest/basic)
+  using the ikiwiki logo.
 
-----
+## Installation
 
 [[!template id=gitbranch branch=smcv/album4 author="[[Simon_McVittie|smcv]]"]]
 
@@ -61,7 +46,7 @@ is to provide a direct link to the image.)
 
 Updated, April 2012: rebased onto the version of [[trail]] that got merged
 
-## Manual installation
+### Manual installation
 
 First, you need a version of ikiwiki with the [[trail]] plugin merged in
 (version 3.20120203 or later).
@@ -80,17 +65,49 @@ to download):
   [stylesheet](http://git.pseudorandom.co.uk/smcv/ikiwiki.git/blob/album4:/doc/style.css)
   (put them in your local.css)
 
-## Demo
+## Changing the templates
 
-* [HTML page of thumbnails](http://ikialbum.hosted.pseudorandom.co.uk/album/)
-  as an entry point to the album
-* Each thumbnail links to
-  [a "viewer" HTML page](http://ikialbum.hosted.pseudorandom.co.uk/album/img_0120/)
-  with a full size image, optional next/previous thumbnail links, and
-  optional [[plugins/comments]]
+When a viewer page is generated or inlined into an album, the template can
+contain these extra variables:
+
+* `<TMPL_VAR ALBUM>` - page name of the album
+* `<TMPL_VAR ALBUMURL>` - relative URL to the album
+* `<TMPL_VAR ALBUMTITLE>` - title of the album, usually taken from
+  a [[ikiwiki/directive/meta]] directive
+* `<TMPL_VAR CAPTION>` - caption for the image
+* `<TMPL_VAR THUMBNAIL>` - a small [[ikiwiki/directive/img]] for the image
+* `<TMPL_VAR IMAGEWIDTH>` - width of the full-size image in pixels
+* `<TMPL_VAR IMAGEHEIGHT>` - height of the full-size image in pixels
+* `<TMPL_VAR IMAGEFILESIZE>` - size of the image, e.g. `1.2 MiB`
+* `<TMPL_VAR IMAGEFORMAT>` - format of the image, typically `JPEG`
+
+The template for the viewer page can also contain:
+
+* `<TMPL_VAR IMG>` - a large [[ikiwiki/directive/img]] to display the image
+* `<TMPL_VAR PREV>` - a link to the previous viewer, typically with a
+  thumbnail
+* `<TMPL_VAR NEXT>` - a link to the next viewer, typically with a
+  thumbnail
+
+## Including album entries elsewhere
+
+To display images from elsewhere in the wiki with the same appearance as
+an [[ikiwiki/directive/album]] or [[ikiwiki/directive/albumsection]],
+you can use an [[ikiwiki/directive/inline]] with the `albumitem`
+template:
+
+       \[[!inline pages="..." sort="-age" template="albumitem"]]
 
 ## Bugs
 
+* `thumbnailsize` doesn't actually work, they're always 96x96.
+  [[KathrynAndersen]] suggested a fix on the [[discussion]] page;
+  search for her name and look for a context diff.
+
+* The album index is limited to 10 images. kjs suggested a fix on
+  the [[discussion]] page: the plugin should pass `show => 0`
+  to `preprocess_inline`.
+
 * There's currently a hard-coded list of extensions that are treated as
   images: `png`, `gif`, `jpg`, `jpeg` or `mov` files. More image and video
   types could be added in future.