Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

Download
ActivePython
INSTALL>
pypm install collective.z3cform.colorpicker

How to install collective.z3cform.colorpicker

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install collective.z3cform.colorpicker
 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
0.2
1.1Never BuiltWhy not?
0.2 Available View build log
0.1 Available View build log
Windows (64-bit)
0.2
1.1Never BuiltWhy not?
0.2 Available View build log
0.1 Available View build log
Mac OS X (10.5+)
1.1 Available View build log
0.2 Available View build log
0.1 Available View build log
Linux (32-bit)
1.1 Available View build log
0.2 Available View build log
0.1 Available View build log
Linux (64-bit)
1.1 Available View build log
0.2 Available View build log
0.1 Available View build log
 
License
GPL
Lastest release
version 1.1 on Jun 5th, 2013

Introduction

collective.z3cform.colorpicker provides two different jQuery based widgets:

  • Farbtastic, a simple color picker.
  • jPicker, a jQuery Color Picker Plugin supporting transparency.

Requirements

  • plone >= 3.2.1
  • plone.app.z3cform

Installation

This addon can be installed has any other addons, please follow official documentation.

Usage

You can use this widget setting the "widgetFactory" property of a form field:

from zope import schema
from z3c.form import form, field
from collective.z3cform.colorpicker.colorpicker import ColorpickerFieldWidget
from collective.z3cform.colorpicker.colorpickeralpha import ColorpickerAlphaFieldWidget

class IColorForm(interface.Interface):
    color = schema.TextLine(title=u"Color",
                            description=u"",
                            required=False)
    alphacolor = schema.TextLine(title=u"Color with alpha layer support",
                                 description=u"",
                                 required=False)

class Color(object):
    color = '#ff0000'
    alphacolor = 'ff0000cc'

    def __init__(self, context):
        self.context = context

class ColorForm(form.Form):
    fields = field.Fields(IColorForm)
    fields['color'].widgetFactory = ColorpickerFieldWidget
    fields['alphacolor'].widgetFactory = ColorpickerAlphaFieldWidget

    ...

for more information see demo directory in the package sources.

Contributors

  • Giorgio Borelli - gborelli, Original Author
  • Silvio Tomatis - silviot

Changelog

1.1 (2013-06-02)
  • fix MANIFEST.in [gborelli]
1.0 (2013-06-02)
  • add z3cform_colorpicker.js to initialize JPicker widget [gborelli]
  • add internationalization support [gborelli]
  • add css and javascript to Plone registry in order to make html valid [gborelli]
  • add profile to install colorpicker package [gborelli]
  • change some jpicker styles [gborelli]
  • update jpicker to v1.1.6 [gborelli]
  • egg layout refactoring [gborelli]
  • change Browser import from Testing.testbrowser [gborelli]
0.2 (2010-10-31)
  • include jPicker widget for alpha transparency support [gborelli]
0.1 (2009-06-19)
  • Initial release

Subscribe to package updates

Last updated Jun 5th, 2013

Download Stats

Last month:2

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.