Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BIRT » Rotated axis labels in Windows(Axis labels just showing garbage when rotated)
Rotated axis labels in Windows [message #855041] Tue, 24 April 2012 13:28 Go to next message
Jens  Köcke is currently offline Jens KöckeFriend
Messages: 5
Registered: September 2011
Junior Member
Hi there,

I came accross a strange problem. I'm developing an RCP application, which draws a bar chart using the BIRT chartengine. But when I try to rotate the xAxis Labels by 45 degree it displays just garbage under Windows. I've attached two screenshots. Both screenshot use the same data and same birt version.
I just added
xAxis.getLabel().getCaption().getFont().setRotation(45);

to rotate the label.

The same code works fine under linux and macosx. Anyone got any suggestions what I'm doing wrong?

Regards
Jens

index.php/fa/8063/0/
index.php/fa/8064/0/
Re: Rotated axis labels in Windows [message #855187 is a reply to message #855041] Tue, 24 April 2012 15:37 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Is this the same issue?
https://bugs.eclipse.org/bugs/show_bug.cgi?id=273975

BTW what output format are you using for the chart?

Jason

On 4/24/2012 9:28 AM, Jens öcke wrote:
> Hi there,
>
> I came accross a strange problem. I'm developing an RCP application, which draws a bar chart using the BIRT chartengine. But when I try to rotate the xAxis Labels by 45 degree it displays just garbage under Windows. I've attached two screenshots. Both screenshot use the same data and same birt version.
> I just added
> xAxis.getLabel().getCaption().getFont().setRotation(45);
> to rotate the label.
>
> The same code works fine under linux and macosx. Anyone got any suggestions what I'm doing wrong?
>
> Regards
> Jens
>
>
>
Re: Rotated axis labels in Windows [message #855970 is a reply to message #855187] Wed, 25 April 2012 08:49 Go to previous messageGo to next message
Jens  Köcke is currently offline Jens KöckeFriend
Messages: 5
Registered: September 2011
Junior Member
I don't think it is the same issue.

I'm rendering direkt to a swt canvas.

Jens
Re: Rotated axis labels in Windows [message #856392 is a reply to message #855970] Wed, 25 April 2012 16:09 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Do you have a sample app that I could run that shows the issue?

Jason

On 4/25/2012 4:49 AM, Jens öcke wrote:
> I don't think it is the same issue.
>
> I'm rendering direkt to a swt canvas.
>
> Jens
Re: Rotated axis labels in Windows [message #856607 is a reply to message #856392] Wed, 25 April 2012 20:42 Go to previous messageGo to next message
Jens  Köcke is currently offline Jens KöckeFriend
Messages: 5
Registered: September 2011
Junior Member
Hi,

I've attached a simple App. It opens a simple Shell and displays a chart. Running on MacOS the bottom Labels are shown. Running on Windows (tested as standalone app, not run from inside eclipse) the bottom labels are just garbage.

Jens

Jason Weathersby wrote on Wed, 25 April 2012 12:09
Do you have a sample app that I could run that shows the issue?

Jason

On 4/25/2012 4:49 AM, Jens öcke wrote:
> I don't think it is the same issue.
>
> I'm rendering direkt to a swt canvas.
>
> Jens

  • Attachment: TestSrc.zip
    (Size: 61.97KB, Downloaded 240 times)
Re: Rotated axis labels in Windows [message #857637 is a reply to message #856607] Thu, 26 April 2012 18:27 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Can you try adding the font name like:
xAxis.getLabel().getCaption().getFont().setName("Arial");

Jason

On 4/25/2012 4:43 PM, Jens Köcke wrote:
> Hi,
>
> I've attached a simple App. It opens a simple Shell and displays a chart. Running on MacOS the bottom Labels are shown. Running on Windows (tested as standalone app, not run from inside eclipse) the bottom labels are just garbage.
>
> Jens
>
> Jason Weathersby wrote on Wed, 25 April 2012 12:09
>> Do you have a sample app that I could run that shows the issue?
>>
>> Jason
>>
>> On 4/25/2012 4:49 AM, Jens öcke wrote:
>>> I don't think it is the same issue.
>>>
>>> I'm rendering direkt to a swt canvas.
>>>
>>> Jens
>
>
Re: Rotated axis labels in Windows [message #857688 is a reply to message #857637] Thu, 26 April 2012 19:24 Go to previous messageGo to next message
Jens  Köcke is currently offline Jens KöckeFriend
Messages: 5
Registered: September 2011
Junior Member
Hi,

Jason Weathersby wrote on Thu, 26 April 2012 14:27
Can you try adding the font name like:
xAxis.getLabel().getCaption().getFont().setName("Arial");


Thanks! It worked. Is it expected behavior? Did I miss something in the docs?

Regards,
Jens

Re: Rotated axis labels in Windows [message #857692 is a reply to message #857688] Thu, 26 April 2012 19:29 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

No I think this may be a bug with fonts. It would be good if you could
put a bugzilla entry in and put the resolution as well.

Jason

On 4/26/2012 3:24 PM, Jens Köcke wrote:
> Hi,
>
> Jason Weathersby wrote on Thu, 26 April 2012 14:27
>> Can you try adding the font name like:
>> xAxis.getLabel().getCaption().getFont().setName("Arial");
>
>
> Thanks! It worked. Is it expected behavior? Did I miss something in the
> docs?
>
> Regards,
> Jens
>
>
Re: Rotated axis labels in Windows [message #857710 is a reply to message #857692] Thu, 26 April 2012 19:50 Go to previous message
Jens  Köcke is currently offline Jens KöckeFriend
Messages: 5
Registered: September 2011
Junior Member
Hi Jason,

Jason Weathersby wrote on Thu, 26 April 2012 15:29
No I think this may be a bug with fonts. It would be good if you could
put a bugzilla entry in and put the resolution as well.


I filed the Bug 377825 - Rotated Axis labels get garbled on windows.

Unfortunately I can't post a link. Wink

Jens
Previous Topic:"cant re-generate content for MultiLineItem" exception with Dynamic Text elements
Next Topic:Birt and long integer types in my Data Set
Goto Forum:
  


Current Time: Thu Apr 18 05:43:04 GMT 2024

Powered by FUDForum. Page generated in 0.03998 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top