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

learn more… | top users | synonyms

32
votes
6answers
86k views

How to put a framed box around text + math environment

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, ...
1
vote
1answer
73 views

Reducing upper and lower margin in shaded environment

I am using \begin{shaded} from \usepackage{framed} to highlight some formulae and theorems in some notes I am writing. I would like to reduce the upper and lower margin: how can I do it?
10
votes
3answers
585 views

Boxed equation with number

My minimum working example: \documentclass{report} \usepackage{amsmath} \begin{document} \begin{center} \boxed{K_{k+1}=P_ka_{k+1}^T(a_{k+1}P_ka_{k+1}^T+I_N)^{-1}} \end{center} \end{document} ...
1
vote
2answers
36 views

Framed paragraph with double-line frame

Regarding various ways but most requires rigorous settings to embed a paragraph of words in a box or a frame with double-line box, I try to use a single commend to acquire the effect. However, ...
11
votes
5answers
23k views

How can I insert a newline in a framebox?

I have several frameboxes in my document, using the following command: \framebox(115,115){ R-Sq: \newline For example} I want to force a new line, but neither \newline or \\ appear to work. Is ...
7
votes
3answers
884 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 ...
0
votes
1answer
18 views

divider line inside framed environment

Adding a horizontal rule inside the framed environment, the line only spans the text area. But i want the line to span the complete box width. How do i do that? Current Code: \begin{framed} Foo.\\ ...
1
vote
2answers
29 views

How i can make a box figure with this alignments as attached?

I have a framed environment in a double column article. Inside the frame i have some lists i want to display. The problem is that i want the size of the frame to be expanded within the two columns. I ...
0
votes
2answers
52 views

Framed picture and framed caption

I need to insert picture in Latex book file, but picture must to be framed, and caption after picture also. That frame is not the same, picture and caption need horizontal line between. But picture ...
2
votes
1answer
31 views

Customize size for drawing box in matrix

\documentclass{beamer} \usetheme{Madrid} \usepackage{amsmath,tikz} \usetikzlibrary{matrix} \begin{document} \begin{frame}{Matrix} This is an example of a matrix. \begin{tikzpicture} \matrix [matrix ...
35
votes
4answers
77k views

Attractive Boxed Equations

I often used \boxed{...} from the AMS math package to place a box around important equations. However, this approach often produces somewhat awkward looking output. Consider \documentclass{article} ...
2
votes
3answers
123 views

How to make fbox around minipage fit the whole minipage inside it?

I have long equation, Ax=b that I want to put a frame around. I can't use mdframed since I need to also compile this with tex4ht, which still does not support mdframed. So I use this trick setup: ...
52
votes
9answers
17k 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} & ...
21
votes
5answers
16k views

What is the easiest way to get borders around a page in LaTeX?

I want my document to have borders in all pages. I imagine I can do that using TikZ, but is there an easier way to do it? I also asked this question here, but as the main question was something ...
1
vote
1answer
35 views

Nested boxes around cells in a table

I would like to nest two boxes in my table. It looks like this: content content content content content +----------------------+ content | content content | ...
0
votes
1answer
46 views

Frame only around theorem in scientific two column poster

I am creating a poster in beamer, I would like to have frame only around my theorem, not to the end of the page (especially having two columns), if anyone know how to modify the code to do that? ...
8
votes
2answers
1k views

SWOT Table - how to convert to an article?

I need a SWOT analyse in color, and I found this one at http://www.mostlycolor.ch/2013/10/colored-blocks-in-beamer.html : Can someone help me by converting the beamer, so I can use it in an ...
1
vote
1answer
123 views

Beamer: transparency of a picture on section frame depending of section number

I'm a new Beamer user. The following code is there just to explain what I intent to do: Put on the "sectionpage" frames a picture with transparency, the transparency level being function of the ...
3
votes
1answer
38 views

How do lines of \framebox'es line up?

I want to stack boxes. The frame lines of the boxes should be exactly on top of each other. The original question However, when I define two boxes, so that one starts where the other ends (spatially ...
2
votes
2answers
959 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 ...
2
votes
1answer
104 views

Simple frame around page

I need add a frame around all page in latex. If I search on google, I find many options, but anything work well for me. Also I need that page would be A4 and have margin 1.27cm. And on the top of ...
3
votes
1answer
118 views

Adding a border around beamer poster

I am trying to find a simple way to add a uniform border around a LaTeX poster, made in beamer, preferably in such a way that it is easy to modify the thickness. Here is the first part of the ...
2
votes
1answer
59 views

putting algorithm in box

Below is my code snippet. Please help me to put a framed box in my algorithm. \documentclass[journal,12pt]{IEEEtran} \usepackage{algorithmic} \usepackage{graphicx} \usepackage{algorithm} ...
1
vote
1answer
102 views

How we can design our own boxed titles?

\begin{tcolorbox} \centering I am a fool..\\ I dont know How to make this box small as text has. \end{tcolorbox} I am using the above code to create boxed titles in my notes.. My output is ...
4
votes
2answers
272 views

framebox and margins

I have 2 minipages, the second of which is \frameboxed. The \framebox command seems to push the minipage out into the right margin, as you can see. [This is not the same as a previous question: ...
0
votes
0answers
20 views

Shadowboxing theorem environment

This is how I would like to redefine my theorem environment. %\newenvironment{sbtheorem} % {\shabox{ \begin{minipage}{0.8\textwidth} \begin{theorem}} % {\end{theorem} \end{minipage} }} ...
1
vote
2answers
28 views

Putting a line into a frame with proper positioning

I wanted to use a header which looks like the image attached below. At first I tried using a fbox with a parbox but I had issues with the right widths because the text wasn't properly aligned at all. ...
7
votes
2answers
166 views

Align mathematics equation in a box

I have the following code of maths equation in a box : \begin{framed} \begin{align*} &C_\star \rightarrow E_\star : &x=3\dfrac{5\phi^2+24\phi+12v+24}{\phi^2}, ...
4
votes
3answers
224 views

fbox without additional v-space

it's a little bit related to Non-invasive replacement for \fbox? , but not really. think: \documentclass[12pt]{article} \begin{document} \footnotesize \begin{tabular}{lc} a & 1\\ a & 1\\ ...
4
votes
3answers
179 views

Horizontal placement of a framebox

I would like to horizontally offset a framed paragraph of text so that the sides of the frame coincide precisely with left and right margins of 2em on a page with a text-width of 6.5 inches. ...
1
vote
0answers
25 views

how to put Verbatim inside minipage that has fbox around it? “Paragraph ended before \FV@BeginScanning was complete. }” [duplicate]

I am surprised that I get an error when I add Verbatim to content of minipage that had \fbox around it. Removing the \fbox removes the error. But I need to put frame around the minipage. I can't use ...
4
votes
3answers
82 views

How can I set the horizontal separation only in a framebox?

I'm using the command \fcolorbox to add a framebox around an image. I want to set the horizontal separation only. With \fboxsep I set the separation all around. \documentclass[oneside]{article} ...
2
votes
1answer
184 views

Frame with padding/margins (without using mdframed)

I'm wondering how to add paddings in a frame (as you can see, left and right paddings are the same, but not the same as top and bottom paddings). I know it can be done using mdframed, but sometimes, ...
8
votes
2answers
355 views

Difference between \framebox{$$} and \boxed{}

I want to put an equation in a frame box. Is it the same that if I create a framed text box environment first then put the equation inside or use the environment \boxed{}? ...
3
votes
1answer
107 views

Customized frame with title over frame

I'm trying to have sections within titled-boxes in my document. My minimum almost-working example is: \documentclass[a4paper]{article} \usepackage{lipsum} ...
16
votes
5answers
10k 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 ...
35
votes
4answers
17k views

Can I have framed blocks in beamer?

Is there a simple way to have the body of a block environment in beamer to have a frame around it, rather than having a background colour? I tried putting a \fbox inside the block, but it just wrote ...
21
votes
3answers
2k views

create a framed environment for a margin note

What am trying to achieve is the following: Of course, if this can be done so that there is a switch between even and odd pages. Currently I am only interested in the not appearing on the LHS ...
15
votes
4answers
2k views

How can I construct a page layout with framed boxes?

For a report I'm writing, I have got an MS Word template for a page that needs to be included. The page looks like this (print screen from Word): However, there are a few things that makes me not ...
2
votes
2answers
71 views

Framed minipage and `comments` package

I am preparing a classroom workbook with two versions: one with answers and one without. The student version has big, empty, framed boxes to handwrite their answers. The teacher version has suggested ...
16
votes
4answers
22k views

How to draw a colored framebox without filling the background?

I like to draw a \fbox{..} which is colored. The xcolor package gives \fcolorbox{<frame color>}{<background color>}{<text>} But this forces me to set a background color. I like ...
6
votes
2answers
356 views

How to create a page like this?

I'm a LaTeX newbie. I want to create a page layout like in the picture below on every page. Can someone help please? Thanks.
2
votes
2answers
78 views

LaTex: Adding cell padding to a text frame

I'm trying to create a box as below in LaTeX. \framebox[40em][c]{ I certify that the work presented in the dissertation is my own unless referenced. } I want a little bit padding between the text ...
4
votes
1answer
336 views

Why is listings' frame width a little larger then \textwidth?

Here is the sample code: \documentclass[]{article} \usepackage{listings} \lstset{ basicstyle=\ttfamily\footnotesize, frame=single, % adds a frame around the code } \begin{document} ...
3
votes
2answers
268 views

How can I write framed formulas in my LaTeX document?

I am interested in this thing because I think that the framed formulas make my document more beautiful. For example how can I make this formula framed? $F=m\cdot a$ I would like to make a light ...
2
votes
1answer
85 views

lstlisting framed with the caption inside the frame

How do I made a lstlistings look like following? The best I could get was: The code for the second image is: \begin{lstlisting}[caption=id(in), frame=single] out <- in; return out; ...
2
votes
2answers
84 views

using framed within itemize or enumerate

I have the following code: \documentclass[a4paper,11pt]{book} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{lmodern} \usepackage{classicthesis} \usepackage{hyperref} ...
1
vote
2answers
171 views

How to force the tcolorbox package to cover the upper and lower part of pages?

The code \documentclass{book} \usepackage[many]{tcolorbox} \usepackage{lipsum} \begin{document} \chapter{Foo bar} \lipsum[1-2] \begin{tcolorbox}[size=tight,oversize, sharp corners, breakable, ...
27
votes
1answer
4k 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 | ...
1
vote
2answers
378 views

How to abbreviate “\begin{frame}”, “\end{frame}”, and “\frametitle”?

Aware abbreviating those commands need not always be helpful, I would like to know how to abbreviate them? The following is what I tried, which does not work: \documentclass[11pt,handout]{beamer} ...