from zope import interface
from zope import schema

from zope.schema.vocabulary import SimpleTerm, SimpleVocabulary
from collective.aviaryimageeditor import messageFactory as _
from collective.aviaryimageeditor import i18n

class IAviaryLayer(interface.Interface):
    """Browser layer"""

vocab_EditOptions = SimpleVocabulary(
 [
  SimpleTerm(value=u"all",        title=_(u"All tools")),
  SimpleTerm(value=u"rotate",     title=_(u"Rotate")),
  SimpleTerm(value=u"resize",     title=_(u"Resize")),
  SimpleTerm(value=u"crop",       title=_(u"Crop")),
  SimpleTerm(value=u"flip",       title=_(u"Flip")),
  SimpleTerm(value=u"redeye",     title=_(u"Red eye")),
  SimpleTerm(value=u"blemish",    title=_(u"Blemish")),
  SimpleTerm(value=u"colors",     title=_(u"Colors")),
  SimpleTerm(value=u"saturation", title=_(u"Saturation")),
  SimpleTerm(value=u"brightness", title=_(u"Brightness")),
  SimpleTerm(value=u"contrast",   title=_(u"Contrast")),
  SimpleTerm(value=u"drawing",    title=_(u"Drawing")),
  SimpleTerm(value=u"text",       title=_(u"Text")),
  SimpleTerm(value=u"stickers",   title=_(u"Stickers")),
  SimpleTerm(value=u"blur",       title=_(u"Blur")),
  SimpleTerm(value=u"whiten",     title=_(u"Whiten")),
  ]
    )
예제 #2
0
from collective.aviaryimageeditor import messageFactory as _

desc_all = _(u"Using this option will mean any new features that Aviary \
  releases will automatically appear without needing to update your code. \
  This option is recommended.")

desc_NoCloseButton = _(u"Set to 'true' to remove the close button. This will \
  only affect the inject OpenType version of the editor.")

desc_Stickers = _(u"An array of sticker urls in the following format:\
  ['http://big_image, http://thumbnail_image',...]")

desc_CropSizes = _(u"A space separated list of preset crop sizes for crop tool.\
  Width and Height are separated by commas.")