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.
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()
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()
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))
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))
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.