Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Unable to load graphics library [Cairo is required]
Unable to load graphics library [Cairo is required] [message #464388] Tue, 22 November 2005 16:44 Go to next message
Tas Frangoullides is currently offline Tas FrangoullidesFriend
Messages: 195
Registered: July 2009
Senior Member
I am using Eclipse 3.1.1 on Suse Linux 10 which appears
to have Cairo 1.0.0-7.2 installed. When trying some example
from the GMF project I get the following error. Seems like
and SWT related problem but I have no idea where to start
investigating. Any help would be appreciated.

Thanks,

Tas.


org.eclipse.swt.SWTException: Unable to load graphics library [Cairo is required] (java.lang.NoClassDefFoundError)
at org.eclipse.swt.SWT.error(SWT.java:2942)
at org.eclipse.swt.graphics.Device.checkCairo(Device.java:154)
at org.eclipse.swt.graphics.GC.initCairo(GC.java:2268)
at org.eclipse.swt.graphics.GC.setAntialias(GC.java:2475)
at org.eclipse.draw2d.SWTGraphics.reconcileHints(SWTGraphics.ja va:795)
at org.eclipse.draw2d.SWTGraphics.checkGC(SWTGraphics.java:282)
at org.eclipse.draw2d.SWTGraphics.checkFill(SWTGraphics.java:26 8)
at org.eclipse.draw2d.SWTGraphics.fillOval(SWTGraphics.java:518 )
at org.eclipse.draw2d.Graphics.fillOval(Graphics.java:428)
at org.eclipse.gmf.runtime.draw2d.ui.internal.graphics.ScaledGr aphics.fillOval(ScaledGraphics.java:325)
at org.eclipse.draw2d.Graphics.fillOval(Graphics.java:428)
at org.eclipse.gmf.runtime.diagram.ui.geoshapes.internal.draw2d .figures.GeoShapeEllipseFigure.paintFigure(GeoShapeEllipseFi gure.java:48)
at org.eclipse.draw2d.Figure.paint(Figure.java:1053)
at org.eclipse.draw2d.Figure.paintChildren(Figure.java:1091)
at org.eclipse.draw2d.Figure.paintClientArea(Figure.java:1123)
at org.eclipse.draw2d.Figure.paint(Figure.java:1055)
at org.eclipse.draw2d.Figure.paintChildren(Figure.java:1091)
at org.eclipse.draw2d.Figure.paintClientArea(Figure.java:1123)
at org.eclipse.draw2d.Figure.paint(Figure.java:1055)
at org.eclipse.draw2d.Figure.paintChildren(Figure.java:1091)
at org.eclipse.draw2d.Figure.paintClientArea(Figure.java:1123)
at org.eclipse.draw2d.Figure.paint(Figure.java:1055)
at org.eclipse.draw2d.Figure.paintChildren(Figure.java:1091)
at org.eclipse.draw2d.Figure.paintClientArea(Figure.java:1123)
at org.eclipse.draw2d.ScalableFreeformLayeredPane.paintClientAr ea(ScalableFreeformLayeredPane.java:61)
at org.eclipse.gmf.runtime.draw2d.ui.internal.graphics.Scalable FreeformLayeredPane.paintClientArea(ScalableFreeformLayeredP ane.java:73)
at org.eclipse.draw2d.Figure.paint(Figure.java:1055)
at org.eclipse.draw2d.Figure.paintChildren(Figure.java:1091)
at org.eclipse.draw2d.Figure.paintClientArea(Figure.java:1123)
at org.eclipse.draw2d.Figure.paint(Figure.java:1055)
at org.eclipse.draw2d.Figure.paintChildren(Figure.java:1091)
at org.eclipse.draw2d.Figure.paintClientArea(Figure.java:1118)
at org.eclipse.draw2d.Viewport.paintClientArea(Viewport.java:15 6)
at org.eclipse.draw2d.Figure.paint(Figure.java:1055)
at org.eclipse.draw2d.Figure.paintChildren(Figure.java:1091)
at org.eclipse.draw2d.Figure.paintClientArea(Figure.java:1123)
at org.eclipse.draw2d.Figure.paint(Figure.java:1055)
at org.eclipse.draw2d.DeferredUpdateManager.repairDamage(Deferr edUpdateManager.java:225)
at org.eclipse.draw2d.DeferredUpdateManager.performUpdate(Defer redUpdateManager.java:145)
at org.eclipse.draw2d.DeferredUpdateManager$UpdateRequest.run(D eferredUpdateManager.java:40)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:3 5)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchr onizer.java:123)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.jav a:2844)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2575)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:809 )
at org.eclipse.jface.window.Window.open(Window.java:787)
at org.eclipse.jface.dialogs.MessageDialog.openError(MessageDia log.java:319)
at org.eclipse.jface.util.SafeRunnable.handleException(SafeRunn able.java:59)
at org.eclipse.core.internal.runtime.InternalPlatform.handleExc eption(InternalPlatform.java:715)
at org.eclipse.core.internal.runtime.InternalPlatform.run(Inter nalPlatform.java:1046)
at org.eclipse.core.runtime.Platform.run(Platform.java:783)
at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:44)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:14 8)
at org.eclipse.jface.viewers.StructuredViewer.fireOpen(Structur edViewer.java:739)
at org.eclipse.jface.viewers.StructuredViewer.handleOpen(Struct uredViewer.java:968)
at org.eclipse.jface.viewers.StructuredViewer$6.handleOpen(Stru cturedViewer.java:1067)
at org.eclipse.jface.util.OpenStrategy.fireOpenEvent(OpenStrate gy.java:243)
at org.eclipse.jface.util.OpenStrategy.access$2(OpenStrategy.ja va:238)
at org.eclipse.jface.util.OpenStrategy$1.handleEvent(OpenStrate gy.java:277)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :66)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1021)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:2867)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2572)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:1699)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1663)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:367)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:143)
at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplicatio n.java:103)
at org.eclipse.core.internal.runtime.PlatformActivator$1.run(Pl atformActivator.java:226)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:376)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:163)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.eclipse.core.launcher.Main.invokeFramework(Main.java:334 )
at org.eclipse.core.launcher.Main.basicRun(Main.java:278)
at org.eclipse.core.launcher.Main.run(Main.java:973)
at org.eclipse.core.launcher.Main.main(Main.java:948)
Caused by: java.lang.NoClassDefFoundError
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:141)
at org.eclipse.swt.graphics.Device.checkCairo(Device.java:152)
.... 77 more
Re: Unable to load graphics library [Cairo is required] [message #464394 is a reply to message #464388] Tue, 22 November 2005 18:39 Go to previous messageGo to next message
Billy Biggs is currently offline Billy BiggsFriend
Messages: 94
Registered: July 2009
Member
Tas Frangoullides wrote:
> I am using Eclipse 3.1.1 on Suse Linux 10 which appears
> to have Cairo 1.0.0-7.2 installed. When trying some example
> from the GMF project I get the following error. Seems like
> and SWT related problem but I have no idea where to start
> investigating. Any help would be appreciated.

> org.eclipse.swt.SWTException: Unable to load graphics library [Cairo is required] (java.lang.NoClassDefFoundError)

The advanced graphics support in SWT 3.1 requires cairo 0.4,
as cairo 1.0 was not yet out. Sorry for the confusing error
message. The fix is to update to a 3.2 development release
which works with cairo 1.0.

-Billy
Re: Unable to load graphics library [Cairo is required] [message #464424 is a reply to message #464394] Wed, 23 November 2005 13:15 Go to previous message
Tas Frangoullides is currently offline Tas FrangoullidesFriend
Messages: 195
Registered: July 2009
Senior Member
Thanks for the help. I've got it all working under 3.2 now. No need to
apologise for the error message, it was good enough.

Tas.

Billy Biggs wrote:

> Tas Frangoullides wrote:
>> I am using Eclipse 3.1.1 on Suse Linux 10 which appears
>> to have Cairo 1.0.0-7.2 installed. When trying some example
>> from the GMF project I get the following error. Seems like
>> and SWT related problem but I have no idea where to start
>> investigating. Any help would be appreciated.
>
>> org.eclipse.swt.SWTException: Unable to load graphics library [Cairo is
>> required] (java.lang.NoClassDefFoundError)
>
> The advanced graphics support in SWT 3.1 requires cairo 0.4,
> as cairo 1.0 was not yet out. Sorry for the confusing error
> message. The fix is to update to a 3.2 development release
> which works with cairo 1.0.
>
> -Billy
Previous Topic:Problem during exploration of tree sub-items
Next Topic:Java2D with SWT
Goto Forum:
  


Current Time: Mon Dec 22 05:08:39 GMT 2014

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

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