Hi Soren,
I encounter a problem of multithread-safe for D-Bus implementation. Did you encounter this problem before, too? Would you like to share me some hint about this problem?
sincerely, Mat.
Krzysztof Kosiński 提到:
Mat-48 wrote:
But when I call these funtions in another thread, it crash inkscape. Is there any required initialization before I call these this function?
Inkscape is not multithread-safe. You cannot call arbitrary functions from different threads.
To open a file by its path, you need to use sp_file_open. However, the argument must be UTF-8 encoded, so you need to use Glib::ustring instead of std::string, and call it like this: sp_file_open(path.data(), NULL);
If you're trying to do something related to D-Bus, consult it with Soren (aka "Glimmer Labs").
Regards, Krzysztof