On Sat, Nov 29, 2014 at 11:03 AM, Hans Hagen <pragma@wxs.nl> wrote:
> On 11/29/2014 10:49 AM, Mark Szepieniec wrote:
>
>> I'm trying to set a default width for figures with \setupfloat. However,
>> the command doesn't seem to be picking up the width specification, even
>> though the manual indicates it accepts a width= argument:
>>
>> \setupfloat[figure][width=2cm]
>>
>> \starttext
>>
>> \placefigure{}{\externalfigure[picture.png]}
>>
>>
>> \stoptext
>>
>
> just
>
> \placefigure{}{\externalfigure[picture.png][width=2cm]}
>
>
>
>> picture.png just gets inserted at its native size, rather than scaled to
>> have the specified width. What am I doing wrong? (setting minwidth
>> and/or maxwidth doesn't seem to work either)
>>
>> Thanks in advance for any assistance.
>>
>> Mark
Sorry, I should have mentioned I was able to work around it by doing
exactly that, but I'd rather not have to edit all the \placefigure
instances if I decide to change the width.
Also I'd like to use a different default width for graphics, so
\setupexternalfigures[width=XXXcm] wouldn't work well either.
I realize I could define my own macros or something to solve this, but I'm
just puzzled that setting width in \setupfloat[figure] doesn't work. Am I
reading the manual wrong, or is is just not implemented yet or something?
(honest question)
Thanks for your response,
MarkHi Mark,You can use \defineexternalfigure as in the following example.\defineexternalfigure[whatever][width=2cm]\starttext\placefigure{}{\externalfigure[picture.png][whatever]}\stoptextChristoph