Hackathon 2013 Proposals

1. Layout

Generating a customized XWiki-Skin is rather tedious and cumbersome. This is because you have to write a frameheader and a framefooter script in which each generates the HTML-code before (frameheader) and after (framefooter) the page-content. The difficulty is now to not forget to close in the footer any div-tag opened in the header.

 

We now would create an extension which allows to create layouts in a Layout Editor. Each layout is composed out of a tree which represents the HTML div-structure. The tree consists out of cells which each represents a div in the HTML. A layout rendering engine will then generate the HTML on the fly. 

 

Features:

  • An XWiki Skin called cellskin which uses the cell-renderer to generate the HTML of the current page out of the layout tree structure.
  • Layout Editor with tree-view:
     
  • Drag and Drop reordering of cells
  • Possibility to define in an object on a page, space-preferences, xwiki-preferences or even in xwiki.cfg which layout should be rendered.
  • Layout import and export
  • Sub-Layouts can be included multiple times in different layouts

 

 

2. Photo

Features:

  • Resize maintaining aspect ratio.
  • Resize to a fixed size maintaining aspect ratio and centering the image, adding a background colour to the "not image covered areas" (transparent if you like).
  • Resize to a fixed size as a lower bound. This cuts a part of the image to match the size (either height or width, whatever overlaps). Deault keeps the center of the image, but you can choose which part to keep.
  • Crop an image. I think this is self explainatory, e.g. use only a face from a larger picture.
  • Place text on the image. Either like a watermark diagonally over the image or in the lower right corner.
  • Change an image from colour to grayscale.
  • Read additional image formats as e.g. images using CMYK colours. Tested at the momet are bmp, gif, jpg and png.
  • Extract meta tags from the image.
  • Generate barcode images.

Challenges:

  • Since it overrides the downloadAttachment method it’s still a plugin. Is there a possibility to do this as a component instead?
  • Can lead to problems when used besides the XWiki image plugin (we use it instead) since you can get the wrong image from the image plugin cache.

 

3. Publish

This is pretty straight forward and is best explained using an example:

You want to create an XWiki contest. Participating should be allowed between 1.1. and 31.3. With publish you can configure your form to be available to all without edit rights only in this time frame without having to remember to activate and deactivate the form.