Loading...
Logo
Processing Forum
I found a strange behaviour of Processing 1.2.1:
Copy code
  1. import processing.pdf.*;

  2. size(600,400);
  3. beginRecord(PDF, "test.pdf"); 

  4. PFont font = createFont("Arial", 10);
  5. textMode(SHAPE);      // <--------  comment this!
  6. textFont(font);

  7. endRecord();

Commenting textMode(SHAPE) the program stops with error "The font Arial cannot be used with PDF Export". PGraphicsPDF.listFonts() returns 0 fonts... 
If textFont is before textMode I get the same error.

The program works correctly when I leave textMode(SHAPE), even if I get a warning "textMode(SHAPE) is not supported by this renderer".

Something I forgot along the way or is it a know behaviour?
Alessandro

Replies(2)

I can't reproduce this error, tried on two computers and it works for me.

That's strange:
2 PCs, same Processing Version 1.2.1.
In one PC the problem is present, the other works flawlessly.  

I now assume this has to do with Java: the one NOT working is build 1.6.0_22-b04.
I don't have now the other version available but I will update soon.

Alessandro