{framed} is about framed document elements, e.g., boxes and environments. A popular package is {mdframed}.

learn more… | top users | synonyms

2
votes
1answer
709 views

How to create protocol flows inside a centred box?

Could you please give some directions how to create the following figure in latex? It is the situation of describing a two parties protocol centered in a box. It is like a 3X4 table but i have ...
3
votes
2answers
2k views

Trying to put a box around a collection of subfigures

I'm trying to have a bounding box around the following figure: \begin{figure}[htp] \begin{center} \subfigure[Process with no error]{\label{noerror}\includegraphics[width=1.5in]{noerror-process}} ...
1
vote
1answer
425 views

I can't move my box I made

Here is the problem, I made a box using \begin{tabular}[b]{|l|} \hline example \\ \hline \end{tabular} I have the [b] meaning bottom, but the position never changes ... In general how do I ...
6
votes
2answers
770 views

CSS border-top, border-bottom, border-right LaTeX equivalent

Is there an equivalent in LaTeX to the CSS border-top, border-bottom, border-right properties? I would like to underline and overline text with with a border on the right, not simply underline or ...
10
votes
1answer
368 views

Is it possible to frame text using a graphic border

I've got a document where in a few cases I'm using the framed package and a single \begin{framed} <text> \end{framed} to visually separate text that is something akin to commentry on the main ...
4
votes
1answer
249 views

Text environment with vertical header and border

I have no experience with creating latex environments, so I hope that someone would be so kind helping me trying to create a new text environment with a border and a vertical header to the right of ...
3
votes
1answer
872 views

How to set frame size in a listing

I'm trying to put a frame around my code, but the frame has the wrong dimension. How can I set them right? ...
6
votes
1answer
1k views

How do I remove padding from a framed box?

I am unable to use mdframed on my server so I am currently creating a framed box like this: \usepackage{framed} \begin{document} \begin{framed} \small{ \noindent \textbf{Key Results}:blah blah blah ...
4
votes
2answers
250 views

Placing long table inside \shadowbox

I have a multi-page table produced by long table package and I want to put each page of the longtable inside \shadowbox. Here is what I have tried: \documentclass{article} \usepackage{fancybox} ...
2
votes
1answer
494 views

Redefine \emph inside theorem using \newshadedtheorem from ntheorem

Using the ntheorem package, the definition of \newshadedtheorem overwrites the \theoremprework, which I wanted to use to redefine \emph inside a custom shaded theorem. The definition of ...
3
votes
1answer
207 views

Indenting text framed by a vertical rule

I would like to know how to modify the LaTeX based answer to this question so that the text left margin would be increased by a given amount. I've tried to change the value of \leftmargin, ...
7
votes
1answer
801 views

framed frame in beamer?

Below is an example of the layout I am trying to make for a beamer presentation: just a simple rounded black frame in which I could insert some contents (e.g. text or images). I have looked at ...
18
votes
2answers
514 views

How to make mdframed ignore descenders in last line

How can we make mdframed to ignore the descenders of the last line in the calculation of the innerbottomsep. In my eyes there are two reasons to desire this: Inner margin The optical bottom sep is ...
6
votes
2answers
535 views

Framed answer environment

I am trying to write a simple environment for the solutions of assessments I give. The code below defines such an environment: \newenvironment{answerenv}[1][Answer]{% Sets the default "Answer" but ...
4
votes
2answers
873 views

How to make this using LaTeX?

I have the following page from the book Mastering your PhD - P. Gosling and B. Noordam (Springer 2006), page 42: Now I wish to make this in LaTeX. I'm in particular interested in how we can make the ...
14
votes
2answers
7k views

How to highlight important parts (with a gray background)

In the below link http://www.math.uiowa.edu/~goodman/algebrabook.dir/bookmt.pdf the author highlights anything which is important using a greyish color background. For example, if you see ...
10
votes
4answers
521 views

Creating simple frames

I want some of my text to be "framed". So far, I have horizontal lines generated by the \separate command in the following MWE: \documentclass{article} \newcommand\separate{\medskip\hrule\medskip} % ...
2
votes
1answer
807 views

Frame around a page latex [duplicate]

Possible Duplicate: Creating Page Border for Single Page only Hello I need to put a double frame around an A4 page in latex. How to do this ? I looked into psframe. Did not quite get it !
12
votes
3answers
14k views

Change border color of \fbox [duplicate]

Possible Duplicate: Is there an \arrayrulecolor-like command to change the rule color of \fbox? I'm using an \fbox to have a border around a minipage. \fbox{ ...
14
votes
1answer
3k views

Box around a few items in an itemize environment

I'm using beamer and want to call out a few items in a list by drawing a box around them, and, ideally, having a small comment appear next to the box, like this:
6
votes
2answers
1k views

In listings, lines that are broken (option breaklines enabled) cause frame to be drawn badly. How do you fix this?

I have an lstlisting which has breaklines and frame enabled. The actual setting is as follows. \lstset{ basicstyle=\ttfamily, showstringspaces=false, breaklines=true, keywordstyle={}, ...
9
votes
3answers
628 views

Align text on top of a framebox

I am trying to create a series of boxes so that my students can input there id number for there final exam. \documentclass{article} \usepackage{amsmath} \usepackage{tikz} \newsavebox{\idbox} ...
4
votes
1answer
1k views

Indentation in \leftbar Environment

How do I control/remove the indentation automatically generated in the \leftbar environment? \documentclass[11pt,letterpaper]{amsbook} \usepackage{xcolor} \definecolor{lightgray}{gray}{0.90} ...
1
vote
1answer
292 views

endless loop with mdframed

The following code leads to an endless loop. pdflatex is at 100% CPU and the log is constantly increasing with number counted upwards. \documentclass{article} \usepackage{mdframed} \begin{document} ...
10
votes
1answer
1k views

Shaded continuous across new enumerate environment

I'm trying to write up solutions where I include the original problem text, in a light gray shaded box. I had been creating the shading with the 'framed' package shaded environment, but some of the ...
2
votes
1answer
776 views

Draw red box around verse

This is a follow-up question to: How to center a verse horizontally I am using the solution given by @Herbert. Is there a way to put a color box around selected few verses I desire?
7
votes
3answers
3k views

How can one prevent \fbox from running off the page?

I am using the \fbox command to box a large chunk of text: \fbox{Four score and seven years ago our fathers brought forth on this continent, a new nation, conceived in Liberty, and dedicated to the ...
17
votes
6answers
6k views

Text in squared box

I'd like to bot a square box around some text. I'd like to denote a labelled object of size 1, in combinatorics this is often symbolised by something like \boxed{1}. It would be nicer if the box was a ...
8
votes
1answer
926 views

Black and white emphasis for \boxed?

I am using \boxed to place emphasis on important equations in an assignment I am typing up, and would like to give the final answer a bit of extra emphasis. I'm using \begin{equation} ... ...
5
votes
3answers
1k views

Placing text and equations inside a box

I have a paragraph that contains text, inline equations and centred equations, and I'd like to put the whole thing in a box that's centred horizontally in the page. It's a key paragraph, so I wanted ...
16
votes
1answer
1k views

How to choose which sides of the border to draw in a `framebox`?

If, for example, you only want to draw the top and bottom border of a box, or perhaps the left and bottom only, is there a simple package to do this or must one resort to using tables or heavy-weight ...
4
votes
2answers
2k views

Wrap a wrapfigure and text by a border?

Is it possible to wrap a wrappicture with some text nearby by a frame?
44
votes
8answers
12k views

Highlight elements in the matrix

I have a matrix and need to highlight some elements in the matrix. I have found how to highlight a single element (I want to put the cell in the square): $$ A = \begin{bmatrix} \fbox{0} & ...
4
votes
1answer
2k views

Including multiple figures/subfigures within an fbox (minipage)

From what I understand, it's pretty much impossible to include floats within an fbox/minipage. I basically want a paragraph of framed text with a couple of subfigures included within the frame. Any ...
4
votes
1answer
547 views

Suppress top skip between own frame environment and itemize

I need to typset a book with a given definition of {itemize} and I added a {framed} environment by using mdframed. If the first line inside {framed} is normal text everything is fine but if it ...
8
votes
4answers
983 views

How can I insert a framed box inside a table?

I'm trying to accomplish the result in shown in following picture. So far I have tried : \begin{tabular}[h]{cm{5cm}m{5cm}c} fingerprint & Signature1 & \rule{5cm}{.5pt} & fingerprint ...
5
votes
3answers
3k views

fbox in tabular throws missing endgroup

I have to draw a border around my tables, so I'm using \fbox{} (is there a better way?). It works when using a threeparttable but with the normal tabular latex throws an error stating Missing ...
6
votes
2answers
181 views

Frame environment with fixed size given by numbers of characters and lines

I would like to make one framed environment with the following behavior. Only the last 8 lines of the content must be displayed. If the content have more than 8 lines, a gentle warning must be ...
12
votes
2answers
950 views

Gray box around figure with a separate gray box around caption

My university requires that all figures in a thesis follow this pattern: I'm very new to LaTeX, so far my best attempt has been this: \begin{SCfigure} \colorbox{darkgray}{ ...
18
votes
6answers
45k views

How to put a framed box around text + math enviroment

I am looking for something like \fbox but it seems that you cannot use it when a math environment is included. However its not only a math environment (then you could use \boxed I know) but also text, ...
4
votes
1answer
385 views

How to make boxes occupy two columns in twocolumn environment, without using float in LaTeX?

I am trying to create a new document class, similar to books, but with two columns and where new chapters always starts in a new page, printing the chapter name inside a box that should occupy two ...
13
votes
4answers
10k views

box around theorem statement

Is there an easy way to put a box around a theorem in LaTeX? For example to state an important theorem. I tried using page 20 of the ntheorem documentation ...
14
votes
4answers
1k views

Creating stackoverflow like tags

I'm trying to create stackoverflow like tags. Currently I'm using an \fbox{text} to create the tags, which works, but not all boxes have the same height (it seems that letters like 'p' make a box take ...
12
votes
4answers
6k views

LaTeX is putting a border around my figures

I'm trying to embed a few images in a figure, but LaTeX keeps putting a border around three of the sides. Is there any way for me to keep it from adding this border? The code that I used to create ...
7
votes
3answers
2k views

A beautiful border style

I need a border style that has a nice appearance. I've found something like this: \documentclass{book} \usepackage{tikz} \usetikzlibrary{calc} \usetikzlibrary{decorations.pathmorphing} ...
2
votes
1answer
1k views

Frame on lstlisting opened on the bottom when code longer than one page [duplicate]

In my \lstset I have: \lstset{ language=Java, % the language of the code basicstyle=\sffamily\large, % the size of the fonts that are used for the code %numbers=left, ...
6
votes
5answers
697 views

Formatting new environment with borders

I have defined myself a new environment as below: \newenvironment{myquote}{\list{}{\leftmargin=0.3in\rightmargin=0.3in}\item[]}{\endlist} What I would like to do here is to be able to format this ...
23
votes
1answer
2k views

How to place a shaded box around a section label and name

In working with a publisher, I need to format section headings like this (using ASCII art): +-----+-------------------------------------+ | 1.2 | Section name | ...
17
votes
1answer
10k views

How to draw frame with rounded corners around box

Is it possible to simply draw a frame around a box which has rounded corners, and be able to control frame width, frame color, frame radius, box background colour (preferably without having to use the ...
6
votes
2answers
637 views

how to eliminate the horizontal spacing of the frame in the framed package?

I'm using the framed package and I found it difficult to adjust the width of a frame to adapt to the current environment, e.g. if I use a shaded environment within the enumerate environment, I will ...