Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

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 manipulate the box to where I want it to be?

Please no fancy packages to install, I am new to this stuff

EDIT: Does anyone know how to add the boxes within \begin{align*} ... \end{align*}?

share|improve this question
1  
Do you want it to float with the document, or remain fixed somewhere? If so, be specific about the location. –  Werner May 13 '12 at 4:40
    
The [b] argument will align the tabular to its bottom baseline. You only have one line, so this doesn't change anything. Note that you can draw a frame around some text using \fbox, no need to misuse tabular for this. Please update your question and state what you are trying to achieve. At the moment it's very vague and confusing, especially your align* edit. –  Martin Scharrer May 13 '12 at 7:47
    
What do you mean with Please no fancy packages to install, I am new to this stuff If you have installed TeX Live or MikTeX, nearly every package will be available by \usepackage. –  Marco Daniel May 13 '12 at 12:33

1 Answer 1

up vote 3 down vote accepted

tabular is non - floating body. Hence you need not use [b] for it. Remove the option and put the code where you want the box to appear. It does the job.

The following example shows various possibilities of placing the box (Still I am afraid that it is not clear to me where to place the box according to the question)

\documentclass{article}    
\usepackage{lipsum}
% ----------------------------------------------------------------
\begin{document}
% ----------------------------------------------------------------
\lipsum[1]
\hspace*{\fill}
\begin{tabular}{|l|}
    \hline
     example \\
     \hline
     \end{tabular}

\begin{parbox}[t]{0.818\textwidth}%
\hfill
\begin{tabular}{|l|}
    \hline
     example \\
     \hline
     \end{tabular}
\end{parbox}
%
\begin{minipage}[c]{\textwidth}
\hfill
\begin{tabular}{|l|}
    \hline
     example \\
     \hline
     \end{tabular}
\end{minipage}

\begin{minipage}[c]{\textwidth}
\centering
\begin{tabular}{|l|}
    \hline
     example \\
     \hline
     \end{tabular}
\end{minipage}
\begin{minipage}[l]{\textwidth}
\begin{tabular}{|l|}
    \hline
     example \\
     \hline
     \end{tabular}
\end{minipage}
\lipsum[2]
\end{document}

enter image description here

share|improve this answer
    
Still doesn't work. For instance, I am trying to make it appear in the middle of the page, but to the right. trying to make a point distribution thing for an exam. –  sidht May 13 '12 at 4:23
    
you want it to be flushed to the right? –  Harish Kumar May 13 '12 at 4:25
    
Yeah, somewhere in the middle to the right –  sidht May 13 '12 at 4:32
    
@jak: See the edit and let me know.. –  Harish Kumar May 13 '12 at 4:38
    
Yes, the first three "examples" are what I need. –  sidht May 13 '12 at 4:42

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.