On Wed, 2010-11-03 at 14:31 +0100, Jonas Nyström wrote:

> I want to try some basic Cairo programming in java, and downloaded the
> 4.0.17 rc2 packages. 

Cool :)
> 
> Where can I find these constant files? 

So I just whacked your code snippet into a class and got the following
imports:

import org.freedesktop.cairo.Context;
import org.freedesktop.cairo.Format;
import org.freedesktop.cairo.ImageSurface;

public class Example
{
    public static void main(String[] args) {
        final ImageSurface surface;
        final Context cr;

        surface = new ImageSurface(Format.ARGB32, 200, 200);

        cr = new Context(surface);
        cr.setSource(0.0, 0.0, 0.0);
        cr.moveTo(25.0, 25.0);
        cr.lineTo(50.0, 100.0);
        cr.stroke();
    }
}


Is that what you needed to know?
> 
> i get errors because CairoAntialias, CairoContent etc where constants
> are defined can't be found.
> 
Oh. Wait. Hm.

Did you run

$ make

If working against the library as built you want the tmp/gtk-4.0.jar
that results from that.

Sounds like you loaded up the classes under src/bindings/ but haven't
built the library, because you're missing the sources under
generated/bindings/. You still must run the build. though.

If working against the java-gnome sources directly you need... well, if
you just use the Eclipse Project that comes in the sources it'll Just
Work™. If you're not using Eclispe, then reply and I'll walk you through
the source folders. You still must run the build, though.

AfC
Granada

Attachment: signature.asc
Description: This is a digitally signed message part

------------------------------------------------------------------------------
Achieve Improved Network Security with IP and DNS Reputation.
Defend against bad network traffic, including botnets, malware, 
phishing sites, and compromised hosts - saving your company time, 
money, and embarrassment.   Learn More! 
http://p.sf.net/sfu/hpdev2dev-nov
_______________________________________________
java-gnome-developer mailing list
java-gnome-developer@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/java-gnome-developer

Reply via email to