This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description


ImageScales applies a simple patch to the schema used for ATImage to allow specification of image scales on a site-by-site basis. It should work with Plone 2.5 and 3.x. For Plone 3.x, you may wish to use instead.


Install ImageScales by adding “Products.ImageScales” to your buildout eggs list.

It’s also possible to extract the “ImageScales” directory in ImageScales/Products and putting it in an old-style Zope Products directory.

ImageScales will not show up in your Plone add/remove products configlet as it needs no special installation.

How it works

Once the ImageScales patch is in place, getAvailableSizes method calls will be routed through a method installed on startup. This method will look for a portal_properties property sheet named imaging_properties. If it finds it, it will read the lines property allowed_sizes to get a list of sizes. If either the special property sheet or property are not found, the original ATImage scales will be used.

Configuring Site Scales

Create in portal_properties a plone property sheet named imaging_properties. Create in that property sheet a lines property with the id “allowed_sizes”.

Sizes should contain a list of lines. Each line is a scale specification. Each specification should have the format:

id horizontal_pixels:vertical_pixels

For example, to recreate the standard ATImage scales, the property would read:

large 768:768
preview 400:400
mini 200:200
thumb 128:128
tile 64:64
icon 32:32
listing 16:16

If you’re using ImageScales with a theme product that has a GS profile, you can create the property sheet with a property_tools.xml specification like:

<?xml version="1.0"?>
<object name="portal_properties" meta_type="Plone Properties Tool">
 <object name="imaging_properties" meta_type="Plone Property Sheet">
  <property name="title">Image Scales for ATImage</property>
  <property name="allowed_sizes" type="lines">
   <element value="large 768:768"/>
   <element value="preview 400:400"/>
   <element value="mini 200:200"/>
   <element value="thumb 128:128"/>
   <element value="tile 64:64"/>
   <element value="icon 32:32"/>
   <element value="listing 16:16"/>

However you build your property sheet, you’ll need to use the portal_atct tool to rebuild image scales in existing images any time you make a change.


1.0 - Unreleased

  • Initial release
Release History

Release History


This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
ImageScales-0.1.tar.gz (10.1 kB) Copy SHA256 Checksum SHA256 Source May 13, 2009

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting