devtools/fill.py
changeset 4072 ead446e70c28
parent 4053 7cc66b1d9183
child 4252 6c4f109c2b03
equal deleted inserted replaced
4071:e19e586cc74e 4072:ead446e70c28
   110             return choosed
   110             return choosed
   111         # All other case, generate a default string
   111         # All other case, generate a default string
   112         attrlength = get_max_length(self.e_schema, attrname)
   112         attrlength = get_max_length(self.e_schema, attrname)
   113         num_len = numlen(index)
   113         num_len = numlen(index)
   114         if num_len >= attrlength:
   114         if num_len >= attrlength:
   115             ascii = self.e_schema.rproperty(attrname, 'internationalizable')
   115             ascii = self.e_schema.rdef(attrname).internationalizable
   116             return ('&'+decompose_b26(index, ascii))[:attrlength]
   116             return ('&'+decompose_b26(index, ascii))[:attrlength]
   117         # always use plain text when no format is specified
   117         # always use plain text when no format is specified
   118         attrprefix = attrname[:max(attrlength-num_len-1, 0)]
   118         attrprefix = attrname[:max(attrlength-num_len-1, 0)]
   119         if format == 'text/html':
   119         if format == 'text/html':
   120             value = u'<span>é%s<b>%d</b></span>' % (attrprefix, index)
   120             value = u'<span>é%s<b>%d</b></span>' % (attrprefix, index)