Xref: utzoo comp.text:7466 comp.text.tex:3517 Path: utzoo!attcan!uunet!ogicse!ucsd!scubed!s3snorkel!rankin From: rankin@s3snorkel.ARPA (Tom Rankin) Newsgroups: comp.text,comp.text.tex Subject: LaTeX: figure placement and centering Keywords: LaTeX, report, figure, centering, center, samepage Message-ID: <457@scubed.SCUBED.COM> Date: 24 Oct 90 21:39:41 GMT Sender: usenet@scubed.SCUBED.COM Reply-To: rankin@scubed.scubed.com (Tom Rankin) Followup-To: comp.text Organization: S-CUBED (San Diego) Lines: 91 I've exhausted all of my patience and resources trying to solve these problems. With any luck, someone here can offer salvation. I am using: TeX, C Version 2.93 LaTeX Version 2.09 - Released 19 April 1986 My source is written using the report style, however, changing to the book style didn't seem to effect any of my results in the least. I haven't tried the article style since I'm using \chapter sectioning (and article.sty doesn't have \chapter). Here are my problems: 1. Location of figures. I'm attempting to specify that I would like my figures to appear "here", as in *right* *here*!, using the following construct: \begin{figure}[h] [...contents of figure...] \end{figure} The figures are consistently coming up at the *end* of my document, not in-line as desired (and as advertised by the "here" location specifier). Very frustrating. How do I have to hold my mouth to get this to work? 2. Centering the tabbing environment within a figure. I'm trying to center a \tabbing environment using either of the following constructs: \begin{figure}[h] \centering \begin{tabbing} [...tabbing stuff...] \begin{tabbing} \end{figure} OR \begin{figure}[h] \begin{center} \begin{tabbing} [...tabbing stuff...] \end{tabbing} \end{center} \end{figure} The result is the same in both cases, the material withing the tabbing environment ends up left justified. I do have a couple of figures that use the tabular environment and they center properly using the same two techniques. Although I could probably use the tabular environment in place of the tabbing one I'm using, it would be a misuse of the tabular environment (the tabbing environment, on the other hand, serves my purpose *exactly* -- except I can't get the damn thing centered on the page). 3. Getting \samepage to work as advertised. I've tried on numerous occasions to creat sections of text that are delimited on the top and the bottom by \rule lines (used for in-line EXAMPLES). I'd like to get the entire example to appear on a single page without stranding part of the example (usually a single rule line) on a separate page. My attempt to get this to happen looks like this: {\samepage \noindent \rule{127mm}{.1mm} \vspace{-2mm}\\ {\large \bf EXAMPLE:} Example Title \\ [...text of example] \noindent \rule{127mm}{.1mm} } but the \samepage environment seems to be wholly ignored. The results are the same with or without the \samepage declaration. By the way, these examples are much shorter than a full page, so they should be able (at the very least) to be pushed onto the top of a following page. Hep me, hep me...please! Tom Rankin rankin@scubed.scubed.com -------------------------------------------------------------------------- Tom Rankin Maxwell Laboratories, S-CUBED Division 3398 Carmel Mtn Rd. rankin@scubed.scubed.com (619) 587-8394 San Diego, CA 92121 --------------------------------------------------------------------------