Am 05.06.08, 15:34 +1200 schrieb Guy K. Kloss:
> On Thu, 05 Jun 2008 3:11:12 pm 小草 wrote:
> > If i want to call some of the functions, i have to rewrite them in VC MFC
> > functions, ig, replace "sprintf" with "AfxMessageBox" or something, so as
> > to use them in my MFC programmes. I wonder if anyone else encounters the
> > same problem?

> As for your problem: You should be just able to use LCMS in your environment 
> to code against its API and use it. It shouldn't handle any output, 
> dialogues, messages, etc. for you, that's YOUR task.
> 
> However, on the subject of error handling I have to complain a bit, too. 
> Setting an error handler is nice, but that's not really possible within some 
> applications. An exception with proper exception handling would be preferable 
> for that reason. But that note is besides the track of your request ...

The lcms(.h) error handler is:
typedef int (* cmsErrorHandlerFunction)(int ErrorCode, const char 
*ErrorText);

LCMSAPI void LCMSEXPORT cmsSetErrorHandler(cmsErrorHandlerFunction Fn);

Cant you raise the exception simply in the cmsErrorHandlerFunction 
provided by you, by checking ErrorCode and reacting on LCMS_ERRC_ABORTED?

kind regards
Kai-Uwe Behrmann
-- 
developing for colour management 
www.behrmann.name + www.oyranos.org
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
Lcms-user mailing list
Lcms-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lcms-user

Reply via email to