cariomm exceptions



Hi list,

When I use rel_line_to, or rel_move_to I get an exception that looks
like this:

glibmm-ERROR **:
unhandled exception (type std::exception) in signal handler:
what: <unknown error status>

aborting...
Aborted


My code is pretty huge, I don't have a test case, but it looks something
like this:

  slotConnections_t::const_iterator slotIter, slotEnd;
  slotEnd = slotConnections.end();
  for(slotIter = slotConnections.begin();slotIter!=slotEnd;slotIter++) {

    GraphicalInstancePtr
sourceNode(dynamic_pointer_cast<GraphicalInstance>(slotIter->second.first));
    assert(sourceNode!=NULL);
    Vector2i retPos(sourceNode->getReturnPos()+sourceNode->getPos());
    Vector2i slotPos(getSlotPos(slotIter->first));
    Vector2i delta(retPos-(slotPos+getPos()));

    cr->save();

    cr->rel_move_to(slotPos[0], slotPos[1]);    //crashes only when this
line is in.

    cr->set_source_rgb(1.0, 0, 0);
    cr->arc(0,0,5,0,2*M_PI);
    cr->fill();

    cr->line_to(retPos[0], retPos[1]);
    cr->stroke();

    cr->restore();
  }

the app uses cairo very little otherwise.  ldd says I'm linked against
libgtkmm-2.4.so.1 => /usr/lib/libgtkmm-2.4.so.1

I know this question is a bit vague, I just don't have any idea what to
make of it.

Another thing,
when I use move_to, it seems to have no effect at all. translate works
however.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]