[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Newsgroup Home]
|
[news.eclipse.platform.swt] Re: Bad font rendering on text of toolitem if displayed with an image
|
We don't draw the gray text, Windows does. The image looks all right. What
theme are you using?
"Vadalus" <vadalus@xxxxxxxxx> wrote in message
news:ben41c$fqp$3@xxxxxxxxxxxxxx
> yep, sure. I suppose it could be a graphics card issue but I see it on a
> number of computers....
>
> I have attached a small image of what I see on the screen.
>
> If if makes any difference I am using 32 bit color.
>
> Thanks
>
>
> Steve Northover wrote:
> > I ran the code and it looks fine to me. Can you post a screen shot
where
> > Eclipse looks bad and another XP app looks good.
> >
> > "Vadalus" <vadalus@xxxxxxxxx> wrote in message
> > news:beekdm$3ui$1@xxxxxxxxxxxxxx
> >
> >>Hi Steve,
> >>
> >>I only see this on eclispe apps, not regular native XP apps.
> >>
> >>Here is a code snippet, for me the disabled toolitem is rendered badly
in
> >>this example.
> >>
> >>public static void main(String[] args)
> >>{
> >>Display display = new Display();
> >>Image image = new Image(display, 16, 16);
> >>Color color = display.getSystemColor(SWT.COLOR_RED);
> >>GC gc = new GC(image);
> >>gc.setBackground(color);
> >>gc.fillRectangle(image.getBounds());
> >>gc.dispose();
> >>
> >>Shell shell = new Shell(display);
> >>ToolBar toolBar = new ToolBar(shell, SWT.FLAT | SWT.BORDER);
> >>
> >>ToolItem item = new ToolItem(toolBar, SWT.PUSH);
> >>item.setImage(image);
> >>item.setText("enabled");
> >>item.setEnabled(true);
> >>
> >>ToolItem item2 = new ToolItem(toolBar, SWT.PUSH);
> >>item2.setImage(image);
> >>item2.setText("disabled");
> >>item2.setEnabled(false);
> >>
> >>toolBar.pack();
> >>shell.open();
> >>
> >>while (!shell.isDisposed())
> >>{
> >>if (!display.readAndDispatch())
> >>{
> >>display.sleep();
> >>}
> >>}
> >>
> >>image.dispose();
> >>display.dispose();
> >>}
> >>
> >>Steve Northover wrote:
> >>
> >>
> >>>Is it bad for other Windows XP apps? How about a snippet?
> >>
> >>>"Vadalus" <vadalus@xxxxxxxxx> wrote in message
> >>>news:be9gpr$p00$1@xxxxxxxxxxxxxx
> >>>
> >>>>Is it a known bug that the font rendering on a disabled ToolItem (when
> >>>>there is also an image on the toolitem) is very bad?
> >>>>
> >>>>I see this with 2.1 under windowsXP.
> >>>>
> >>>>Thanks
> >>>>
> >>
> >>
> >
> >
>
----------------------------------------------------------------------------
----