I'm writing an article for a magazine. I'm trying to insert a (floating) 2-column box at the upper right corner of a 3-column document, with the text wrapping around it nicely andn the columns being aligned. I'm making the box using the tikz package so I can have a box with rounded edges and a background color. I was trying to do the wrapping using wrapfig (and I've tried some minipage stuff as well), but I can't get it to work.
This is some code that explains what I'm trying to do, and how I've been trying to do it:
\documentclass{article}
\usepackage{wrapfig}
\usepackage{tikz}
\usepackage{multicol}
\definecolor{col}{rgb}{0.6,0.6,0.9}
\setlength{\columnsep}{0.5cm}
\newcommand{\floatingBox}[3]
{
\noindent
\begin{wrapfigure}{#1}{#2}
\begin{tikzpicture}
\node[rounded corners=5pt, fill=col, text width=\linewidth]{#3};
\end{tikzpicture}
\end{wrapfigure}
}
\begin{document}
\begin{multicols}{3}
\large
Some random rambling to fill a page.
Aardvark AB aback abacus abaft abalone abandon abandoned abandonment abase
abasement abash abashed abate abatement abattoir abbess abbey abbot
abbreviate abbreviation ABC abdicate abdication abdomen abdominal abduct
abduction abeam abed aberrant aberration abet abeyance abhor abhorrence
abhorrent abide abiding ability abject abjure ablaze able able-bodied ABM
abnegation abnormal abnormality aboard abode abolish abolition abolitionist
A-bomb abominable abominate abomination aboriginal aborigine abort abortion
abortionist abortive abound about about-face above aboveboard abracadabra
abrade Abraham abrasion abrasive abreast abridge abridgment abroad abrogate
abrogation abrupt abscess abscond absence absent absentee absenteeism
absent-minded absinthe absolute absolute zero absolution absolutism absolve
absorb absorbency absorbent absorbing absorption abstain abstemious
abstention abstinence abstinent abstract abstracted abstraction abstruse
absurd absurdity abundance abundant abuse abusive abut abutment abysmal
abyss AC acacia academia academic academician academy a cappella accede
accelerate acceleration accelerator accent accentuate accentuation accept
acceptability acceptable acceptance access accessibility accessible
accession.
\floatingBox{tr}{2\columnwidth + 1\columnsep}{
\begin{multicols}{2}
A box that spans 2 columns and should be floating on top of the page with
the text wrapping around it. It's aligned to the right, so it would be
exactly above 2 entire columns, with one column to its left.
\end{multicols}
}
Accessory accident accidental accident-prone acclaim acclamation acclimate
acclimation acclimatization acclimatize accolade accommodate accommodating
accommodation accompaniment accompanist accompany accomplice accomplish
accomplished accomplishment accord accordance accordingly according to
accordion accost account accountability accountable accountant accounting
accouterments accredit accreditation accrue accumulate accumulation
accumulative accuracy accurate accursed accusation accusative accusatory
accuse accused accusingly accustom accustomed ace acerbic acerbity
acetaminophen acetate acetic acid acetone acetylene ache achievable achieve
achievement.
\end{multicols}
\end{document}