comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Is there a way to keep axis text from scaling?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Is there a way to keep axis text from scaling? [message #17541] Fri, 29 October 1999 00:00 Go to next message
Karri Kaksonen is currently offline  Karri Kaksonen
Messages: 27
Registered: October 1999
Junior Member
I wrote some object graphics axes and found out that I
cannot change the data range without scaling the font at
the same time.

The solution to kill the axis and re-create them is not
very pretty. Does somebody have a better solution?

--
Regards,

Karri Kaksonen
Re: Is there a way to keep axis text from scaling? [message #17623 is a reply to message #17541] Sun, 31 October 1999 00:00 Go to previous message
Karri Kaksonen is currently offline  Karri Kaksonen
Messages: 27
Registered: October 1999
Junior Member
Mark Hadfield wrote:
>> axistext->setproperty, font=self.complexPlotFont, $
>> Recompute_Dimensions=2
>
> This works for the axis title but not for the tick text, i.e. the following
>
> oaxis->GetProperty, TICKTEXT=ticktext
> ticktext->SetProperty, RECOMPUTE_DIMENSIONS=2

I had no Title's in my axis. This keyword worked on the
ticktexts. (IDL 5.2.1 Intel Windows machine)

--
Karri
Re: Is there a way to keep axis text from scaling? [message #17626 is a reply to message #17541] Sun, 31 October 1999 00:00 Go to previous message
Mark Hadfield is currently offline  Mark Hadfield
Messages: 783
Registered: May 1995
Senior Member
David Fanning <davidf@dfanning.com> wrote in message
news:MPG.12837f0ab595ea55989925@news.frii.com...
> Karri Kaksonen (karri.kaksonen@picker.fi) writes:
>
>> I wrote some object graphics axes and found out that I
>> cannot change the data range without scaling the font at
>> the same time.
>>
>> The solution to kill the axis and re-create them is not
>> very pretty. Does somebody have a better solution?
>
> ...
>
> What we want to do here is recompute the text scaling
> when we change the axis range that the text object
> is attached to. We can control when the scaling occurs
> by setting the RECOMPUTE_DIMENSIONS property of the
> text object. In this case, you would like to *always*
> recompute the text dimensions, so I would set this
> property at the same time you assign the font object
> to the text object in the INIT method of your object:
>
> axistext->setproperty, font=self.complexPlotFont, $
> Recompute_Dimensions=2

This works for the axis title but not for the tick text, i.e. the following

oaxis->GetProperty, TICKTEXT=ticktext
ticktext->SetProperty, RECOMPUTE_DIMENSIONS=2

has no effect. An extra keyword to IDLgrAxis::Init, allowing this behaviour
to be overridden, would be nice.

(My news server refused to post this message because there is more included
text than new. So here's some more new text:
ABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCD EFGHABCDEFGHABCD
EFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGH ABCDEFGHABCDEFGH
ABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCD EFGHABCDEFGHABCD
EFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGH ABCDEFGHABCDEFGH
ABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCD EFGHABCDEFGHABCD
EFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGH ABCDEFGHABCDEFGH
ABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGHABCD EFGHABCDEFGHABCD
EFGHABCDEFGHABCDEFGHABCDEFGHABCDEFGH

---
Mark Hadfield
m.hadfield@niwa.cri.nz http://katipo.niwa.cri.nz/~hadfield/
National Institute for Water and Atmospheric Research
PO Box 14-901, Wellington, New Zealand
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Does the hide-keyword work?
Next Topic: point_lun is slow

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 11:42:17 PDT 2025

Total time taken to generate the page: 0.00509 seconds