[Vala] RELEASE: Vala 0.18.0 + GTK 3.4.2 for Win32

2012-10-22 Thread tarnyko
Hi folks, 

A bit silent during last month, I come back to announce a bundle for Vala 
0.18.0 and GTK+ 3.4.2 on Windows. 


Download link here :
http://www.tarnyko.net/en/?q=node/13
or here :
http://www.tarnyko.net/dl/vala.htm 

(A helpful being told me that my formers installers had the bad habit of 
emptying the PATH variable if it was longer than 1023 characters : 
http://www.tarnyko.net/en/?q=comment/307#comment-307. It is now fixed for 
all installers ; please re-download them just in case.) 

- 

News for ValaWinPKG users : 

* The repos for Vala 0.16.0 and 0.18.0 are finally up ! 


There are some packages regressions :
- FreeGLUT VAPI doesn't seem to work with Vala  0.12.0. Needs some fixes 
from its original maintainer ;
- Poppler doesn't work anymore, should apparently be updated. Will do this 
when I have time. 


There is a new package :
- LibUSB 

* If you want to use these new repos, you should really update ValaWinPKG 
before (http://www.tarnyko.net/en/?q=node/12). Sorry, but it's the last time 
it should be necessary. 

* The new version of ValaWinPKG allows you to have multiple Vala 
installations and maintain their packages separately. See this tutorial 
(http://www.tarnyko.net/en/?q=node/14) for more info. 



Regards, 


Tarnyko
___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list


Re: [Vala] RELEASE: Vala 0.18.0 + GTK 3.4.2 for Win32

2012-10-22 Thread Edwin Dlca
Thank you very much for your work, it is very useful for those who want to
use VALA and carry our programs to Windows.
I'll download it now.
Congratulations and keep going.

2012/10/22 tarn...@tarnyko.net

 Hi folks,
 A bit silent during last month, I come back to announce a bundle for Vala
 0.18.0 and GTK+ 3.4.2 on Windows.
 Download link here :
 http://www.tarnyko.net/en/?q=**node/13http://www.tarnyko.net/en/?q=node/13
 or here :
 http://www.tarnyko.net/dl/**vala.htm http://www.tarnyko.net/dl/vala.htm
 (A helpful being told me that my formers installers had the bad habit of
 emptying the PATH variable if it was longer than 1023 characters :
 http://www.tarnyko.net/en/?q=**comment/307#comment-307http://www.tarnyko.net/en/?q=comment/307#comment-307.
 It is now fixed for all installers ; please re-download them just in case.)
 -
 News for ValaWinPKG users :
 * The repos for Vala 0.16.0 and 0.18.0 are finally up !
 There are some packages regressions :
 - FreeGLUT VAPI doesn't seem to work with Vala  0.12.0. Needs some fixes
 from its original maintainer ;
 - Poppler doesn't work anymore, should apparently be updated. Will do this
 when I have time.
 There is a new package :
 - LibUSB
 * If you want to use these new repos, you should really update ValaWinPKG
 before 
 (http://www.tarnyko.net/en/?q=**node/12http://www.tarnyko.net/en/?q=node/12).
 Sorry, but it's the last time it should be necessary.
 * The new version of ValaWinPKG allows you to have multiple Vala
 installations and maintain their packages separately. See this tutorial (
 http://www.tarnyko.net/en/?q=**node/14http://www.tarnyko.net/en/?q=node/14)
 for more info.

 Regards,
 Tarnyko
 __**_
 vala-list mailing list
 vala-list@gnome.org
 https://mail.gnome.org/**mailman/listinfo/vala-listhttps://mail.gnome.org/mailman/listinfo/vala-list

___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list


Re: [Vala] RELEASE: Vala 0.18.0 + GTK 3.4.2 for Win32

2012-10-22 Thread tarnyko
Hi Edwin, 

You're welcome ! I just hope it proves as useful to people as it has proven 
to me. Don't hesitate to report any problems btw ^^ 



Edwin Dlca writes: 


Thank you very much for your work, it is very useful for those who want to
use VALA and carry our programs to Windows.
I'll download it now.
Congratulations and keep going. 

2012/10/22 tarn...@tarnyko.net 


Hi folks,
A bit silent during last month, I come back to announce a bundle for Vala
0.18.0 and GTK+ 3.4.2 on Windows.
Download link here :
http://www.tarnyko.net/en/?q=**node/13http://www.tarnyko.net/en/?q=node/13
or here :
http://www.tarnyko.net/dl/**vala.htm http://www.tarnyko.net/dl/vala.htm
(A helpful being told me that my formers installers had the bad habit of
emptying the PATH variable if it was longer than 1023 characters :
http://www.tarnyko.net/en/?q=**comment/307#comment-307http://www.tarnyko.net/en/?q=comment/307#comment-307.
It is now fixed for all installers ; please re-download them just in case.)
-
News for ValaWinPKG users :
* The repos for Vala 0.16.0 and 0.18.0 are finally up !
There are some packages regressions :
- FreeGLUT VAPI doesn't seem to work with Vala  0.12.0. Needs some fixes
from its original maintainer ;
- Poppler doesn't work anymore, should apparently be updated. Will do this
when I have time.
There is a new package :
- LibUSB
* If you want to use these new repos, you should really update ValaWinPKG
before 
(http://www.tarnyko.net/en/?q=**node/12http://www.tarnyko.net/en/?q=node/12).
Sorry, but it's the last time it should be necessary.
* The new version of ValaWinPKG allows you to have multiple Vala
installations and maintain their packages separately. See this tutorial (
http://www.tarnyko.net/en/?q=**node/14http://www.tarnyko.net/en/?q=node/14)
for more info. 


Regards,
Tarnyko
__**_
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/**mailman/listinfo/vala-listhttps://mail.gnome.org/mailman/listinfo/vala-list 


___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list


Re: [Vala] Bug in async methods?

2012-10-22 Thread Jim Nelson
For async to work properly, you must run the GLib MainLoop.  MainLoop is where 
your async closure for test_function.begin() is called.  It's where all 
callbacks are scheduled, actually.

The only reason this works is that in the case of DO_YIELD you stash the 
test_function.callback and then call it back.  That's why you're seeing End 
callback called 1.

A better way to do this is to (a) get rid of ext_callback and (b) call new 
GLib.MainLoop().run() right before the return 0 in main().  Without actually 
modifying the code (i.e. I'm doing this off the top of my head), that should 
work.

-- Jim

On Mon, Oct 22, 2012 at 2:47 PM, rastersoft ras...@rastersoft.com wrote:

-BEGIN PGP SIGNED MESSAGE- 
Hash: SHA1 

Hi all: 

I was working with async methods, and found something odd: if I call an 
async method, but, for whatever reason, I never call YIELD inside, the 
end callback function is never called. 

I attach an example: by compiling it with 

valac -D DO_YIELD -o test_async test_async.vala --pkg=gio-2.0 

will do a YIELD inside the async function. But when compiled with 

valac -o test_async test_async.vala --pkg=gio-2.0 

will not. In the former case you can see how End callback called 1 is 
printed, because the callback for the end is called; but in the later, 
it's not printed. 

Is that a bug? If not, why does it work that way? 

Thanks. 

- -- 
Nos leemos 
RASTER (Linux user #228804) 
ras...@rastersoft.com http://www.rastersoft.com 

-BEGIN PGP SIGNATURE- 
Version: GnuPG v1.4.11 (GNU/Linux) 
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/ 

iEYEARECAAYFAlCFvwEACgkQXEZvyfy1ha/m+QCfQzIoKObEBhWIO8mwCPtbjBNI
9I8AoJ2kNDrIRYqRsHFCk4sb6eN/pPyC 
=yUo1 
-END PGP SIGNATURE- 


___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list


Re: [Vala] Bug in async methods?

2012-10-22 Thread rastersoft

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Yes, you are right: I created a main loop, called run(), and the
callback got called.

Anyway, I don't understand why is not possible to ensure that the end
callback gets called even without a main loop :?

Thanks!

El 23/10/12 00:03, Jim Nelson escribió:
 For async to work properly, you must run the GLib MainLoop. MainLoop is where 
 your async closure for
test_function.begin() is called. It's where all callbacks are scheduled,
actually.

 The only reason this works is that in the case of DO_YIELD you stash
the test_function.callback and then call it back. That's why you're
seeing End callback called 1.

 A better way to do this is to (a) get rid of ext_callback and (b) call
new GLib.MainLoop().run() right before the return 0 in main().
Without actually modifying the code (i.e. I'm doing this off the top of
my head), that should work.

 -- Jim

 On Mon, Oct 22, 2012 at 2:47 PM, rastersoft ras...@rastersoft.com wrote:

 Hi all:

 I was working with async methods, and found something odd: if I call an
 async method, but, for whatever reason, I never call YIELD inside, the
 end callback function is never called.

 I attach an example: by compiling it with

 valac -D DO_YIELD -o test_async test_async.vala --pkg=gio-2.0

 will do a YIELD inside the async function. But when compiled with

 valac -o test_async test_async.vala --pkg=gio-2.0

 will not. In the former case you can see how End callback called 1 is
 printed, because the callback for the end is called; but in the later,
 it's not printed.

 Is that a bug? If not, why does it work that way?

 Thanks.





- -- 
Nos leemos
 RASTER(Linux user #228804)
ras...@rastersoft.com  http://www.rastersoft.com

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iEYEARECAAYFAlCFxngACgkQXEZvyfy1ha/qbgCdEaOkBSyLpQFLgnldBkpo2v4C
FlIAnRy2zdJBUIgC5IfgXbvKEcGg8wAv
=OnLX
-END PGP SIGNATURE-

___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list


Re: [Vala] Bug in async methods?

2012-10-22 Thread Jim Nelson
It would take me a bit of time to explain async (I've thought about blogging 
about it), but the short answer is: Vala's async and yield keywords are 
designed to use MainLoop to schedule code execution.

You don't *have* to use them to do asynchronous work, but they are certainly 
convenient.

-- Jim

On Mon, Oct 22, 2012 at 3:19 PM, rastersoft ras...@rastersoft.com wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Yes, you are right: I created a main loop, called run(), and the callback got 
called.

Anyway, I don't understand why is not possible to ensure that the end callback 
gets called even without a main loop :?

Thanks!

El 23/10/12 00:03, Jim Nelson escribió:
 For async to work properly, you
  must run the GLib MainLoop. MainLoop is where your async closure
  for test_function.begin() is called. It's where all callbacks are
  scheduled, actually.

  

   The only reason this works is that in the case of DO_YIELD
  you stash the test_function.callback and then call it back. That's
  why you're seeing End callback called 1.

  

   A better way to do this is to (a) get rid of ext_callback and
  (b) call new GLib.MainLoop().run() right before the return 0
  in main(). Without actually modifying the code (i.e. I'm doing
  this off the top of my head), that should work.

  

   -- Jim

  

   On Mon, Oct 22, 2012 at 2:47 PM, rastersoft
  ras...@rastersoft.com wrote:

  

   Hi all:

  

   I was working with async methods, and found something odd: if
  I call an

   async method, but, for whatever reason, I never call YIELD
  inside, the

   end callback function is never called.

  

   I attach an example: by compiling it with

  

   valac -D DO_YIELD -o test_async test_async.vala --pkg=gio-2.0

  

   will do a YIELD inside the async function. But when compiled
  with

  

   valac -o test_async test_async.vala --pkg=gio-2.0

  

   will not. In the former case you can see how End callback
  called 1 is

   printed, because the callback for the end is called; but in
  the later,

   it's not printed.

  

   Is that a bug? If not, why does it work that way?

  

   Thanks.

  

  

  

  

- -- 
Nos leemos
 RASTER    (Linux user #228804)
ras...@rastersoft.com  http://www.rastersoft.com

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iEYEARECAAYFAlCFxngACgkQXEZvyfy1ha/qbgCdEaOkBSyLpQFLgnldBkpo2v4C
FlIAnRy2zdJBUIgC5IfgXbvKEcGg8wAv
=OnLX
-END PGP SIGNATURE-


___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list


Re: [Vala] Bug in async methods?

2012-10-22 Thread rastersoft

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

If you have some spare time, please, blog it.

Thanks!

El 23/10/12 00:22, Jim Nelson escribió:
 It would take me a bit of time to explain async (I've thought about blogging 
 about it), but the short
answer is: Vala's async and yield keywords are designed to use MainLoop
to schedule code execution.

 You don't *have* to use them to do asynchronous work, but they are
certainly convenient.

 -- Jim

 On Mon, Oct 22, 2012 at 3:19 PM, rastersoft ras...@rastersoft.com wrote:

 Yes, you are right: I created a main loop, called run(), and the
callback got called.

 Anyway, I don't understand why is not possible to ensure that the end
callback gets called even without a main loop :?

 Thanks!

 El 23/10/12 00:03, Jim Nelson escribió:
  For async to work properly, you
 must run the GLib MainLoop. MainLoop is where your async closure
 for test_function.begin() is called. It's where all callbacks are
 scheduled, actually.



  The only reason this works is that in the case of DO_YIELD
 you stash the test_function.callback and then call it back. That's
 why you're seeing End callback called 1.



  A better way to do this is to (a) get rid of ext_callback and
 (b) call new GLib.MainLoop().run() right before the return 0
 in main(). Without actually modifying the code (i.e. I'm doing
 this off the top of my head), that should work.



  -- Jim



  On Mon, Oct 22, 2012 at 2:47 PM, rastersoft
 ras...@rastersoft.com wrote:



  Hi all:



  I was working with async methods, and found something odd: if
 I call an

  async method, but, for whatever reason, I never call YIELD
 inside, the

  end callback function is never called.



  I attach an example: by compiling it with



  valac -D DO_YIELD -o test_async test_async.vala --pkg=gio-2.0



  will do a YIELD inside the async function. But when compiled
 with



  valac -o test_async test_async.vala --pkg=gio-2.0



  will not. In the former case you can see how End callback
 called 1 is

  printed, because the callback for the end is called; but in
 the later,

  it's not printed.



  Is that a bug? If not, why does it work that way?



  Thanks.













- -- 
Nos leemos
 RASTER(Linux user #228804)
ras...@rastersoft.com  http://www.rastersoft.com

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iEYEARECAAYFAlCFzjUACgkQXEZvyfy1ha/AmQCfV9ryD8iSphisdtWeikftht1C
WfAAn3BNz/GqRqxDsn6RGgoP6VVWjjuX
=+qaa
-END PGP SIGNATURE-

___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list


Re: [Vala] Bug in async methods?

2012-10-22 Thread rastersoft

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

I've been watching the source code generated by Vala and the key is here:

_data_-result = 1;
if (_data_-_state_ == 0) {
g_simple_async_result_complete_in_idle (_data_-_async_result);
} else {
g_simple_async_result_complete (_data_-_async_result);
}

What do you think about a decorator or something similar to allow to use
async functions without main loop, just using always
g_simple_async_result_complete() in those cases?

I ask this because I'm using Vala to do simulations, using an
architecture similar to SimPy (this is, based on async methods) and it
would be much more convenient to be able to work that way in those cases.

El 23/10/12 00:22, Jim Nelson escribió:
 It would take me a bit of time to explain async (I've thought about blogging 
 about it), but the short
answer is: Vala's async and yield keywords are designed to use MainLoop
to schedule code execution.

 You don't *have* to use them to do asynchronous work, but they are
certainly convenient.

 -- Jim

 On Mon, Oct 22, 2012 at 3:19 PM, rastersoft ras...@rastersoft.com wrote:

 Yes, you are right: I created a main loop, called run(), and the
callback got called.

 Anyway, I don't understand why is not possible to ensure that the end
callback gets called even without a main loop :?

 Thanks!

 El 23/10/12 00:03, Jim Nelson escribió:
  For async to work properly, you
 must run the GLib MainLoop. MainLoop is where your async closure
 for test_function.begin() is called. It's where all callbacks are
 scheduled, actually.



  The only reason this works is that in the case of DO_YIELD
 you stash the test_function.callback and then call it back. That's
 why you're seeing End callback called 1.



  A better way to do this is to (a) get rid of ext_callback and
 (b) call new GLib.MainLoop().run() right before the return 0
 in main(). Without actually modifying the code (i.e. I'm doing
 this off the top of my head), that should work.



  -- Jim



  On Mon, Oct 22, 2012 at 2:47 PM, rastersoft
 ras...@rastersoft.com wrote:



  Hi all:



  I was working with async methods, and found something odd: if
 I call an

  async method, but, for whatever reason, I never call YIELD
 inside, the

  end callback function is never called.



  I attach an example: by compiling it with



  valac -D DO_YIELD -o test_async test_async.vala --pkg=gio-2.0



  will do a YIELD inside the async function. But when compiled
 with



  valac -o test_async test_async.vala --pkg=gio-2.0



  will not. In the former case you can see how End callback
 called 1 is

  printed, because the callback for the end is called; but in
 the later,

  it's not printed.



  Is that a bug? If not, why does it work that way?



  Thanks.













- -- 
Nos leemos
 RASTER(Linux user #228804)
ras...@rastersoft.com  http://www.rastersoft.com

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iEYEARECAAYFAlCF06UACgkQXEZvyfy1ha/LHwCfZyN6VrCTRoBo+qj/F5ueyCM1
9MMAoM/a1bpZviM5ktwhpPRCHJKtSToL
=62sR
-END PGP SIGNATURE-

___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list


Re: [Vala] Bug in async methods?

2012-10-22 Thread Jim Nelson
I think you would need to work with the Vala team to get something like this 
landed.  Part of the solution might be to look at the other back-ends that Vala 
supports (i.e. Posix), although I think those are kept in a separate branch and 
not supported in the main distribution.

However, I suspect you're trying to do something specific for your project, and 
it's best if you built a custom system for doing these async operations.  You 
might be able to package it up into a separate library, if it's generic enough.

-- Jim

On Mon, Oct 22, 2012 at 4:15 PM, rastersoft ras...@rastersoft.com wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

I've been watching the source code generated by Vala and the key is here:

    _data_-result = 1;
    if (_data_-_state_ == 0) {
    g_simple_async_result_complete_in_idle (_data_-_async_result);
    } else {
    g_simple_async_result_complete (_data_-_async_result);
    }

What do you think about a decorator or something similar to allow to use async 
functions without main loop, just using always g_simple_async_result_complete() 
in those cases?

I ask this because I'm using Vala to do simulations, using an architecture 
similar to SimPy (this is, based on async methods) and it would be much more 
convenient to be able to work that way in those cases.

El 23/10/12 00:22, Jim Nelson escribió:
 It would take me a bit of time
  to explain async (I've thought about blogging about it), but the
  short answer is: Vala's async and yield keywords are designed to
  use MainLoop to schedule code execution.

  

   You don't *have* to use them to do asynchronous work, but
  they are certainly convenient.

  

   -- Jim

  

   On Mon, Oct 22, 2012 at 3:19 PM, rastersoft
  ras...@rastersoft.com wrote:

  

   Yes, you are right: I created a main loop, called run(), and
  the callback got called.

  

   Anyway, I don't understand why is not possible to ensure that
  the end callback gets called even without a main loop :?

  

   Thanks!

  

   El 23/10/12 00:03, Jim Nelson escribió:

For async to work properly, you

   must run the GLib MainLoop. MainLoop is where your async
  closure

   for test_function.begin() is called. It's where all callbacks
  are

   scheduled, actually.

  

  

  

The only reason this works is that in the case of
  DO_YIELD

   you stash the test_function.callback and then call it back.
  That's

   why you're seeing End callback called 1.

  

  

  

A better way to do this is to (a) get rid of
  ext_callback and

   (b) call new GLib.MainLoop().run() right before the return
  0

   in main(). Without actually modifying the code (i.e. I'm
  doing

   this off the top of my head), that should work.

  

  

  

-- Jim

  

  

  

On Mon, Oct 22, 2012 at 2:47 PM, rastersoft

   ras...@rastersoft.com wrote:

  

  

  

Hi all:

  

  

  

I was working with async methods, and found something
  odd: if

   I call an

  

async method, but, for whatever reason, I never call
  YIELD

   inside, the

  

end callback function is never called.

  

  

  

I attach an example: by compiling it with

  

  

  

valac -D DO_YIELD -o test_async test_async.vala
  --pkg=gio-2.0

  

  

  

will do a YIELD inside the async function. But when
  compiled

   with

  

  

  

valac -o test_async test_async.vala --pkg=gio-2.0

  

  

  

will not. In the former case you can see how End
  callback

   called 1 is

  

printed, because the callback for the end is called; but
  in

   the later,

  

it's not printed.

  

  

  

Is that a bug? If not, why does it work that way?

  

  

  

Thanks.

  

  

  

  

  

  

  

  

  

  

  

  

- -- 
Nos leemos
 RASTER    (Linux user #228804)
ras...@rastersoft.com  http://www.rastersoft.com

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iEYEARECAAYFAlCF06UACgkQXEZvyfy1ha/LHwCfZyN6VrCTRoBo+qj/F5ueyCM1
9MMAoM/a1bpZviM5ktwhpPRCHJKtSToL
=62sR
-END PGP SIGNATURE-


___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list