Skip to content

NullPointerException using EPS command in PDF output file #21

Description

@simoc

I ran the following Mapyrus commands:

newpage "pdf", "test3.pdf", 210, 297
move 50, 50
eps "test3.eps", 20

Mapyrus stopped with a Java exception:

Cannot invoke "java.awt.Graphics2D.getColor()" because "this.m_graphics2D" is null
java.lang.NullPointerException: Cannot invoke "java.awt.Graphics2D.getColor()" because "this.m_graphics2D" is null
	at org.mapyrus.OutputFormat.drawBoundingBoxes(OutputFormat.java:3926)
	at org.mapyrus.OutputFormat.drawEPS(OutputFormat.java:4053)
	at org.mapyrus.Context.drawEPS(Context.java:2142)
	at org.mapyrus.ContextStack.drawEPS(ContextStack.java:687)
	at org.mapyrus.Interpreter.execute(Interpreter.java:1936)
	at org.mapyrus.Interpreter.executeStatement(Interpreter.java:3552)
	at org.mapyrus.Interpreter.interpret(Interpreter.java:3185)
	at org.mapyrus.Mapyrus.processFile(Mapyrus.java:215)
	at org.mapyrus.Mapyrus.main(Mapyrus.java:719)

The documentation for the EPS command states that a grey box should be drawn on the page.

I am using the git master branch.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions