* \getfiguredimensions again in mkiv
@ 2009-11-09 20:36 Aditya Mahajan
2009-11-19 16:44 ` Aditya Mahajan
0 siblings, 1 reply; 12+ messages in thread
From: Aditya Mahajan @ 2009-11-09 20:36 UTC (permalink / raw)
To: mailing list for ConTeXt users
Hans,
Something is also wrong with getting the width and height of a figure in
mkiv. Minimal example:
\starttext
\getfiguredimensions[filename]
\figurewidth
\figureheight
\stoptext
Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2009-11-09 20:36 \getfiguredimensions again in mkiv Aditya Mahajan
@ 2009-11-19 16:44 ` Aditya Mahajan
2009-11-19 21:41 ` Hans Hagen
0 siblings, 1 reply; 12+ messages in thread
From: Aditya Mahajan @ 2009-11-19 16:44 UTC (permalink / raw)
To: mailing list for ConTeXt users
Hi,
This request was lost in traffic.
On Mon, 9 Nov 2009, Aditya Mahajan wrote:
> Hans,
>
> Something is also wrong with getting the width and height of a figure in
> mkiv. Minimal example:
>
> \starttext
> \getfiguredimensions[filename]
> \figurewidth
> \figureheight
> \stoptext
To be precise, I get 0sp 0sp as output, rather than the correct dimensions
of the figure.
Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2009-11-19 16:44 ` Aditya Mahajan
@ 2009-11-19 21:41 ` Hans Hagen
2009-11-19 23:04 ` Aditya Mahajan
2010-01-03 2:30 ` Aditya Mahajan
0 siblings, 2 replies; 12+ messages in thread
From: Hans Hagen @ 2009-11-19 21:41 UTC (permalink / raw)
To: mailing list for ConTeXt users
Aditya Mahajan wrote:
> Hi,
>
> This request was lost in traffic.
>
> On Mon, 9 Nov 2009, Aditya Mahajan wrote:
>
>> Hans,
>>
>> Something is also wrong with getting the width and height of a figure
>> in mkiv. Minimal example:
>>
>> \starttext
>> \getfiguredimensions[filename]
>> \figurewidth
>> \figureheight
>> \stoptext
>
> To be precise, I get 0sp 0sp as output, rather than the correct
> dimensions of the figure.
fixed in next beta
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2009-11-19 21:41 ` Hans Hagen
@ 2009-11-19 23:04 ` Aditya Mahajan
2010-01-03 2:30 ` Aditya Mahajan
1 sibling, 0 replies; 12+ messages in thread
From: Aditya Mahajan @ 2009-11-19 23:04 UTC (permalink / raw)
To: mailing list for ConTeXt users
On Thu, 19 Nov 2009, Hans Hagen wrote:
> Aditya Mahajan wrote:
>> Hi,
>>
>> This request was lost in traffic.
>>
>> On Mon, 9 Nov 2009, Aditya Mahajan wrote:
>>
>>> Hans,
>>>
>>> Something is also wrong with getting the width and height of a figure in
>>> mkiv. Minimal example:
>>>
>>> \starttext
>>> \getfiguredimensions[filename]
>>> \figurewidth
>>> \figureheight
>>> \stoptext
>>
>> To be precise, I get 0sp 0sp as output, rather than the correct dimensions
>> of the figure.
>
> fixed in next beta
Thanks.
Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2009-11-19 21:41 ` Hans Hagen
2009-11-19 23:04 ` Aditya Mahajan
@ 2010-01-03 2:30 ` Aditya Mahajan
2010-01-03 11:24 ` Hans Hagen
2010-02-23 18:17 ` Aditya Mahajan
1 sibling, 2 replies; 12+ messages in thread
From: Aditya Mahajan @ 2010-01-03 2:30 UTC (permalink / raw)
To: mailing list for ConTeXt users
On Thu, 19 Nov 2009, Hans Hagen wrote:
> Aditya Mahajan wrote:
>> Hi,
>>
>> This request was lost in traffic.
>>
>> On Mon, 9 Nov 2009, Aditya Mahajan wrote:
>>
>>> Hans,
>>>
>>> Something is also wrong with getting the width and height of a figure in
>>> mkiv. Minimal example:
>>>
>>> \starttext
>>> \getfiguredimensions[filename]
>>> \figurewidth
>>> \figureheight
>>> \stoptext
>>
>> To be precise, I get 0sp 0sp as output, rather than the correct dimensions
>> of the figure.
>
> fixed in next beta
The results in MkII and MkIV are inconsistent. Minimal example:
\setupexternalfigures[location={local,default}]
\starttext
\getfiguredimensions[cow]
\startlines
width: \figurewidth
height:\figureheight
\stoplines
\stoptext
In MkII I get,
width: 276.03125pt
height: 200.75pt
In MkIV I get,
width: 7592528sp
height: 5694396sp
which translates to (why doesn't MkIV use pt as units?)
width:115.85pt
height:86.889pt
I don't know if this is a bug in grph-inc.lua or in luatex.
Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2010-01-03 2:30 ` Aditya Mahajan
@ 2010-01-03 11:24 ` Hans Hagen
2010-02-23 18:17 ` Aditya Mahajan
1 sibling, 0 replies; 12+ messages in thread
From: Hans Hagen @ 2010-01-03 11:24 UTC (permalink / raw)
To: mailing list for ConTeXt users
On 3-1-2010 3:30, Aditya Mahajan wrote:
> In MkII I get,
>
> width: 276.03125pt
> height: 200.75pt
>
> In MkIV I get,
>
> width: 7592528sp
> height: 5694396sp
>
> which translates to (why doesn't MkIV use pt as units?)
>
> width:115.85pt
> height:86.889pt
> I don't know if this is a bug in grph-inc.lua or in luatex.
i'll look into it
concerning pt ... tex internally uses sp so this is what mkiv uses
in tex-lua communications
you can use:
\startlines
width: \the\dimexpr\figurewidth\relax
height: \the\dimexpr\figureheight\relax
\stoplines
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2010-01-03 2:30 ` Aditya Mahajan
2010-01-03 11:24 ` Hans Hagen
@ 2010-02-23 18:17 ` Aditya Mahajan
2010-02-23 18:21 ` Aditya Mahajan
` (2 more replies)
1 sibling, 3 replies; 12+ messages in thread
From: Aditya Mahajan @ 2010-02-23 18:17 UTC (permalink / raw)
To: mailing list for ConTeXt users
Hi Hans,
On Sat, 2 Jan 2010, Aditya Mahajan wrote:
> On Thu, 19 Nov 2009, Hans Hagen wrote:
>
>> Aditya Mahajan wrote:
>>> Hi,
>>>
>>> This request was lost in traffic.
>>>
>>> On Mon, 9 Nov 2009, Aditya Mahajan wrote:
>>>
>>>> Hans,
>>>>
>>>> Something is also wrong with getting the width and height of a figure in
>>>> mkiv. Minimal example:
>>>>
>>>> \starttext
>>>> \getfiguredimensions[filename]
>>>> \figurewidth
>>>> \figureheight
>>>> \stoptext
>>>
>>> To be precise, I get 0sp 0sp as output, rather than the correct dimensions
>>> of the figure.
>>
>> fixed in next beta
>
> The results in MkII and MkIV are inconsistent. Minimal example:
This is still wrong. Using the following example,
> \setupexternalfigures[location={local,default}]
> \starttext
> \getfiguredimensions[cow]
>
> \startlines
> width: \the\dimexpr\figurewidth\relax
> height: \the\dimexpr\figureheight\relax
> \stoplines
> \stoptext
>
> In MkII I get,
>
> width: 276.03125pt
> height: 200.75pt
>
> In MkIV I get,
>
> width: 200.75pt
> height: 200.75pt
It appears that the dimension for width is being used for height. I could
not find an obvious mistake in grph-inc.
Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2010-02-23 18:17 ` Aditya Mahajan
@ 2010-02-23 18:21 ` Aditya Mahajan
2010-02-23 19:38 ` Wolfgang Schuster
2010-02-23 22:36 ` Hans Hagen
2 siblings, 0 replies; 12+ messages in thread
From: Aditya Mahajan @ 2010-02-23 18:21 UTC (permalink / raw)
To: mailing list for ConTeXt users
On Tue, 23 Feb 2010, Aditya Mahajan wrote:
>> In MkII I get,
>>
>> width: 276.03125pt
>> height: 200.75pt
>>
>> In MkIV I get,
>>
>> width: 200.75pt
>> height: 200.75pt
>
> It appears that the dimension for width is being used for height.
I mean that the dimension for height is being used for width.
Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2010-02-23 18:17 ` Aditya Mahajan
2010-02-23 18:21 ` Aditya Mahajan
@ 2010-02-23 19:38 ` Wolfgang Schuster
2010-02-23 19:43 ` Aditya Mahajan
2010-02-23 22:36 ` Hans Hagen
2 siblings, 1 reply; 12+ messages in thread
From: Wolfgang Schuster @ 2010-02-23 19:38 UTC (permalink / raw)
To: mailing list for ConTeXt users
Am 23.02.10 19:17, schrieb Aditya Mahajan:
> It appears that the dimension for width is being used for height. I
> could not find an obvious mistake in grph-inc.
For unscaled images you can use \figurenaturalwidth and
\figurenaturalheight.
Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2010-02-23 19:38 ` Wolfgang Schuster
@ 2010-02-23 19:43 ` Aditya Mahajan
0 siblings, 0 replies; 12+ messages in thread
From: Aditya Mahajan @ 2010-02-23 19:43 UTC (permalink / raw)
To: mailing list for ConTeXt users
On Tue, 23 Feb 2010, Wolfgang Schuster wrote:
> Am 23.02.10 19:17, schrieb Aditya Mahajan:
>> It appears that the dimension for width is being used for height. I could
>> not find an obvious mistake in grph-inc.
> For unscaled images you can use \figurenaturalwidth and \figurenaturalheight.
Ah, thanks.
Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2010-02-23 18:17 ` Aditya Mahajan
2010-02-23 18:21 ` Aditya Mahajan
2010-02-23 19:38 ` Wolfgang Schuster
@ 2010-02-23 22:36 ` Hans Hagen
2010-02-23 23:00 ` Aditya Mahajan
2 siblings, 1 reply; 12+ messages in thread
From: Hans Hagen @ 2010-02-23 22:36 UTC (permalink / raw)
To: mailing list for ConTeXt users
On 23-2-2010 19:17, Aditya Mahajan wrote:
> \setupexternalfigures[location={local,default}]
> \starttext
> \getfiguredimensions[cow]
>
> \startlines
> width: \the\dimexpr\figurewidth\relax
> height: \the\dimexpr\figureheight\relax
> \stoplines
> \stoptext
hm, i get
width: 276.03125pt
height: 200.75pt
in mkiv
--
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \getfiguredimensions again in mkiv
2010-02-23 22:36 ` Hans Hagen
@ 2010-02-23 23:00 ` Aditya Mahajan
0 siblings, 0 replies; 12+ messages in thread
From: Aditya Mahajan @ 2010-02-23 23:00 UTC (permalink / raw)
To: Hans Hagen; +Cc: mailing list for ConTeXt users
On Tue, 23 Feb 2010, Hans Hagen wrote:
> On 23-2-2010 19:17, Aditya Mahajan wrote:
>> \setupexternalfigures[location={local,default}]
>> \starttext
>> \getfiguredimensions[cow]
>>
>> \startlines
>> width: \the\dimexpr\figurewidth\relax
>> height: \the\dimexpr\figureheight\relax
>> \stoplines
>> \stoptext
>
> hm, i get
>
> width: 276.03125pt
> height: 200.75pt
>
> in mkiv
I was using 2010.02.09. The current version, 2010.02.23 works fine. Sorry
about the noise.
Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2010-02-23 23:00 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-11-09 20:36 \getfiguredimensions again in mkiv Aditya Mahajan
2009-11-19 16:44 ` Aditya Mahajan
2009-11-19 21:41 ` Hans Hagen
2009-11-19 23:04 ` Aditya Mahajan
2010-01-03 2:30 ` Aditya Mahajan
2010-01-03 11:24 ` Hans Hagen
2010-02-23 18:17 ` Aditya Mahajan
2010-02-23 18:21 ` Aditya Mahajan
2010-02-23 19:38 ` Wolfgang Schuster
2010-02-23 19:43 ` Aditya Mahajan
2010-02-23 22:36 ` Hans Hagen
2010-02-23 23:00 ` Aditya Mahajan
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).