Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [tcbinputlisting]

The `tcbinputlisting` module from the `tcolorbox` package is designed for generating nice and colorful boxes that contain code like the `\lstinputlisting` from `listings` package.

0
votes
0answers
27 views

tcolorbox tcblinputlisting unexpected behavior when filenames have spaces and/or underscores

I'm not a Latex expert, so I reached the limit of my knowledge in the tracking down of this problem. If someone can shed some light into this problem I think it would be very useful. The Problem ...
2
votes
0answers
21 views

Change path to tcbinputlisting to just reflect file name

In the code given below, I have many Matlab files. I put the files into a folder called "Project/Matlab". The name that appears in the first line is now "Project/Matlab/sample.m". [Note: I have ...
3
votes
2answers
54 views

Left frame tcolotbox disappears when broken up by new page

In the code given below, if there is a page break for the tcolorbox, the left grey line that I wanted, disappears. If however, the tcolorbox is not broken, the left line is present. Can you help me ...
3
votes
1answer
60 views

Infinite loop error when inserting more than one\newtcbinputlisting setting

I was attempting to generate different programming languages code snippets to highlight the different syntax in different programming languages like: Python, Matlab and C++ (more to be added later). ...
1
vote
1answer
78 views

Label inside of \newtcbinputlisting giving incorrect ref number

In the code below, I am trying to reference some matlab code that is written using a \newtcbinputlisting environment. When I attach a label to the code, the reference number come in as "1" or "a)" or ...
1
vote
1answer
53 views

Modify macro to have \newtcbinputlisting caption different in TOC

I would like some help to get the caption of the below \newtcbinputlisting to show up differently in the TOC. For example, for figure captions, the user can type ... \caption[MakeMaze output]{...
5
votes
1answer
194 views

Have just the file name show up in a listing environment

How to get just the file name (sometimes with an underscore "_") to show up in the code environment if the actual listing file is in another location like ../Matlabcode/sol2_adx.m instead of something ...
3
votes
1answer
44 views

Adjust vertical spacing of image within listing environment

In the code below, I wanted to be able to center the image to the heading text like that shown below, where the center of the image is in line with the center of the text: Here is the code that I ...
3
votes
1answer
114 views

“Repair” listing environment when used in the enumerate environment

In the code given below, the my listing environment gets skewed while in the enumerate environment: How to fix the code so that the listing box inside the enumerate environment, looks like that out ...
0
votes
1answer
53 views

Error with LuaLaTeX, tcolorbox with the listings library and an extension-less file

I have a quite similar problem as this one: error with LuaLaTeX, lstinputlisting and an extension-less file Compilation of the MWE below fails with this error message: ! Package Listings Error: ...
0
votes
2answers
139 views

tcolorbox for source code (read from file) and ouput (read from file) in lower part

I'm looking for a way to use tcolorbox to typeset some source code from a file and its output (read from a file) in the lower part of the same box and I can't find how to do this in the documentation. ...