{code} is about using LaTeX to format and display source code. For questions about TeX itself as a programming language, use the {programming} tag.

learn more… | top users | synonyms

0
votes
2answers
44 views

Pandoc md to tex: code + enumerate interaction

How to make pandoc md to xelatex conversion understand that the code structure is within an enumeration list. The minimal code I've got in my markdown file. * Test your code * Don't use structures ...
4
votes
0answers
74 views

How make formulas in the PDF not selectable?

Mathematical formulas in a PDF from LaTex generate lots of noise while reading it with Text-to-speech software. This is why I would like find a way to make all the set of symbols inside the formulas ...
3
votes
0answers
23 views

Eagle-i website citations in BibTex

I'm trying to cite some information from the Eagle-i website using BibTex. I realized they have many types of citations that seems not to match the BibTex entry types. For example, Eagle-i suggested ...
3
votes
0answers
239 views

How to use same font-style with escapechar in lstlisting?

Original Question I want to highlight something inside a C++-comment in a code-listing. \documentclass[a4paper, 12pt]{article} \usepackage{color} \usepackage{listings} \definecolor{light_gray}{rgb}...
2
votes
0answers
68 views

Start Matlab code directly from Latex

I'm using the documentclass beamer to make a presentation. Is there a way to start Matlab code directly from Latex? A button that I can press so that the Matlab code starts to run automatically? ...
2
votes
0answers
53 views

Tangle source code from PDF for literate programs

I want to include raw source code text that can be extracted from a PDF. It looks like this might be possible using PDF layers or OCQ or some kind of accessible option but I can't find a TeX package. ...
2
votes
0answers
37 views

\mintinline expands to a single newline

I'm using Minted 2.1, that I have installed through tlmgr, and Texmaker 4.1. Compiling the following piece of code (straight from the documentation) : \documentclass{report} \usepackage[utf8]{...
2
votes
0answers
124 views

How to write the signature of a method in LaTex?

I'm writing an article in LaTex about programming and I need to write the signature of a C++ method using a specific format, only the statement of the method, not the body. for example: void ...
2
votes
0answers
113 views

Different colours for each argument and value in listings

This recent question (Print blue brackets in one language and black in another) made me come up with (up to) two more questions regarding the listings package: Is there an option similar to opstyle ...
2
votes
0answers
160 views

Eclipse with texclipse code completion

I am using Eclipse with texclipse. Code completions are not showing up for some of the commands. For example: \mbox{}, \mathcal{} and for some others that i cannot recall at the moment. (If this ...
1
vote
0answers
33 views

Anyone knows any “automatic” package to draw graphs of posets (the Hasse diagrams)?

anyone knows any "automatic" package to draw graphs of posets (the Hasse diagrams)? I know TikZ, but I wanted something faster (automatic). Thank you.
1
vote
0answers
41 views

Removing the blank space after a definition (or something)?

already I researched a lot about it, but found nothing. Could you help me remove this white space to be between intem 3 and paragraph ("Quando não ....."). I thank you
1
vote
0answers
31 views

Include Doxygen syntax in LaTeX?

I want to write documetation for my current appliaction in LaTeX (about technologies i used and so on) and i wander if i could use section \mainpage of Doxygen in him, as a chapter " how to use " , ...
1
vote
0answers
28 views

How can I fill a page with a minted included json file?

I'm trying to add some huge json files to my document and have no idea how can I solve this two problems. Code: \linespread{1.0} \subsection{File xpto.json for X = 1} \label{ap:json_xpto1} \beCengin{...
1
vote
0answers
34 views

Unwanted coding shown next to inserted images on PDF, have no idea why? Pictures and code shown in description

Have this problem for all images except this one: I have tried PNG and Jpeg files, same problem. Here is the code us for the "count final.jpg" \begin{figure}[htp] \centering \includegraphics[...
1
vote
0answers
36 views

Best way to reuse and change code in a lot of documents

I would like to use in a lot of documents the same title page and some settings in a way that when I want to implement a change to take effect in all of them. One way that I thought is to place ...
1
vote
0answers
53 views

Help identifying LaTeX code-style feature

The document below uses a feature I can't quite identify to display monospaced code-style font sections: Does anyone know how to achieve this effect?
1
vote
0answers
63 views

Inserting a stand alone code file using lstlisting

I am in the process of writing a report on a project and need to include the final code used in an appendix. The final code while not yet complete, is lengthy enough that I would like to just use \...
1
vote
0answers
232 views

Dummy code box in LaTeX

I am not used to work in TeX and I need to write a dummy code box like in this style. I am not entirely sure how to replicate this style. I found some code boxes, but not in this structure that I want
0
votes
0answers
34 views

matlab-prettifier with fancyvrb-style of label / frame

I wonder how to make the frame line around caption of listing not being printed (top line being broken into two by caption in the middle) when matlab-prettifier (or listings package) are being used, ...
0
votes
0answers
60 views

minted not highlighting and inserting random characters in code

I am trying to syntax highlight some Haskell code in my latex document. The rest of my document works fine except for one section. I have the \usepackage{minted} command where my other packages are ...
0
votes
0answers
38 views

How to create an index for a book that includes code chunks

I'm in the process of creating an index for a book that includes R code chunks. I'd like to include certain R functions that appear in these chunks in the index, so I assume I have to place the \index ...
0
votes
0answers
26 views

How can I Autoident in TeXstudio?

I am a new LaTeX user. How can I auto-indent all my LaTeX code in TeXstudio? have TeXstudio an auto function ?
0
votes
0answers
46 views

Is it possible to use tikzmark inside minted?

As I've pointed out in a related question, I'd like to have some arrows pointing to parts of a source-code listing. I know this is possible with the listings package, but is it possible with minted? ...
0
votes
0answers
27 views

Pygments for markup of Lua source code - how to get styling information and the necessary macros using ``pygmentize``?

I wanted to use Pygments (specifically via the pygmentize tool) to mark up some Lua code for inclusion into a LaTeX document. Based on what I understand, pygmentize can either output a full document (...
0
votes
0answers
30 views

How to write “for” block with counter by Algorithmic package

How can I write a code like below using algorithmic package for (int i = 0; i < node.children; ++i) ..... I can't use foreach or forall because in a point inside the loop I should decrement i ...
-1
votes
0answers
18 views

am having problem managing the margin around the code please help

[![ 1: http://i.stack.imgur.com/ZRFeY.png I am trying to publish matlab code but it's overlapping code in the next column. I tried to do it using tabular format but still no help. if there is any ...