Re: Warnings in latest Glib

2008-04-22 Thread Yaakov (Cygwin Ports)
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Torsten Schoenfeld wrote:
| These all refer to code that uses sv_reftype and which expects it to
| return a char*.  And that's what sv_reftype's prototype says, too:
|
| #define sv_reftype Perl_sv_reftype
| PERL_CALLCONV char* Perl_sv_reftype(pTHX_ SV* sv, int ob)
|
| It seems that your perl is different.  But anyway, I think these
| warnings are harmless.

The Cygwin perl 5.10.0 proto.h has:

PERL_CALLCONV const char*   Perl_sv_reftype(pTHX_ const SV* sv, int ob)

AFAIK the Cygwin perl does nothing special here.


Yaakov
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEAREIAAYFAkgNZj0ACgkQpiWmPGlmQSPsEgCg2gPxjUpgnwOSu4JtbYe635Dy
8DgAoIJ4QLpk9rTYHZkuFQ0HSbosy0l0
=cpJo
-END PGP SIGNATURE-
___
gtk-perl-list mailing list
gtk-perl-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-perl-list


Re: Problems building XML::Parser on Win32, was Release: Camelbox

2008-04-22 Thread Daniel Kasak
On Mon, 2008-04-21 at 02:18 -0700, spicy jack wrote:

 MinGW is a copy of the GNU compiler suite for Windows, IIRC it's GCC
 3.4.5 or thereabouts.  The MinGW-5.1.3.exe program is the installer;
 the gcc/g++ binaries are already on the system and in your path if you
 did a Full Install, you shouldn't need to do anything else to compile
 modules (except tweak source code, more below).

Got it. Yes I did a full install.

 instructions snipped 

 Please let me know if the above instructions don't work for you.

This works. Thanks. It would be great if you could include this in your
next distribution :) I will be leaving my current position soon, and the
person who replaces me will have enough things to freak them out,
without having to hand-edit Makefiles ...

But anyway, this works for me. Thanks again.

Dan

--
Daniel Kasak
IT Developer
NUS Consulting Group
Level 5, 77 Pacific Highway
North Sydney, NSW, Australia 2060
T: (+61) 2 9922-7676 / F: (+61) 2
9922 7989
email: [EMAIL PROTECTED]
website:
http://www.nusconsulting.com.au


___
gtk-perl-list mailing list
gtk-perl-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-perl-list


Re: Displaying console output

2008-04-22 Thread muppet

On Apr 21, 2008, at 8:12 PM, Thomas Rosario wrote:

 Hi All,

 I'm trying to build a GUI to show console output of an existing  
 application. What I've done is 'clicked' signal_connect from  
 Gtk2::Button will execute the application and save the output into a  
 Gtk2::TextBuffer which will be displayed in Gtk2::TextView.

 At the moment, if the button is pressed, the whole GUI will 'freeze'  
 and after the application execution is finished, the complete output  
 is displayed. My question is, how can it be done so textview will be  
 updated in real time with the console output instead of waiting the  
 whole execution to be finished.

You need to use a pipe-open to read the output of your helper program  
from a child process.

How do i keep my GUI updating while doing a long file read?
http://live.gnome.org/GTK2-Perl/FrequentlyAskedQuestions#head-20b1c1d3a92f0c61515cb88d15e06b686eba6cbc


--
It's all very complicated and would take a scientist to explain it.
   -- MST3K


___
gtk-perl-list mailing list
gtk-perl-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-perl-list


re: Displaying console output

2008-04-22 Thread Jeff Hallock

You can put this line throughout your code or in a loop to update pending 
events (This is also good to use for updating progress bars.)

# Run the main loop as long as events are pending
Gtk2-main_iteration while ( Gtk2-events_pending );


You can also use POE (Perl Object Environment) which allows your program to 
multitask.


Message: 1
Date: Mon, 21 Apr 2008 17:12:51 -0700 (PDT)
From: Thomas Rosario [EMAIL PROTECTED]
Subject: Displaying console output
To: gtk-perl-list@gnome.org
Message-ID: [EMAIL PROTECTED]
Content-Type: text/plain; charset=us-ascii

Hi All,

I'm trying to build a GUI to show console output of an existing application. 
What I've done is 'clicked' signal_connect from Gtk2::Button will execute the 
application and save the output into a Gtk2::TextBuffer which will be displayed 
in Gtk2::TextView.

At the moment, if the button is pressed, the whole GUI will 'freeze' and after 
the application execution is finished, the complete output is displayed. My 
question is, how can it be done so textview will be updated in real time with 
the console output instead of waiting the whole execution to be finished.

Many Thanks!


___
gtk-perl-list mailing list
gtk-perl-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-perl-list


Glib::Flags overload !=

2008-04-22 Thread Kevin Ryde
This little program,

use strict;
use warnings;
use Glib;
my $p = Glib::ParamSpec-int ('x','x','',0,1,0, ['readable']);

my $f1 = $p-get_flags;
my $f2 = $p-get_flags;
print f1 ref is , ref $f1, \n;
print f1 != f2 is , $f1 != $f2 ? yes\n : no\n;

prints warnings

Argument [ readable ] isn't numeric in numeric ne (!=) at foo.pl line 9.
Argument [ readable ] isn't numeric in numeric ne (!=) at foo.pl line 9.

I saw in the Glib pod that == is overloaded, which made me try to use
!= too :-).  I wonder if that could be offered fairly easily.

I see ne works, but I suspect that's through stringizing (or at least
it reaches a print stuck into the overloaded '').
___
gtk-perl-list mailing list
gtk-perl-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-perl-list