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.

I have a simple two column document in ConTeXt. I tried to float/wrap the figures within text with `placefigure`, but it inserts the figures exactly where they are. This will leave a empty space in the previous column, if a figure is not fitted. enter image description here

In addition, ConTeXt ignore figure float positioning commands of top,bottom, etc. What should be the standard figure placement to float/wrap within the text?

\starttext
\startcolumns[n=2,tolerance=verytolerant]
\section{Introduction}
LaTeX is based on the idea that authors should be able to focus on the content of what they are writing without being distracted by its visual presentation. In preparing a LaTeX document, the author specifies the logical structure using familiar concepts such as chapter, section, table, figure, etc., and lets the LaTeX system worry about the presentation of these structures. It therefore encourages the separation of layout from content while still allowing manual typesetting adjustments where needed. This is similar to the mechanism by which many word processors allow styles to be defined globally for an entire document or the use of Cascading Style Sheets to style HTML.
\placefigure[top,bottom][fig:1]{LaTeX can be arbitrarily extended by using the underlying macro language to develop custom formats. Such macros are often collected into packages, which are available to address special formatting issues such as complicated mathematical content or graphics. Indeed, in the example below, the align environment is provided by the amsmath package.
}
{\externalfigure[1.png][width=\textwidth]}
LaTeX is based on the idea that authors should be able to focus on the content of what they are writing without being distracted by its visual presentation. In preparing a LaTeX document, the author specifies the logical structure using familiar concepts such as chapter, section, table, figure, etc., and lets the LaTeX system worry about the presentation of these structures.
\stopcolumns
\stoptext
share|improve this question
2  
Discussed at wiki.contextgarden.net/… . I know nowt about this topic myself, so I can't tell you whether that text is useful. –  Esteis Aug 23 '12 at 20:48
    
Very using link. I was using the pdf manual, which is not very complete, and I was unaware of columnsets. It is better than other tricks introduced there. –  All Aug 23 '12 at 21:10
1  
I'm glad. :-) Could you post the columnsets code you end up using as an answer, and accept it? It will help others looking for an answer, and get this question out of the "unanswered" queue. –  Esteis Aug 24 '12 at 7:27
add comment

1 Answer

To float images, contextgarden's Using Graphics describes two ways. Either using starthanging, like:

\starttext
\starthanging[location=right,n=2,distance=1cm]{\externalfigure[cow][width=4cm]}
    \input tufte
\stophanging
\stoptext

or using Floating Objects, which are numbered and placed by ConTeXt, and can get a caption, like:

\placefigure[right]{My Caption}{\externalfigure[cow.jpg]}
share|improve this answer
add comment

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.