parameters: (self, parent, info, page, settings)
return_statement: return parent
docstring: Build the tokens needed for displaying code listing.
docstring_summary: Build the tokens needed for displaying code listing.
docstring_tokens: Build the tokens needed for displaying code listing .
function: def createToken(self, parent, info, page, settings):
          """
          Build the tokens needed for displaying code listing.
          """
  
          filename = common.check_filenames(info['subcommand'])
          flt = floats.create_float(parent, self.extension, self.reader, page, settings,
                                    token_type=Listing)
          # Create code token
          lang = settings.get('language')
          content = self.extractContent(filename, settings)
          lang = lang if lang else common.get_language(filename)
  
          code = core.Code(flt, style="max-height:{};".format(settings['max-height']),
                           content=content, language=lang)
  
          if flt is parent:
              code.attributes.update(**self.attributes(settings))
          else:
              code.name = 'ListingCode' #TODO: Find a better way
  
          if settings['link']:
              modal.ModalSourceLink(flt, src=filename, language=lang)
  
          return parent
function_tokens: def createToken ( self , parent , info , page , settings ) : filename = common . check_filenames ( info [ 'subcommand' ] ) flt = floats . create_float ( parent , self . extension , self . reader , page , settings , token_type = Listing ) # Create code token lang = settings . get ( 'language' ) content = self . extractContent ( filename , settings ) lang = lang if lang else common . get_language ( filename ) code = core . Code ( flt , style = "max-height:{};" . format ( settings [ 'max-height' ] ) , content = content , language = lang ) if flt is parent : code . attributes . update ( * * self . attributes ( settings ) ) else : code . name = 'ListingCode' #TODO: Find a better way if settings [ 'link' ] : modal . ModalSourceLink ( flt , src = filename , language = lang ) return parent