[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"detail-sidebar-cat-0-en-105":3,"doc-seo-686736-105":59,"doc-detail-686736-en":130,"doc-similar-686736":170},{"code":4,"msg":5,"data":6},0,"success",[7,13,18,23,28,33,38,43,48,51,55],{"id":8,"doc_module":4,"doc_module_name":9,"category_name":10,"show_sort_weight":11,"slug":12},1,"Document","Story & Novel",90,"story-novel",{"id":14,"doc_module":4,"doc_module_name":9,"category_name":15,"show_sort_weight":16,"slug":17},2,"Literature",80,"literature",{"id":19,"doc_module":4,"doc_module_name":9,"category_name":20,"show_sort_weight":21,"slug":22},4,"Exam",70,"exam",{"id":24,"doc_module":4,"doc_module_name":9,"category_name":25,"show_sort_weight":26,"slug":27},5,"Comic",60,"comic",{"id":29,"doc_module":4,"doc_module_name":9,"category_name":30,"show_sort_weight":31,"slug":32},6,"Technology",50,"technology",{"id":34,"doc_module":4,"doc_module_name":9,"category_name":35,"show_sort_weight":36,"slug":37},7,"Healthcare",40,"healthcare",{"id":39,"doc_module":4,"doc_module_name":9,"category_name":40,"show_sort_weight":41,"slug":42},8,"Research & Report",30,"research-report",{"id":44,"doc_module":4,"doc_module_name":9,"category_name":45,"show_sort_weight":46,"slug":47},9,"Religion & Spirituality",20,"religion-spirituality",{"id":46,"doc_module":4,"doc_module_name":9,"category_name":49,"show_sort_weight":46,"slug":50},"World Cup","world-cup",{"id":52,"doc_module":4,"doc_module_name":9,"category_name":53,"show_sort_weight":52,"slug":54},10,"Lifestyle","lifestyle",{"id":56,"doc_module":4,"doc_module_name":9,"category_name":57,"show_sort_weight":24,"slug":58},19,"General","general",{"code":4,"msg":60,"data":61},"ok",{"site_id":62,"language":63,"slug":64,"title":65,"keywords":66,"description":67,"schema_data":68,"social_meta":123,"head_meta":125,"extra_data":127,"updated_unix":129},105,"en","the-listings-package-users-guide-getting-started-step-by-step","The Listings Package - User's guide - Getting started - Step by step","","The Listings Package provides a LaTeX-based source code printer for typesetting standalone files and code listings using an environment similar to verbatim. It supports printing code snippets with a \\\\verb-like command and offers many parameters that control the output format. Users can define custom behaviors when their programming languages are not already supported, and configure appearance, special characters, line numbers, layout elements, styles, and language mappings.",{"@graph":69,"@context":122},[70,84,105],{"@type":71,"itemListElement":72},"BreadcrumbList",[73,77,79,82],{"item":74,"name":75,"@type":76,"position":8},"https://docshare.wps.com","Home","ListItem",{"item":78,"name":9,"@type":76,"position":14},"https://docshare.wps.com/document/",{"item":80,"name":30,"@type":76,"position":81},"https://docshare.wps.com/document/technology/",3,{"item":83,"name":65,"@type":76,"position":19},"https://docshare.wps.com/document/the-listings-package-users-guide-getting-started-step-by-step/686736/",{"url":83,"name":65,"@type":85,"image":86,"author":91,"headline":65,"publisher":94,"fileFormat":97,"inLanguage":63,"description":67,"dateModified":98,"datePublished":99,"encodingFormat":97,"isAccessibleForFree":100,"interactionStatistic":101},"DigitalDocument",{"url":87,"@type":88,"width":89,"height":90},"https://docshare.wps.com/thumbnails/the-listings-package-users-guide-getting-started-step-by-step/686736.png","ImageObject",300,407,{"name":92,"@type":93},"BigDaveOnline","Person",{"url":74,"name":95,"@type":96},"DocShare","Organization","application/pdf","2026-11-29","2026-11-07",true,{"@type":102,"interactionType":103,"userInteractionCount":19},"InteractionCounter",{"@type":104},"ViewAction",{"@type":106,"mainEntity":107},"FAQPage",[108,114,118],{"name":109,"@type":110,"acceptedAnswer":111},"What does the Listings Package do in LaTeX?","Question",{"text":112,"@type":113},"It typesets source code by printing standalone files and code listings, using a verbatim-like environment and commands for code snippets.","Answer",{"name":115,"@type":110,"acceptedAnswer":116},"How can users control the appearance and behavior of listings?",{"text":117,"@type":113},"The package provides many output parameters, including options for layout elements, emphasis of identifiers, line numbers, and language/style definitions.",{"name":119,"@type":110,"acceptedAnswer":120},"What should users do if their programming language is not supported?",{"text":121,"@type":113},"They can create their own definitions so the package can recognize and format that language appropriately.","https://schema.org",{"og:url":83,"og:type":124,"og:title":65,"og:site_name":95,"og:description":67},"article",{"robots":126,"canonical":83},"index,follow",{"doc_id":128,"site_id":62},686736,1794062392,{"code":4,"msg":5,"data":131},{"doc_id":128,"user_id":132,"nickname":92,"user_avatar":133,"doc_module":4,"category_id":29,"category_name":30,"doc_title":65,"doc_description":67,"doc_content":134,"file_id":135,"file_url":136,"file_type":137,"file_size":138,"view_count":19,"is_deleted":4,"is_public":8,"is_downloadable":8,"audit_status":8,"page_count":139,"language":140,"language_code":63,"site_id":62,"html_lang":63,"table_of_contents":141,"faqs":142,"seo_title":143,"seo_description":67,"update_tm":129,"read_time":144,"preview_page_count":29,"preview_urls":145},962090896214,"https://ap-avatar.wpscdn.com/davatar_155a257f0dc6eb9ab79c44ca47cae57d","The Listings Package  \nCopyright 1996{2004 Carsten Heinz \u003C[cheinz@gmx. de](cheinz@gmx. de) >  \n2004/09/07 Version 1.3  \nAbstract  \nThe listings package is a source code printer for LATEX. You can typeset stand alone 􀀌les as well as listings with an environment similar to verbatim as well as you can print code snippets using a command similar to \\verb. Many parameters control the output and if your preferred programming language isn't already supported, you can make your own de􀀌nition.  \nUser's guide 3  \n1 Getting started 3  \n1.1 A minimal 􀀌le ......... 3  \n1.2 Typesetting listings ..... 3  \n1.3 Figure out the appearance .. 5  \n1.4 Seduce to use ......... 6  \n1.5 Alternatives .......... 7  \n2 The next steps 9  \n2.1 Software license ........ 9  \n2.2 Package loading ........ 10  \n2.3 The key=value interface ... 10  \n2.4 Programming languages ... 11  \n2.5 Special characters ...... 11  \n2.6 Line numbers ......... 13  \n2.7 Layout elements ....... 14  \n2.8 Emphasize identi􀀌ers ..... 17  \n2.9 Indexing ............ 18  \n2.10 Fixed and 􀀍exible columns . 18  \n3 Advanced techniques 19  \n3.1 Style de􀀌nitions ........ 19  \n3.2 Language de􀀌nitions ..... 20  \n3.3 Delimiters ........... 21  \n3.4 Closing and credits ...... 23  \nReference guide 24  \n4 Main reference 24  \n4.1 How to read the reference .. 24  \n4.2 Typesetting listings ..... 25  \n4.3 Space and placement ..... 25  \n4.4 The printed range ...... 26  \n4.5 Languages and styles ..... 26  \n4.6 Figure out the appearance .. 27  \n4.7 Getting all characters right . 29  \n4.8 Line numbers ......... 30  \n4.9 Captions ............ 31  \n4.10 Margins and line shape ... 32  \n4.11 Frames ............. 33  \n4.12 Indexing ............ 35  \n4.13 Column alignment ...... 35  \n4.14 Escaping to LATEX ...... 36  \n4.15 Interface to fancyvrb ..... 38  \n4.16 Environments ......... 39  \n4.17 Language de􀀌nitions ..... 39  \n4.18 Installation .......... 44  \n5 Experimental features 45  \n5.1 Listings inside arguments .. 45  \n5.2 􀂄 Export of identi􀀌ers .... 46  \n5.3 􀂄 Hyper references ...... 46  \n5.4 Literate programming .... 47  \n5.5 LGrind de􀀌nitions ....... 47  \n5.6 􀂄 Automatic formatting ... 48  \n5.7 Arbitrary linerange markers . 49  \nTips and tricks 50  \n6 Troubleshooting 50  \n7 How tos 51  \nPreface  \nReading this manual If you are experienced with the listings package, you should read the next paragraph \\News and changes \" . Otherwise read section 1 Getting started step by step and go on with section 2.  \nNews and changes This is the third bug􀀌x release. The most noteworthy news for the tortured | I mean experienced | user is a new \\output routine, which improves the compatibility to other packages. Therefore the temporary key noxoutput has been removed.  \ntexcs became a family, [i.e. you](i.e. you) can highlight your own control sequences diffently from the already de􀀌ned ones: texcsstyle= [*][hclass numberi] . . . and texcs=[hclassnumberi] . . . Note the added optional star, which also highlights the backslash in front of the control sequence name. And don't forget to check page 28 for a bug.  \nkeywordstyle has a small add-on (see page 28) and extendedchars is turned on by default.  \nThe following languages were added: Awk (Gnu and Posix), Gnuplot, HandelC, ByteCode Java (JVMIS), Plasm, Promella, and RSL, refer table refuPrede-􀀌nedLanguages. Moreover, HTML, AspectJ, and MetaPost have been improved. Thanks go to the contributers.  \nThanks There are many people I have to thank for fruitful communication, posting their ideas, giving error reports, adding programming languages tolstdrvrs.dtx, and so on. Their names are listed in section 3.4.  \nTrademarks Trademarks appear throughout this documentation without any trademark symbol; they are the property of their respective trademark owner. There is no intention of infringement; the usage is to the bene􀀌t of the trademark owner.  \nUser's guide  \n1 Getting started  \n1.1 A minimal 􀀌le  \nBefore using the listings package, you should be familiar with the LATEX typesett","cbCaiekNsMCUNBn0","https://ap.wps.com/l/cbCaiekNsMCUNBn0","pdf",489351,56,"English","# User's guide\n## Getting started\n## The next steps\n## Advanced techniques\n# Reference guide\n## Main reference\n## Experimental features\n## Tips and tricks\n## Troubleshooting\n## How tos","[{\"question\":\"What does the Listings Package do in LaTeX?\",\"answer\":\"It typesets source code by printing standalone files and code listings, using a verbatim-like environment and commands for code snippets.\"},{\"question\":\"How can users control the appearance and behavior of listings?\",\"answer\":\"The package provides many output parameters, including options for layout elements, emphasis of identifiers, line numbers, and language/style definitions.\"},{\"question\":\"What should users do if their programming language is not supported?\",\"answer\":\"They can create their own definitions so the package can recognize and format that language appropriately.\"}]","The Listings Package - User's guide - Getting started - Step by step | PDF",141,[146,150,154,158,162,166],{"page_no":8,"url":147,"width":148,"height":149},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-09/93c113206d84e80e98d4035510ecd57b.webp",983,1390,{"page_no":14,"url":151,"width":152,"height":153},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-09/026062ba811d865a23d8fc2d1c00ccf1.webp",982,1388,{"page_no":81,"url":155,"width":156,"height":157},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-09/31c90121db455ec53cd97bf6637779f9.webp",981,1387,{"page_no":19,"url":159,"width":160,"height":161},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-09/0ef409b511f3efe6d7f3b38a7814ae44.webp",980,1385,{"page_no":24,"url":163,"width":164,"height":165},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-09/27865caea3564075afbc125f7a8a57b6.webp",979,1384,{"page_no":29,"url":167,"width":168,"height":169},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-09/7e24a08352b97b1522ff794a0ad70cba.webp",978,1383,{"list":171,"token":66},[172,178,184,190,196,203,209,215,222,229],{"doc_id":173,"doc_title":174,"file_type":137,"home_preview_img_url":175,"slug":176,"view_count":24,"category_name":30,"create_tm":177},686741,"The Listings Package - Version 1 - User's guide","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230000580642/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=RtuabRr3gTZKvpKrFRDetHp1PMQ%3D","the-listings-package-version-1-users-guide",1794062405,{"doc_id":179,"doc_title":180,"file_type":137,"home_preview_img_url":181,"slug":182,"view_count":24,"category_name":30,"create_tm":183},669402,"THE KNITTING PACKAGE - written guide for LaTeX/TEX knitting chart fonts","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229988612059/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=lxxxQ6n1t8%2Fq73luzUEUkmvUjT4%3D","the-knitting-package-written-guide-for-latextex-knitting-chart-fonts",1793553230,{"doc_id":185,"doc_title":186,"file_type":137,"home_preview_img_url":187,"slug":188,"view_count":44,"category_name":30,"create_tm":189},652823,"LATEX2e - Unofficial Reference Manual - June 2026","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229973518358/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=qo9IsRvanIACWf2gkD6qiqNFRQ8%3D","latex2e-unofficial-reference-manual-june-2026",1792883055,{"doc_id":191,"doc_title":192,"file_type":137,"home_preview_img_url":193,"slug":194,"view_count":39,"category_name":30,"create_tm":195},656937,"Lewis Structures in LATEX - Using the lewis package","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229975336515/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=NEbRWzxVXQmninT8waYxSFgLCrk%3D","lewis-structures-in-latex-using-the-lewis-package",1792971564,{"doc_id":197,"doc_title":198,"file_type":137,"home_preview_img_url":199,"slug":200,"view_count":201,"category_name":30,"create_tm":202},291542,"File Layouts - CHOICE Program - 2024","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229903497817/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=92odqYWYprhqD%2FGsqF18ZZ3Nams%3D","file-layouts-choice-program-2024",12,1789645936,{"doc_id":204,"doc_title":205,"file_type":137,"home_preview_img_url":206,"slug":207,"view_count":44,"category_name":30,"create_tm":208},656624,"Writing a Patent Application in LATEX and LYX","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229974796302/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=eG0v%2Be91AFevlVQUvZFozv6TPUg%3D","writing-a-patent-application-in-latex-and-lyx",1792969684,{"doc_id":210,"doc_title":211,"file_type":137,"home_preview_img_url":212,"slug":213,"view_count":81,"category_name":30,"create_tm":214},699578,"New Computer Fan Data-Science Set-up - Python (Anaconda), R (Rstudio), Matlab and Latex (Texlive)","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230011320290/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=bnRyy1f0AFbSSooTZcpRB%2BplxPk%3D","new-computer-fan-data-science-set-up-python-anaconda-r-rstudio-matlab-and-latex-texlive",1794479724,{"doc_id":216,"doc_title":217,"file_type":137,"home_preview_img_url":218,"slug":219,"view_count":220,"category_name":30,"create_tm":221},345472,"PDF-XChange Lite V6 User Manual","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229911104854/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=dkFjMXlr60ZpDsp1YluYDXAKktM%3D","pdf-xchange-lite-v6-user-manual",18,1790057765,{"doc_id":223,"doc_title":224,"file_type":137,"home_preview_img_url":225,"slug":226,"view_count":227,"category_name":30,"create_tm":228},343494,"Honeywell Printers - Print PDF Directly - User Guide","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229910425225/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=n5yAHJn1pjlxvn9DQDn0wqWyFBw%3D","honeywell-printers-print-pdf-directly-user-guide",25,1790051312,{"doc_id":230,"doc_title":231,"file_type":137,"home_preview_img_url":232,"slug":233,"view_count":34,"category_name":30,"create_tm":234},689156,"Thermo-Calc Documentation Set - Version 2020b - Installation Guide and Licensing Setup","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230001524699/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796112119&Signature=EFKhrotYgNIzxtu7SZX%2B6RrzcGE%3D","thermo-calc-documentation-set-version-2020b-installation-guide-and-licensing-setup",1794097891]