Re: Captions at top of tables
Shane Siers írta: >Hi, all. This should be an easy one, but I just spent an hour trolling Google >and discussion forums and still don't know:> > I want my float captions to be at the bottom for figures (default) and at the top for tables -- there is where I'm having the problem. I tried putting the table (a Sweave chunk) below the caption in the float, but on compilation this just printed the chunk code as text.> > > I hope this has an easy answer...let me know if I have to spend 20 minutes paring my document down to a useable example.-- > Shane> > Hello: I use the caption and floatrow packages together to set floating tables/figures and their captions. They are very powerful, even might be overkill for your purpose. Unfortunately the floatrow manual is overwhelming and hard to understand at first. You can find the manuals here: http://www.ctan.org/pkg/caption http://www.ctan.org/pkg/floatrow bcsikos
Re: Captions at top of tables
Have you read the recent manual? There is an example for creating tables in Sweave (PDF version at https://github.com/downloads/yihui/lyx/sweave.pdf; lyx source is shipped with LyX 2.0.2 and also available at https://github.com/yihui/lyx/raw/master/examples/sweave.lyx) Regards, Yihui -- Yihui Xie Phone: 515-294-2465 Web: http://yihui.name Department of Statistics, Iowa State University 2215 Snedecor Hall, Ames, IA On Fri, Jan 13, 2012 at 12:39 AM, Shane Siers wrote: > Hi, all. This should be an easy one, but I just spent an hour trolling > Google and discussion forums and still don't know: > > I want my float captions to be at the bottom for figures (default) and at > the top for tables -- there is where I'm having the problem. I tried > putting the table (a Sweave chunk) below the caption in the float, but on > compilation this just printed the chunk code as text. > > I hope this has an easy answer...let me know if I have to spend 20 minutes > paring my document down to a useable example. > > -- > Shane > >
Re: Captions at top of tables
On Thu, 12 Jan 2012, Shane Siers wrote: I want my float captions to be at the bottom for figures (default) and at the top for tables -- there is where I'm having the problem. Shane, These are the defaults for both figures and tables. When you open a float for a figure you see the caption box. When you enter the text you want, move the cursor to the line above it and enter the figure. When you create a table float, enter the caption then put the cursor on the following row before inserting the table. You can then change the environment to LyX code if you wish. Rich
Re: Captions... can't be justified
It seems that by default captions are centered when they're less than one line long, and justified when they're longer than one line. The best bet to change this appears to be the caption package. Try adding this to your document's preamble: \usepackage[singlelinecheck=off]{caption} For more information about the caption package, see this page: http://www.ctan.org/tex-archive/help/Catalogue/entries/caption.html Jim > > I'm using 'tables' for placing some of my photos and captions into. Thanks! FN > > Frederick Noronha :: +91-9822122436 :: +91-832-2409490 > More books from Goa :: http://goa1556.goa-india.org/ >
Re: captions to graphics are sometimes centred and sometimes not
On 2010-04-04, Richard Brown wrote: > Using 1.6.5 on ubunto 9..10, and komascript book, I have some photographs > insert in floats. Each photograph has a caption. Sometimes the captions are > centred on the page, and sometimes they are left justified- and I can see no > difference whatsoever in the procedure I adopted (Insert float, + insert > graphics) or in the source code. The only difference is that some captions > are longer than others. This is exacly the reason: captions that fit on one line are centered by some layout styles. The KOMA-script documentation (scrguien.pdf) will tell you how you can configure this via document options or code in the LaTeX preamble. Günter
Re: captions to graphics are sometimes centred and sometimes not
On 4/4/2010 2:06 PM, Richard Brown wrote: Using 1.6.5 on ubunto 9..10, and komascript book, I have some photographs insert in floats. Each photograph has a caption. Sometimes the captions are centred on the page, and sometimes they are left justified- and I can see no difference whatsoever in the procedure I adopted (Insert float, + insert graphics) or in the source code. The only difference is that some captions are longer than others. For instance, this is centred: % Preview source code for paragraph 43 % \begin{figure}[H] \includegraphics[width=3.65in]{bolzano_esterno} \caption{La sala del commiato a Bolzano.} \end{figure} And this is left justified: % Preview source code for paragraph 45 % \begin{figure}[H] \includegraphics[width=3.65in,height=2.3in]{bolzano_crocefisso} \caption{Bolzano, il catafalco. ~Da notare i simboli religiosi non \protect \\ sono fissi. } \end{figure} Wherein lies the difference? Can't reproduce it here. Can you post a barebones example (minimal LyX file)? I notice that you are not centering the images within the floats, so the images will be left-justified. When I do it here, though, the captions are centered. (Also, the second caption is a single line here. Is it supposed to be two lines for you?) /Paul
Re: Captions
Am Friday 21 August 2009 11:28:40 schrieb solvi.natl...@uis.no: > Hi! > > Does anybody know, how can get rid of the indentations in my float caption > texts (for both figures and tables)? > > Figure 1: Now my text looks like this, > here begins the 2nd line of the caption. > > Figure 2: And I would like to have something like > this, where there isn't an indent in the 2nd line. > > Document-class: book(KOMA-script) > LYX version 1.6.3 for Windows. > I am using \setcapindent{0mm} in the preamble under book(KOMA-script) ( LYX version 1.6.3 for Linux) Wolfgang > I have tried different things I found on the internet, both ERT and > commands for the preamble but so far nothing has worked out - either > nothing happens or I get lots and lots of errors. I have looked in the > KOMA-manual but I just don't undrstand it- I basically needs an > explanation for dummies :D > > It should be mentioned that I already have this defined in the preamble: > > \usepackage[dvips=false% > ,pdftex=false% > ,vtex=false% > ,twoside% > ,papersize={170mm,240mm}% --- A4 with 20mm cut on both sides and 28.8mm > cut top and bottom > ,hdivide={24mm,*,24mm}% --- 122mm text width, 24mm margin both sides (no > binding edge!) > ,vdivide={11.5mm,*,17.5mm}% --- 28.5+11.5=40mm from top of A4 to text > (46mm at bottom) > ,includehead% > ,includefoot% > ]{geometry} > \usepackage[a4,cam,axes,noinfo,center]{crop} % For printing crop-marks on > a4 manuscript > \usepackage{fancyhdr} > \pagestyle{fancy} > \renewcommand{\chaptermark}[1]{\markboth{\uppercase{#1}}{}} > \renewcommand{\sectionmark}[1]{\markright{\uppercase{#1}}} > \fancyhf{} > \fancyhead[LE,RO]{\small \thepage} % Left on Even numbered pages & Right > on Odd > \fancyhead[LO]{\small \slshape \rightmark} % Left on Odd (Right-hand page) > \fancyhead[RE]{\small \slshape \leftmark} % Right on Even (Left-hand page) > \renewcommand{\headrulewidth}{0.5pt} > > I really hope someone can help me with this and please give me the > dummy-version :D -- - Wolfgang Engelmann Schlossgartenstrasse 22 D-72070 Tübingen Tel 07071 68325
Re: Captions
Hi, the most effective way (as far as I know) to customise float capions is to use the package caption which provides several options. I use it in connection withLyX and the KOMA script report class and I obtain what I want. If it is not included in your LaTeX distribution you can download it from: http://www.ctan.org/tex-archive/macros/latex/contrib/caption/ and install in your computer. Then in you preamble you should put the following lines: \usepackage{caption} \captionsetup[table]{format=plain,skip=\medskipamount} % for tables \captionsetup[figure]{format=plainskip=\medskipamount} %for figures Check the documentation with all the options you can use at http://www.ctan.org/get/macros/latex/contrib/caption/caption-eng.pdf Best wishes Pierfranco 2009/8/21 > > Hi! > > Does anybody know, how can get rid of the indentations in my float caption > texts (for both figures and tables)? > > Figure 1:Now my text looks like this, >here begins the 2nd line of the caption. > > Figure 2:And I would like to have something like > this, where there isn't an indent in the 2nd line. > > Document-class: book(KOMA-script) > LYX version 1.6.3 for Windows. > > I have tried different things I found on the internet, both ERT and > commands for the preamble but so far nothing has worked out - either nothing > happens or I get lots and lots of errors. I have looked in the KOMA-manual > but I just don't undrstand it- I basically needs an explanation for dummies > :D > > It should be mentioned that I already have this defined in the preamble: > > \usepackage[dvips=false% > ,pdftex=false% > ,vtex=false% > ,twoside% > ,papersize={170mm,240mm}% --- A4 with 20mm cut on both sides and 28.8mm cut > top and bottom > ,hdivide={24mm,*,24mm}% --- 122mm text width, 24mm margin both sides (no > binding edge!) > ,vdivide={11.5mm,*,17.5mm}% --- 28.5+11.5=40mm from top of A4 to text (46mm > at bottom) > ,includehead% > ,includefoot% > ]{geometry} > \usepackage[a4,cam,axes,noinfo,center]{crop} % For printing crop-marks on > a4 manuscript > \usepackage{fancyhdr} > \pagestyle{fancy} > \renewcommand{\chaptermark}[1]{\markboth{\uppercase{#1}}{}} > \renewcommand{\sectionmark}[1]{\markright{\uppercase{#1}}} > \fancyhf{} > \fancyhead[LE,RO]{\small \thepage} % Left on Even numbered pages & Right on > Odd > \fancyhead[LO]{\small \slshape \rightmark} % Left on Odd (Right-hand page) > \fancyhead[RE]{\small \slshape \leftmark} % Right on Even (Left-hand page) > \renewcommand{\headrulewidth}{0.5pt} > > I really hope someone can help me with this and please give me the > dummy-version :D > > > >
Re: captions for longables
gwyn hopkins schrieb: I know that there is an ugly hack for getting numbered captions Do you mean the one given in the EmbeddedObjects manual of LyX 1.4.4? In LyX 1.5 (will be released in two weeks or so) you will be able to insert captions to longtables nearly as for all other captions. regards Uwe
Re: Captions
> "Helge" == Helge Hafting <[EMAIL PROTECTED]> writes: Helge> From a user perspective, there is nothing strange about Helge> inserting a caption in the text. It seems natural that the Helge> caption is a property of the table/figure, not the float. Is it Helge> a figure or a table? Insert a "table caption" or a "figure Helge> caption" then. :-/ Yes. Helge> This gives a meaningful hint. Although the real bug probably is Helge> that it was possible to manufacture such a document in the Helge> first place. The caption inset will solve that. JMarc
Re: Captions
Jean-Marc Lasgouttes wrote: "Trevor" == Trevor Nicholls <[EMAIL PROTECTED]> writes: Trevor> Why does the "caption" style in stdlayouts.inc display Trevor> "Senseless!" I've got a section which includes some text, a Trevor> table, and some more text. The table has to appear in a Trevor> specific location between certain paragraphs so it is a fixed Trevor> table not a floating one, and it could certainly use a Trevor> caption, so on the face of it "caption" looks like the right Trevor> tool for the job. First, I tend to disagree in general with table that _have_ to appear between two particular paragraphs. But after all, it is your document, not mine :) Solution: create a Table float, put your table and caption inside it. Then Edit>Float Settings... will allow you to select 'here definitely' as placement. Trevor> * Why tell me that a caption is senseless? * Why *is* a Trevor> caption senseless here? Because there is no way to know whether to write 'Figure 1' or 'Table 1'. Trevor> * And why define a senseless style in the standard delivery in Trevor> the first place? A caption should be in a float. As any latexer will know - but he is probably not a latex guy then. From a user perspective, there is nothing strange about inserting a caption in the text. It seems natural that the caption is a property of the table/figure, not the float. Is it a figure or a table? Insert a "table caption" or a "figure caption" then. :-/ I don't see a good way to make this intuitive and also keep good latex compatibility. Well, LyX could put an implicit "Here definitely!" float around the nonfloating label when exporting to latex. This would sometimes lead to label and caption being separated by a page break though. Instead of the text "senseless!", how about "Caption works only inside a float!" ? This gives a meaningful hint. Although the real bug probably is that it was possible to manufacture such a document in the first place. Helge Hafting
Re: Captions
> "Trevor" == Trevor Nicholls <[EMAIL PROTECTED]> writes: Trevor> Why does the "caption" style in stdlayouts.inc display Trevor> "Senseless!" I've got a section which includes some text, a Trevor> table, and some more text. The table has to appear in a Trevor> specific location between certain paragraphs so it is a fixed Trevor> table not a floating one, and it could certainly use a Trevor> caption, so on the face of it "caption" looks like the right Trevor> tool for the job. First, I tend to disagree in general with table that _have_ to appear between two particular paragraphs. But after all, it is your document, not mine :) Solution: create a Table float, put your table and caption inside it. Then Edit>Float Settings... will allow you to select 'here definitely' as placement. Trevor> * Why tell me that a caption is senseless? * Why *is* a Trevor> caption senseless here? Because there is no way to know whether to write 'Figure 1' or 'Table 1'. Trevor> * And why define a senseless style in the standard delivery in Trevor> the first place? A caption should be in a float. JMarc
Re: captions in LYX
RENARD Francois 144138 wrote: Does somebody know how to modify the apparence of all legends in LYX ? (modify size of characters, of margins etc.) I found no option in LYX to do that. I tried to use the package "caption", but it had no effects on the legends in my document. But to use caption is exactly what you have to do. Could you send a short example file, where captions doesn't work? regards Uwe
Re: captions in LYX
RENARD Francois 144138 wrote: > Hello, > > Does somebody know how to modify the apparence of all legends in LYX ? > (modify size of characters, of margins etc.) > I found no option in LYX to do that. > > I tried to use the package "caption", but it had no effects on the > legends in my document. Hi, François You need to use a little bit of latex magic in your Preamble. For example: %% Set the sections to be bold but otherewise the same size %% as normal text \newlength{\spaceUnderSection} \newlength{\spaceOverSection} \setlength{\spaceUnderSection}{0.1ex plus .2ex} % \setlength{\spaceOverSection}{1.5ex plus -1ex minus-.2ex} % [EMAIL PROTECTED] [EMAIL PROTECTED] {\spaceOverSection}% {\spaceUnderSection}% {\normalfont\bfseries}} %% Frame the figures \renewenvironment{figure}[1][tbph] [EMAIL PROTECTED] [EMAIL PROTECTED] %% Set the captions to be italic \newcommand\myCaption[1]{\itshape\refstepcounter{figure}% \begin{center}\figurename\ \thefigure :\ #1\end{center}\upshape} \let\caption\myCaption -- Angus
Re: Captions of figures an tables
Am Dienstag, 05.08.03 um 10:46 Uhr schrieb Juergen Spitzmueller: Katrin Pietzsch wrote: 1. i'd like to set the captions width to the tables/ figures width. Which package do i need and how do I set the captionwidth? If you're using a (fairly recent) koma class, you can use \setcapwidth[alignment]{width} (have a look at scrguide, section 3.6) Else the package caption2 provides a command \captionwidth i am using the standard book class, so i suppose \setcapwidth[alignment]{width} is no option for me, unless there is a possibility to tell lyx to use this specific koma-script-command - is there? i tried using caption2 instead, but something went wrong. In the latex-preamble (layout -> latex-preamble) i inserted a \usepackage{caption2} and right before the tablecaption i wrote in TeX-mode: \captionwidth{10cm}. Judging by the error-messages i got, this is not the right way to do it. The error-messages are as follows: ! Missing number, treated as zero. { l.5421 \captionwidth{ 10cm} A number should have been here; I inserted '0'. (If you can't figure out why I needed to see a number, look up 'weird error' in the index to The TeXbook.) and ! Illegal unit of measurement (pt inserted). { l.5421 \captionwidth{ 10cm} Dimensions can be in units of em, ex, in, pt, pc, cm, mm, dd, cc, bp, or sp; but yours is a new one! I'll assume that you meant to say pt, for printer's points. [...] Actually, I meant to say cm, so what did I do wrong? What's the proper way of telling lyx to use caption2? I don't have the TeXbook, otherwise I'd give it a shot to learn more about weird errors. :) 2. is there a way to tell the list of figures/ list of tables to make shorter entries (some of my tables have the source added in brackets, but i don't want this displayed in the list of tables). At the beginning of the caption text: Insert->Short Title The short title will be used for headings and lof/lot. that worked fine! thanks :) Regards, Katrin
Re: Captions of figures an tables
Katrin Pietzsch wrote: > i am using the standard book class, so i suppose > \setcapwidth[alignment]{width} > is no option for me, unless there is a possibility to tell lyx to use > this specific koma-script-command - is there? No. > i tried using caption2 instead, but something went wrong. In the > latex-preamble (layout -> latex-preamble) i inserted a > \usepackage{caption2} correct (there are lots of layout options for the package. You might consult the documentation, which is only available in german as "anleitung.tex"). > and right before the tablecaption i wrote in TeX-mode: > \captionwidth{10cm}. Judging by the error-messages i got, this is not > the right way to do it. The error-messages are as follows: actually, \captionwidth returns the current length. Try \setcaptionwidth{10cm} (at the beginning of the float). Juergen.
Re: Captions of figures an tables
Katrin Pietzsch wrote: Hi, some of the tables and figures i inserted in my paper have quite long captions. Now there are two things i'd like to do: 1. i'd like to set the captions width to the tables/ figures width. Which package do i need and how do I set the captionwidth? 1. Make a figure/table float as usual. 2. Put a minipage with the desired width in the float. (Make sure the minipage is inserted in "normal text", not "caption" text) 3. Put your figure/table and the caption text inside the minipage. Overly long captions will now break to that width. This use of minipages also lets you put several figures besides each other (or above each other) in the same float. This because you may have one caption per minipage. Nice if you have thin figures or figures that belong together. Helge Hafting
Re: Captions of figures an tables
Katrin Pietzsch wrote: > 1. i'd like to set the captions width to the tables/ figures width. > Which package do i need and how do I set the captionwidth? If you're using a (fairly recent) koma class, you can use \setcapwidth[alignment]{width} (have a look at scrguide, section 3.6) Else the package caption2 provides a command \captionwidth > 2. is there a way to tell the list of figures/ list of tables to make > shorter entries (some of my tables have the source added in brackets, > but i don't want this displayed in the list of tables). At the beginning of the caption text: Insert->Short Title The short title will be used for headings and lof/lot. HTH, Juergen.
Re: Captions of figures an tables
Katrin Pietzsch schrieb: some of the tables and figures i inserted in my paper have quite long captions. Now there are two things i'd like to do: 1. i'd like to set the captions width to the tables/ figures width. Which package do i need and how do I set the captionwidth? 2. is there a way to tell the list of figures/ list of tables to make shorter entries (some of my tables have the source added in brackets, but i don't want this displayed in the list of tables). have a look at http://www.perce.de/LaTeX/hvfloat/ The package offers what you need. Herbert
Re: captions apart from floats
Max Bian wrote: > As I understand, all figures should take one page by itself and labeled > as "Figure XX" only, where XX is the number. And all the captions > should be listed in a sheet seperate from all the figures. > > I want this too! write in preamble: \usepackage{endfloat} \let\Caption\caption \renewcommand\caption[1]{% \Caption[#1]{}% } and insert your listoffigures as usual. With this trick you can not use the short caption option like \caption[short for toc]{long for caption} Herbert -- http://www.educat.hu-berlin.de/~voss/lyx/
Re: captions apart from floats
As I understand, all figures should take one page by itself and labeled as "Figure XX" only, where XX is the number. And all the captions should be listed in a sheet seperate from all the figures. I want this too! Max --- Dekel Tsur <[EMAIL PROTECTED]> wrote: > On Fri, Sep 27, 2002 at 11:30:55AM +0200, Martijn Brouwer wrote: > > I am preparing an article (revtex), and have to print all floats > after > > the text. This can be achieved using the endfloats option of > revtex. But > > I am also required to separate the figure text (captions) from the > > figures themselves. Do not ask me why, I think this is stupid too, > but > > my supervisor wants it this way. Scientific Workplace can do this, > so I > > suppose latex can do this too. How can I achieve this with LyX? > > It is not clear what you want. > Where exactly should the captions be placed? __ Do you Yahoo!? New DSL Internet Access from SBC & Yahoo! http://sbc.yahoo.com
Re: captions apart from floats
On Fri, Sep 27, 2002 at 11:30:55AM +0200, Martijn Brouwer wrote: > I am preparing an article (revtex), and have to print all floats after > the text. This can be achieved using the endfloats option of revtex. But > I am also required to separate the figure text (captions) from the > figures themselves. Do not ask me why, I think this is stupid too, but > my supervisor wants it this way. Scientific Workplace can do this, so I > suppose latex can do this too. How can I achieve this with LyX? It is not clear what you want. Where exactly should the captions be placed?
Re: Captions no Appearing
On Thu, Sep 05, 2002 at 10:23:52AM +0200, Jean-Marc Lasgouttes wrote: > Chris McCarthy wrote: > > Hi And sorry for the lameness of this question: I can insert a figure fine > > using INSERT > FIGURE > After picking the .ps file, I type some text into > > the box in the 2nd popup which says "Caption", but that text never appears. > > > > Alternatively, if I select "Caption" style from the pulldown menu on the > > upper left, I get the word "Senseless", which then becomes very difficult > > to remove or edit. > > > > Thanks for your help with this "Senseless" question > > You have to insert these things in a float inset. And use the "Caption" style from the toolbar (not the text box in the popup).
Re: Captions no Appearing
Chris McCarthy wrote: > Hi And sorry for the lameness of this question: I can insert a figure fine > using INSERT > FIGURE > After picking the .ps file, I type some text into > the box in the 2nd popup which says "Caption", but that text never appears. > > Alternatively, if I select "Caption" style from the pulldown menu on the > upper left, I get the word "Senseless", which then becomes very difficult > to remove or edit. > > Thanks for your help with this "Senseless" question You have to insert these things in a float inset. JMarc