Adrian Maier wrote:
> Hello,
> 
> I am trying to run a python program from a Lazarus application. Executing
> it with TProcess is working fine,  but it is slow from the user's
> perspective : it takes a few seconds until the program shows up.
> 
> In order to speed up the execution i linked the python program in the
> pascal application,  but i am receiving some runtime error when
> executing the python code.
> 
> (process:5430): Pango-CRITICAL **: pango_font_description_set_size:
> assertion `size >= 0' failed
> [FORMS.PP] ExceptionOccurred
>  Sender=EAccessViolation
>  Exception=Access violation
>  Stack trace:
>  $B7EF1807  LAZARUSPACKAGEINTF_finalize,  line 49 of gtkglobals.pp
>  $0806F9FE  TCUSTOMFORM__DODESTROY,  line 646 of ./include/customform.inc
>  $0806E8D8  TCUSTOMFORM__BEFOREDESTRUCTION,  line 98 of
> ./include/customform.in
> c
>  $0806E912  TCUSTOMFORM__DESTROY,  line 112 of ./include/customform.inc
>  $080711E8  TCUSTOMFORM__CREATE,  line 1310 of ./include/customform.inc
>  $080771A2  TAPPLICATION__CREATEFORM,  line 1523 of
> ./include/application.inc
>  $08053BF6  main,  line 79 of project1.lpr
> TApplication.HandleException Access violation
>  Stack trace:
>  $B7EF1807  LAZARUSPACKAGEINTF_finalize,  line 49 of gtkglobals.pp
>  $0806F9FE  TCUSTOMFORM__DODESTROY,  line 646 of ./include/customform.inc
>  $0806E8D8  TCUSTOMFORM__BEFOREDESTRUCTION,  line 98 of
> ./include/customform.in
> c
>  $0806E912  TCUSTOMFORM__DESTROY,  line 112 of ./include/customform.inc
>  $080711E8  TCUSTOMFORM__CREATE,  line 1310 of ./include/customform.inc
>  $080771A2  TAPPLICATION__CREATEFORM,  line 1523 of
> ./include/application.inc
>  $08053BF6  main,  line 79 of project1.lpr
> [FORMS.PP] ExceptionOccurred
> ^M[FORMS.PP] ExceptionOccurred
> 
> 
> The python script works with no problems when it is run on its own.
> 
> The lazarus application is compiled with gtk1. The python application is
> also using wx  (which uses gtk on linux).
> 
> So,  my question is  :  is it possible to have problems because the
> gtk library is used at the same time from  pascal and  python ?
> Other ideas?
> 
> 
> 
> Best wishes,
> Adrian Maier
> 

You should look at P4D (Python for Delphi).
AFAIK it also works with lazarus.
http://mmm-experts.com/

Uwe

_________________________________________________________________
     To unsubscribe: mail [EMAIL PROTECTED] with
                "unsubscribe" as the Subject
   archives at http://www.lazarus.freepascal.org/mailarchives

Reply via email to