Exemplo n.º 1
0
 def canvas(self, **kwargs):
     if kwargs.get('id') is None:
         kwargs['id'] = 'canvas%s' % uniqueId()
     self.write_tag(u'canvas', True, kwargs)
     self._closeTag(u'canvas')
     self._canvasMode = kwargs[
         'id']  # Some builder calls change behavior when in SVG mode.
Exemplo n.º 2
0
 def id2WindowId(cls, id):
     u"""
     
     The ``id2WindowId`` transformer method answers the unique window id that is used to store the state of
     a window in the session. If ``id`` is ``None`` then create a unique id.
     
     """
     return 'floatWin_%s' % id or uniqueId()
Exemplo n.º 3
0
 def id2WindowId(cls, id):
     u"""
     <doc>
     The <code>id2WindowId</code> transformer method answers the unique window id that is used to store the state of
     a window in the session. If <attr>id</attr> is <code>None</code> then create a unique id.
     </doc>
     """
     return 'floatWin_%s' % id or uniqueId()
Exemplo n.º 4
0
 def getNewSessionId(cls, size=None):
     u"""
     
     The ``getNewSessionId`` method answers a new generated session id of length ``size``
     of ``self.SESSION_SIDDIGITS`` if omitted.
     
     """
     return str(uniqueId(size or cls.C.SESSION_SIDDIGITS))
Exemplo n.º 5
0
 def getNewSessionId(cls, size=None):
     u"""
     <doc>
     The <code>getNewSessionId</code> method answers a new generated session id of length <attr>size</attr>
     of <code>self.SESSION_SIDDIGITS</code> if omitted.
     </doc>
     """
     return str(uniqueId(size or cls.C.SESSION_SIDDIGITS))
Exemplo n.º 6
0
 def getNewSessionId(cls, size=None):
     u"""
     <doc>
     The <code>getNewSessionId</code> method answers a new generated session id of length <attr>size</attr>
     of <code>self.SESSION_SIDDIGITS</code> if omitted.
     </doc>
     """
     return str(uniqueId(size or cls.C.SESSION_SIDDIGITS))
Exemplo n.º 7
0
 def id2WindowId(cls, id):
     u"""
     <doc>
     The <code>id2WindowId</code> transformer method answers the unique window id that is used to store the state of
     a window in the session. If <attr>id</attr> is <code>None</code> then create a unique id.
     </doc>
     """
     return 'floatWin_%s' % id or uniqueId()
Exemplo n.º 8
0
 def getNewSessionId(cls, size=None):
     u"""
     
     The ``getNewSessionId`` method answers a new generated session id of length ``size``
     of ``self.SESSION_SIDDIGITS`` if omitted.
     
     """
     return str(uniqueId(size or cls.C.SESSION_SIDDIGITS))
Exemplo n.º 9
0
 def canvas(self, **kwargs):
     if kwargs.get('id') is None:
         kwargs['id'] = 'canvas%s' % uniqueId()
     self.write_tag(u'canvas', True, kwargs)
     self._closeTag(u'canvas')
     self._canvasMode = kwargs['id'] # Some builder calls change behavior when in SVG mode.