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 products.autocompletewidget

How to install Products.AutocompleteWidget

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install products.autocompletewidget
 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
1.4.0 Available View build log
1.3 Available View build log
Windows (64-bit)
1.4.0 Available View build log
1.3 Available View build log
Mac OS X (10.5+)
1.4.0 Available View build log
1.3 Available View build log
Linux (32-bit)
1.4.0 Available View build log
1.3 Available View build log
Linux (64-bit)
1.4.0 Available View build log
1.3 Available View build log
 
License
see LICENSE.txt
Dependencies
Lastest release
version 1.4.0 on Oct 25th, 2011

Overview

To use this package just create a field like:

System Message: WARNING/2 (<string>, line 6)

Literal block expected; none found.

StringField('test_field', default='', searchable=0, required=0, vocabulary=DisplayList((('week', 'Week'), ('wedding','Wedding'), ('winona','Winona'), ('winter', 'Winter'), ('weather','Weather'), ('cow', 'Cow'))), widget=AutocompleteWidget(label='Test Widget', description='Test this', ), enforceVocabulary=0, ),

You can also use a LinesField instead of a StringField. The widget adapts automatically. This has the advantage that you can index the field in the catalog (keyword index). Combine this with the filter_bogus property on the widget and the widget will prepare the entered values.

It's useless without a vocabulary, and setting enforceVocabulary true doesn't really make sense unless you use the LinesField.

Configuration

There are a few parameters that can be set to alter the behavior of the widget:

actb_timeout: How long (ms) before the autocomplete box times out and dissapears. (Default: 2500, -1 to disable) actb_lim: How many choices to show in the autocomplete box at a time. (default: 5) actb_firsttext: Should the autocomplete serach be limited to the beginning of keyword (True), or should it search the entire entry for a match (False)? (default: 0) actb_filter_bogus: remove keywords that are not in the vocabulary and also remove redundant keywords, leading/trailing spaces etc.

actb_expand_onfocus: expand the dropdown on focus.

actb_complete_on_tab: set to 0 if you want tab to move the focus to the next widget. default is 1.

Credits

The javascript used is based on the widget at http://codeproject.com/jscript/jsactb.asp by zichun and used with permission.

The improved_multivalued_fields_management branch which has become the new trunk of this package was started by Quadra Informatique <plone at quadra-informatique dot fr>.

Thanks to all contributors (names listed in Changes).

Changes

1.4 - unreleased
  • Merged from trunk, keeping fixes and features

System Message: WARNING/2 (<string>, line 69)

Bullet list ends without a blank line; unexpected unindent.

[Quadra Informatique - jriboux]

From 1.0 original trunk
  • Fixed safari keyboard issues. Added single select option

System Message: WARNING/2 (<string>, line 76)

Bullet list ends without a blank line; unexpected unindent.

[dannyb]

  • Updated to use a GenericSetup profile for installation

System Message: WARNING/2 (<string>, line 79)

Bullet list ends without a blank line; unexpected unindent.

[wichert]

  • Change the templates to use a div based dropdown, giving a sane

System Message: WARNING/2 (<string>, line 82)

Bullet list ends without a blank line; unexpected unindent.

scrolling experience. [dannyb]

1.3 (15-03-2010)
  • Added possibility to hide the clear button
  • Corrected a bug showing () when the multivalued field was empty
  • Added compatibility with reference fields
  • generalized a few checks to make compatible with ReferenceFields (davisagli)
  • inline the filter function and uses scopes instead of method calling.

System Message: WARNING/2 (<string>, line 98)

Bullet list ends without a blank line; unexpected unindent.

the vocab for field was being called for each term stored in the field keyword_from_value method should go away. It's no longer being used. also general white space cleanups. (runyaga)

  • tabindex is not available for archetypes widgets anymore and broke

System Message: WARNING/2 (<string>, line 103)

Bullet list ends without a blank line; unexpected unindent.

edit views in plone4 - fixes http://plone.org/products/autocompletewidget/issues/5 (fRiSI)

  • eggified product (fRiSi)
  • history.txt and HISTORY.txt merged to CHANGES.txt
  • added issue #3 (merging with trunk) to todo.txt
  • removed refres.txt since it's no longer supported
  • made widget work with vocabularies containing non-ascii characters too

System Message: WARNING/2 (<string>, line 114)

Bullet list ends without a blank line; unexpected unindent.

(fRiSi)

2008-03-14 - v1.2.1 : Quadra Informatique - Jonathan Riboux

  • integrated Ak Sorpa's fix to prevent &amp;, &lt; and &gt; to appear in the input box after selecting a value in the drop-down list

2008-03-12 - v1.2 : Quadra Informatique - Jonathan Riboux

  • corrected i18n attributes so AutocompleteWidget can be used in English
  • added tooltips and button labels
  • better look
  • added CSS classes to buttons

2008-02-25 - v1.1 : Quadra Informatique - Nicolas Geissel

  • using fieldName var instead of field.getName for better flexibility (widget can now be used as a search widget)
  • added i18n

2008-02-07 - v1.0 : Quadra Informatique - Jonathan Riboux

  • improvement of display list support (display value, but register key)
  • widget shows a list of current values next to the input field for multivalued fields
  • arrows navigation in menu now works on Internet Explorer
  • cleanup of process_form code

2005-02-09: Danny Bloemendaal

  • ESC shows the dropdown list
  • onblur now works and hides the list
  • added property to have the list expanded on focus
  • renamed filter_bogus to actb_filter_bogus to have a consistent naming

2005-02-08: Danny Bloemendaal

  • replaced the javascript factory with the latets version from the original author
  • redid the styling so the widget resembles more the standard widget formatting
  • removed some configuration stuff that only lead to bad UI behavior
  • added LinesField support so the field can now be indexed properly

Subscribe to package updates

Last updated Oct 25th, 2011

Download Stats

Last month:5

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.