ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Ursula Hermann via ntg-context <ntg-context@ntg.nl>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Cc: Ursula Hermann <ursula.hermann@univie.ac.at>
Subject: Re: Floating Figure in framed-environment
Date: Wed, 19 Oct 2022 11:52:33 +0000	[thread overview]
Message-ID: <8c8e3a14c47340249d49870636240a23@univie.ac.at> (raw)
In-Reply-To: <166617189408.7.7542558523685252324.69917366@privly.pm>

Dear Oliver, 

maybe something like this? 
This is my example: 
\starttext

\setuppapersize
  [A5]

\setupexternalfigures
  [location=default]

\setupindenting
  [yes, small]

\setupwhitespace
  [small]

\defineframedtext
  [prettyblock]
  [width=10cm,
   indenting={yes, small},
   background=color, backgroundcolor=lightgreen,
   foreground=color, foregroundcolor=black,
   offset=2mm,
   align=flushleft]

\starttext

\startprettyblock
\setupindenting[next]
  The Earth, as a habitat for animal life, is in old age and has a fatal
  illness. Several, in fact.

  It would be happening whether humans had ever evolved or not.

  \placefigure
[][fig:church]
{Stephanus Church.}
{\externalfigure[ma-cb-24][width=.4\textwidth]}

\stopprettyblock
\setupindenting[next]
Below, we have two separate columns; but up here, for the nonce, we have but
the one.

\startcolumns [n=2]
  Text, text, text \dots
  all in the first column
\column
  Words, words, words \dots
  all in the second column.
  And look ye here! Even more words!
\stopcolumns

\stoptext

Many regards
Uschi 

-----Ursprüngliche Nachricht-----
Von: ntg-context <ntg-context-bounces@ntg.nl> Im Auftrag von Oliver Sieber via ntg-context
Gesendet: Mittwoch, 19. Oktober 2022 11:31
An: ntg-context@ntg.nl
Cc: Oliver Sieber <context-ml@privly.pm>
Betreff: [NTG-context] Floating Figure in framed-environment

Dear ConTeXt Users

I am relatively new to context and I am suffering with a problem with the framed environment.

I want to use a framed textbox for Definitions in my script. I also want to use floating figures.  But this does not work and I haven’t found out why. Maybe I totally use it the wrong way. I would appreciate if someone could help me or has a tipp.

Here is an example code, where the figure does not behave as expected, i.e. the figure is behind the text:

\starttext
\framed[corner=round, rulethickness=2pt, width=\textwidth, align=flushleft, offset=1em,background=color,framecolor=black]
{{\bf Definition: Hello World} \blank[medium] 

\placefigure[right, none]{This is an example of a logo.}{\externalfigure[dummy]}

Carrot cake tiramisu lollipop dragée lollipop marshmallow carrot cake sweet pastry. Tiramisu danish jelly tootsie roll tart gummi bears. Carrot cake chupa chups cake wafer lemon drops lemon drops tiramisu. Chocolate lemon drops sugar plum cheesecake jelly beans sugar plum. Tootsie roll cupcake jujubes pie chocolate bar bear claw chupa chups shortbread. Candy candy canes jelly-o jelly beans sugar plum muffin danish donut. Bonbon lemon drops powder jujubes marshmallow biscuit halvah. Powder carrot cake caramels chocolate cake carrot cake jelly-o. Topping danish tootsie roll gummi bears oat cake jujubes. Sweet candy canes cotton candy pie topping. Jelly-o carrot cake ice cream lemon drops macaroon gummies lemon drops tiramisu chocolate cake. Cupcake sugar plum shortbread gummi bears tootsie roll. Chocolate cake sugar plum macaroon candy canes chocolate bar donut cake icing tootsie roll.
}
\stoptext


Best regards
Oli
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : https://contextgarden.net
___________________________________________________________________________________
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : https://contextgarden.net
___________________________________________________________________________________

  reply	other threads:[~2022-10-19 11:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-19  9:31 Oliver Sieber via ntg-context
2022-10-19 11:52 ` Ursula Hermann via ntg-context [this message]
2022-10-19 15:35   ` Oliver Sieber via ntg-context
2022-10-19 16:38 ` Wolfgang Schuster via ntg-context

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8c8e3a14c47340249d49870636240a23@univie.ac.at \
    --to=ntg-context@ntg.nl \
    --cc=ursula.hermann@univie.ac.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).