{fancyvrb} is a package that provides sophisticated facilities for reading and writing verbatim TeX code.

learn more… | top users | synonyms

2
votes
2answers
610 views

Resize frame around Verbatim

The code: \begin{figure} \begin{Verbatim}[frame=single, framesep=5mm] <pick ...> <onMessage resolveByBPELEngine="true"> ... </onMessage> ... </pick> \end{Verbatim} ...
2
votes
4answers
513 views

Problems with % percent sign in fancyvrb inline \Verb

I have some programming language code examples in a fancyvrb \Verb!...! expression. This includes the modulus operator which happens to be a percent sign, e.g. \Verb!(1..100) select: { arg i; i % 7 ...
1
vote
1answer
171 views

How to make fancyvrb's \DefineShortVerb work in other commands?

I'm using the fancyvrb package with the \DefineShortVerb{\|}. However, using | inside of any command doesn't work. MWE: \documentclass{scrbook} \usepackage{fancyvrb} \DefineShortVerb{\|} ...
5
votes
1answer
216 views

fancyvrb and \overfullrule

I know I can use \overfullrule=5pt to get overfull lines marked with a black marker, but using the Verbatim environment from the fancyvrb package the overfull lines are not marked. For example, ...
1
vote
1answer
1k views

Frame line width within DefineVerbatimEnvironment

I am trying to define an environment which requires a frame line as wide as \textwidth \DefineVerbatimEnvironment% {code}{Verbatim}{...,frame=lines,% xleftmargin=7pt,fontsize=...} I ...
5
votes
1answer
156 views

Retrieve em-width from another font

I’m trying to align verbatim segments with their outputs. Consider this MWE: \documentclass{article} \usepackage{lmodern} \usepackage{fancyvrb} ...
5
votes
1answer
846 views

Colored line numbers with algorithmicx?

The fancyvrb allows me to customize line number style which I find very useful. I'm using it to give line numbers a different color and then use that same color in the text describing the code. I ...
3
votes
1answer
300 views

How to set the Top Margin for a custom Verbatim environment (fancyvrb)

From the fancyvrb documentation, it looks like I can set left and right margins (paragraph 4.1.13) only. How can I set the top margin for my environment? More specifically, given that I have a frame ...
3
votes
1answer
309 views

Command right after closing a verbatim environment

I need to use a form of a verbatim environment, so that after the closing of the environment, there immediately follows another command. In particular I need something like the following - assuming ...
3
votes
1answer
242 views

fancybox conflict with fancyvrb? [duplicate]

Possible Duplicate: Error using \usepackage{fancyvrb, fancybox} I try to implement a simple environment to highlight source code in LaTeX. My solution is : use VerbatimOut to write text ...
0
votes
1answer
131 views

fancyvrb always creates new page

I'm having trouble using the facyvrb package. I have the following code: \section{My section} \subsection{Subsection} \begin{Verbatim}[frame=single] ...lots of code... \end{Verbatim} However, ...
11
votes
3answers
375 views

fancyvrb ShortVerb and tikz incompatibity

I've been working on a document that has a lot of little verbatim bits so I'm using fancyvrb \DeflneShortVerb{\|}. Now I want to add a tikz picture, and the whole thing fails. It there a simple way ...
4
votes
1answer
2k views

inputenc error with unicode chars and verbatim

I am writing a package where I need to save the contents of several environments in verbatim mode to an auxiliary file. Then the auxiliary file is processed by an external program. In the next ...
8
votes
2answers
2k views

Background color for fancyvrb

For reasons unclear to me, fancyvrb doesn't have a background option. However, the minted package, which it is based on, has one, which suggests it should not be too difficult to add. The relevant ...
4
votes
3answers
764 views

Error using \usepackage{fancyvrb, fancybox}

With TeX Live 2009, with this MWE. \documentclass{article} \usepackage{fancyvrb, fancybox} \begin{document} \begin{Verbatim}[frame=single] auto eth0 \end{Verbatim} \end{document} I ...
3
votes
1answer
123 views

Possible to use certain delimiters for macros with fancyvrb?

In this document: \documentclass{article} \usepackage{fancyvrb} \DefineVerbatimEnvironment{AVerb}{Verbatim}{commandchars=\\\{\}} \def\foo#1-#2;{} \begin{document} \begin{AVerb} \foo x-z; ...
1
vote
1answer
305 views

How do I embed Unicode G Cleff in a Verbatim environment?

I am writing a chapter on Unicode. I'm using LaTeX using the fancyvrb chapter and inputenc, which lets me type most unicode characters without problem. Problem: I want to include a character from the ...
3
votes
1answer
964 views

New command using inline verbatim

I would like to define a command using verbatim like in the commented line in the following code. \documentclass{article} \usepackage{amsmath,amsfonts,amssymb} % ...
6
votes
1answer
414 views

Determine number of lines in a verbatim environment

I'm trying to implement two new key-value pairs for the fancyvrb package: head= and tail= specify how many lines to display: That is, head=10, tail=5 specifies to print the first 10 lines of the ...
2
votes
1answer
2k views

fancyvrb alternate commandchars and \textcolor

The following works: \documentclass{article} \usepackage{fancyvrb} \usepackage{color} \begin{document} \begin{Verbatim}[commandchars=\\\{\}] test\textcolor{red}{foo}test \end{Verbatim} ...
1
vote
1answer
80 views

How to convince fancyvrb to give overfull warnings?

The following document \documentclass{article} \usepackage{fancyvrb} \begin{document} \hsize=1cm \begin{Verbatim} foo bar foo bar foo bar foo bar foo bar \end{Verbatim} \end{document} does not give ...
3
votes
1answer
398 views

fancyvrb, helvetica and underscore… is it just me?

Ran into some weirdness with fancyvrb, helvetica and _. Here's a MWE (for me): \documentclass{article} \usepackage{fancyvrb} \begin{document} \begin{Verbatim}[fontfamily=helvetica] Oh no! It's a ...
3
votes
2answers
600 views

Reduce space between Sinput and Soutput

I'm using Sweave in the book document class, and I'm getting really huge spacing between Sinput and Soutput evironments. \documentclass[11pt]{book} \usepackage{Sweave} \usepackage{boxedminipage} ...
1
vote
1answer
2k views

using fancyvrb Verbatim environment from within newenvironment

As with this question, I want to use a verbatim environment from within an environment definition, but I want the listings to be numbered, so I think I need to use fancyvrb. It appears that fancyvrb ...
6
votes
1answer
821 views

Problem about program code included in LaTeX

I have some Matlab code which I would like to include in my LaTeX document. I use fancyvrb package, based on which I define a new environment called code. An complete and minimum example is: ...
3
votes
2answers
733 views

“Missing number, treated as zero” with fancyvrb package

I was trying to use the package fancyvrb. However with \usepackage{breqn} \usepackage{fancyvrb} \DefineVerbatimEnvironment{code}{Verbatim}{fontsize=\small} ...
1
vote
1answer
244 views

How to make my unusual environment accept one argument?

I cannot find a good title to express my question. Therefore, please parse the following code first. Minimal Code \documentclass[dvips,dvipsnames,cmyk,table]{book} ...