[Vala] static linking with Vala

2010-01-28 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: Is possible to statically link a Vala program? I need it to compile code for a Multimedia hard disk for which I don't have all the libraries. Thanks. - -- Nos leemos RASTER(Linux user #228804) ras...@rastersoft.c

Re: [Vala] static linking with Vala

2010-01-29 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Jan Hudec escribió: Hi Jan: >> Is possible to statically link a Vala program? I need it to compile code >> for a Multimedia hard disk for which I don't have all the libraries. > There is no global statically vs. dynamically link. The compiler will l

[Vala] Python bindings for Vala code

2010-02-06 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: Is possible to do Python bindings for Vala classes? This is, accessing vala classes from Python. Yes, I know that it should be as "easy" than doing it for a GObject class, but what I mean is if there is a tutorial or similar, and, what's more

Re: [Vala] Python bindings for Vala code

2010-02-07 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Arc Riley escribió: Hi: [problems with GObject introspection and PyGI] > Sorry to those who are putting a lot of work into > PyGObject/PyGIR/PyBank/PyNameOfTheMonth but its harmful to mislead > project developers in suggesting they should use someth

[Vala] using the notification area/systray

2011-07-10 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm working on a program in Vala and I need to paint an icon on the notification area (or system tray). I've been searching for an specific API in Vala, but haven't found it. Is there something that simplifies it? Thanks. - -- Nos leemos

[Vala] support for "elif"

2011-07-16 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: Have you considered to support "elif" in Vala as syntax sugar for "else if ...", like in python? Thanks. - -- Nos leemos RASTER(Linux user #228804) ras...@rastersoft.com http://www.rastersoft.com -

[Vala] Using gettext

2011-07-26 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm creating a program using Valide and Vala, and I want to use gettext. Unfortunately, I receive this error: In file included from /home/raster/workspace/cronopete/cronopete.vala.c:33:0: /usr/include/glib-2.0/glib/gi18n-lib.h:29:2: error: #

[Vala] volatile

2011-07-27 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm working with threads, and I need to declare a boolean private variable as "volatile". I tried with "private volatile bool myvar", and valide seems to recognize the syntax, but the compilation returns an error. Thanks. - -- Nos leemos

Re: [Vala] volatile

2011-07-29 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 El 28/07/11 10:25, Maciej Marcin Piechotka escribió: Hi: > Remember that the marking variable as volatile in C does not make it > atomic. You still need something like: > > volatile int i = 0; > > // if (i) > if (GLib.AtomicInt.get(ref i) != 0) > ..

[Vala] int64 generics

2011-08-02 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I need to create an ArrayList with int64 values. Using var mylist = new ArrayList(); returns an error: int64 is not a supported generic type argument, use ? to box value types I box it with var mylist = new ArrayList(); and compi

[Vala] GSettings uses memory backend

2011-08-11 Thread rastersoft
Hi all: I'm trying to use gsettings in my vala code, but it insists in use the memory backend (GLib-GIO-Message: Using the 'memory' GSettings backend. Your settings will not be saved or shared with other applications.). Several pages say to install libdconf-dbus-1 and libdconf; I did it, but stil

Re: [Vala] GSettings uses memory backend

2011-08-11 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 El 11/08/11 12:28, Sébastien Wilmet escribió: > On Thu, Aug 11, 2011 at 10:39:26AM +0200, rastersoft wrote: >> I'm trying to use gsettings in my vala code, but it insists in >> use the memory backend (GLib-GIO-Message: Using the &

[Vala] detect mounted volumes

2011-08-13 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I need to detect when a new USB disk has been mounted or unmounted. Currently I use VolumeMonitor.get() to acquire a VolumeMonitor instance and list the volumes (using get_root().get_path() to get the mounting path), but I want to do it in a

Re: [Vala] detect mounted volumes

2011-08-13 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi: Yes, using "mount_added.connect_after" and "mount_removed.connect_after" did the trick. Thanks! El 13/08/11 14:16, Luca Bruno escribió: > On Sat, Aug 13, 2011 at 01:53:04PM +0200, rastersoft wrote: >> >> Hi

[Vala] Getting access to objects using an ObjectPath

2011-08-15 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm starting with DBus over Vala, and I'm having problems in getting access to some elements. I want to work with the UDisk system, so I started to connecto to "org/freedesktop/Udisks" and get all the devices. This returns an array of Object

Re: [Vala] Getting access to objects using an ObjectPath

2011-08-15 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I found the problem: I have to use "org.freedesktop.UDisks" in both get_proxy_sync, because is the same program/connection who answers to all objects. El 15/08/11 11:51, rastersoft escribió: > > Hi all: > > I'm starting w

Re: [Vala] Vala logo proposals

2011-08-15 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi: The logo text is great, but I dislike the logo symbols... What about a V letter "in speed", like the feathers in the first wing? Something like this: http://www.rastersoft.com/vala_fast_v.png I'm not a good graphic designer, but I think you

[Vala] extract translatable strings from VALA files

2011-08-24 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I've been able to extract the translatable strings from VALA files using xgettext -o po/untitled.pot -L c# -k_ *.vala Unfortunately, when I want to use intltool-update with a POTFILES.in file (setting before each VALA file the string [t

[Vala] asynchronous call with DBus

2011-08-27 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm working with DBus and Vala, and I've been able to call to a method in UDisks; but now I want to do that call in an asynchronous manner, because it needs some time to be completed (format a disk). I tried something like this: [DBus (name

Re: [Vala] Was GNOME Panel applet example removed?

2011-08-30 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi: El 30/08/11 15:39, Quikee escribió: > It was removed when examples were converted to GTK 3 and Gnome 3 > and Gnome Panel is deprecated in Gnome 3 so it was removed. Exact > message when it happened is: "remove panel applet sample (panel > applets

[Vala] gtk_clutter_init

2011-09-02 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: How can I call gtk_clutter_init()? I tried several combinations but I've been unable to do it. Thanks. - -- Nos leemos RASTER(Linux user #228804) ras...@rastersoft.com http://www.rastersoft.com -BEGIN

[Vala] live.gnome.org is down

2011-09-06 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all The server live.gnome.org is down, and so all the pages about Vala. Does someone know when will it be active again? Thanks. - -- Nos leemos RASTER(Linux user #228804) ras...@rastersoft.com http://www.raste

[Vala] embed gtk 2.0 widget in clutter actor

2011-09-24 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm creating an app with clutter, and I want to embed a GTK+2 widget inside it; unfortunately, if I try to use gtkclutter-1.0 VAPI, it insists in use GTK+3; and gtkclutter-0.10 seems to not support GtkClutter.Actor. Is there a way of doing th

[Vala] can't receive scroll event in object's method

2011-09-27 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm trying to receive the scroll event in an object, but I'm unable to do it. If I do: [...] this.mybox = new EventBox(); mybox.add_events (Gdk.EventMask.SCROLL_MASK); mybox.scroll_event.connect(do_scroll);

Re: [Vala] can't receive scroll event in object's method

2011-09-28 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Thanks, finally it works! El 28/09/11 09:38, Iñigo Serna escribió: > Hello, > > On 27 September 2011 21:13, rastersoft wrote: >> I'm trying to receive the scroll event in an object, but I'm unable to >> do it. If

[Vala] Monodevelop, vala and GTK

2011-10-01 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: Up to now I am using Valide to develop in Vala; but since this IDE seems to not being actively developed anymore, I want to switch to other IDE. I was considering Monodevelop, but when I want to add the packages I need for my project (Gtk, Gd

[Vala] Compiling VTG under Ubuntu 11.10

2011-10-15 Thread rastersoft
Hi all: I updated my system to Ubuntu 11.10, and now I can't use VTG. There's no package for it, and I can't compile the source code from git. If I install only libvala-0.14, the configure script returns an error, saying that libvala is older than libvala-0.12. If I install libvala-0.12, then

Re: [Vala] Compiling VTG under Ubuntu 11.10

2011-10-16 Thread rastersoft
it's called libafrodite instead of afrodite. I sent the patch to the VTG page. Unfortunately, it compiles but doesn't work: Gedit doesn't find it :( El 16/10/11 05:22, bsquared escribió: rastersoft writes: Hi all: I updated my system to Ubuntu 11.10, and now I can't us

Re: [Vala] Compiling VTG under Ubuntu 11.10

2011-10-16 Thread rastersoft
Hi: That link points to a sample plugin, not to Vala Toys... :? El 16/10/11 17:47, bsquared escribió: rastersoft writes: Hi: I found your patches, and I applied it, but it still complains. Now the problem is with libafrodite: error: Package `afrodite-0.14' not found in specified Val

[Vala] Date format

2011-10-24 Thread rastersoft
Hi all: I want to print a date in the format dd/mm/ or mm/dd/, acording to the current locale. Unfortunately, strftime only seems to support %x, which prints the year as a two-digits number, instead of four digits. How can I get the current date format to be able to print it in the r

Re: [Vala] Date format

2011-10-25 Thread rastersoft
tunately, that's an extremely ugly hack. So I want to know if is there a straightforward way of doing this. Thanks. El 25/10/11 15:35, Reid Thompson escribió: On Mon, 2011-10-24 at 22:33 +0200, rastersoft wrote: I want to print a date in the format dd/mm/ or mm/dd/, acording

Re: [Vala] Date format

2011-10-25 Thread rastersoft
y there should never be a misunderstanding over the time and date format. reid On Tue, 2011-10-25 at 22:06 +0200, rastersoft wrote: Thanks, but that doesn't solve my problem. I already got access to that, and tested format("%x"); unfortunately, it puts the year as a two-digit number. I

Re: [Vala] How to ignore exceptions?

2011-10-31 Thread rastersoft
Or, maybe, something like this: try { code_that_can_generate_exception_but_we_don't_want_to_catch(); }; I don't know if that would break too much the syntax, or would make it difficult to implement... El 31/10/11 11:49, pancake escribió: What about adding a code attribute like [IgnoreExc

[Vala] g_object_unref in render_icon

2011-10-31 Thread rastersoft
Hi all: I'm working with an IconView and using the render_icon method to add icons to it. Checking the Vala documentation, I found at http://valadoc.org/gtk+-2.0/Gtk.Widget.render_icon.html that it says that is mandatory to use g_object_unref after using an icon obtained with this method

[Vala] using a GLib.Icon in an IconView

2011-10-31 Thread rastersoft
Hi all: I'm working with a Gtk.IconView, and need to put standard icons in it. I have several ThemedIcons, and want to use them there, but IconView expects a Gdk.Pixbuf. How can I do that? I've been unable to find how to render a GLib.Icon in a Gdk.Pixbuf. Thanks. -- Nos leemos

Re: [Vala] using a GLib.Icon in an IconView

2011-10-31 Thread rastersoft
/10/11 20:01, JM escribió: Gtk.Invisible w = new Gtk.Invisible(); Gdk.Pixbuf pixb = w.render_icon(Gtk.Stock.CONNECT, IconSize.BUTTON, null); best regards Am Montag, den 31.10.2011, 15:59 +0100 schrieb rastersoft: Hi all: I'm working with a Gtk.IconView, and need to put standard icons

Re: [Vala] How to ignore exceptions?

2011-10-31 Thread rastersoft
I don't think that try { ... } is a good idea, but try { ... }; is. Just removing the catch can result in involuntary errors, but if you have to choose between a ";" or a "catch", the probability of "forgetting" it is greatly reduced. El 31/10/11 23:22, pancake escribió: Hi On 31

Re: [Vala] How to ignore exceptions?

2011-10-31 Thread rastersoft
Yes, I like it! El 01/11/11 00:46, Fabian Deutsch escribió: Maybe nocatch { ... } would make that case even clearer. Am Dienstag, den 01.11.2011, 00:43 +0100 schrieb rastersoft: I don't think that try { ... } is a good idea, but try { ... }; is. Just removing the

[Vala] list_style_properties

2011-11-03 Thread rastersoft
Hi all: I'm trying to read the widget's current style, and wanted to use the method widget.list_style_properties(uint n_props). The problem is that the definition in GTK official documentation http://developer.gnome.org/gtk/2.24/GtkWidget.html#gtk-widget-class-list-style-properties states th

[Vala] get the fg, bg colors

2011-11-07 Thread rastersoft
Hi all: I've been trying to get the RC info from a window, to be able to replicate the background color of an iconview in other parts with Cairo, but I've been unable to do it. I always receive a core dump. How can I get access to it? (foreground color, background color, text color, and so on

[Vala] Memory leak with Gdk.Pixbuf.add_alpha

2011-11-16 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I think I found a memory leak with Gdk.Pixbuf.add_alpha. This function returns a copy of the specified pixbuf, adding an alpha channel. But it seems that Vala increments the count reference too, so it never gets freed. I made my tests with V

Re: [Vala] About Vala's IDE

2011-12-06 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi! There was a project called Valide, written in Vala (https://launchpad.net/valide). Unfortunately it seems to be stalled :( El 06/12/11 10:32, Pigex.Zhang escribió: > Dear All: > > Is there has a plan with vala's professional IDE ?I tried some ty

Re: [Vala] Vala 0.16

2011-12-31 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Try to do: sudo ldconfig El 31/12/11 20:16, David Gomes escribió: > vala: error while loading shared libraries: libvala-0.16.so.0: cannot open > shared object file: No such file or directory. > > Guys, I built Vala 0.16 from source on Ubuntu 1

[Vala] poppler and gtk3

2012-03-24 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm trying to use poppler with gtk3 and vala, but when I use --pkg poppler-glib, vala adds gtk2 too, with the obvious conflict. How can I do it? Thanks. - -- Nos leemos RASTER(Linux user #228804) ras...@rastersoft.com

[Vala] Interfaces and asynchronous methods

2012-08-13 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I tried to define an interface with an async method, but I receive this error in the line where I try to invoke it in an object that implements it: backup.vala:246.14-246.43: error: invocation of void method not allowed as expression Are as

Re: [Vala] Interfaces and asynchronous methods

2012-08-14 Thread rastersoft
escribió: > On Mon, Aug 13, 2012 at 4:03 PM, rastersoft wrote: > >> >> -BEGIN PGP SIGNED MESSAGE- >> Hash: SHA1 >> >> Hi all: >> >> I tried to define an interface with an async method, but I receive this >> error in the line wh

[Vala] d-bus timeout when formating disk

2012-08-26 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm using UDISKS and D-BUS to formate a hard disk. Unfortunately, the time needed to format the drive is bigger than the default timeout for an async call, so I always receive an exception with a d-bus timeout. How can I set the timeout to a

Re: [Vala] d-bus timeout when formating disk

2012-08-27 Thread rastersoft
e" attribute, but also didn't work). El 27/08/12 11:03, Luca Bruno escribió: > On Sun, Aug 26, 2012 at 11:15 PM, rastersoft wrote: > >> Hi all: >> >> I'm using UDISKS and D-BUS to formate a hard disk. Unfortunately, the >> time needed to format the driv

[Vala] Bug in vala, dbus, or udisk?

2012-08-27 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm trying to connect a callback to a signal from UDISK, through DBus. The signal is JobChanged, defined here: http://hal.freedesktop.org/docs/udisks/Device.html#Device::JobChanged The problem is that in the documentation it's defined as J

Re: [Vala] Volatile keyword in Vala(please answer)

2012-08-28 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 It's supposed that a volatile variable can change "magically" (this is, being modified by another thread, a device driver...), so the compiler has to take that into account when doing optimizations. A crude example in C: volatile int v=1; wh

[Vala] Monodevelop

2012-09-16 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I've been using Anjuta for a long time for developing with Vala, but now I want to try with Monodevelop. I tested it, and seemed to work fine, except when compiling, because I was unable to specify it to use Libgee (it wasn't on the list of

[Vala] Bug in async methods?

2012-10-22 Thread rastersoft
-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_

Re: [Vala] Bug in async methods?

2012-10-22 Thread rastersoft
odifying 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 wrote: > > Hi all: > > I was working with async methods, and found something odd: if I call an > async method, but, for what

Re: [Vala] Bug in async methods?

2012-10-22 Thread rastersoft
eld 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 wrote: > > Yes, you are right: I created a

Re: [Vala] Bug in async methods?

2012-10-22 Thread rastersoft
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 wrote: > &g

[Vala] Register object in SYSTEM bus

2012-11-07 Thread rastersoft
} } void on_bus_aquired (DBusConnection conn) { GLib.stdout.printf ("Registering bus\n"); try { var l=conn.register_object ("/com/rastersoft/gamed", new dbus_class()); GLib.stdout.printf ("Registered bus %d\n",(int)l); } catch (IOErro

Re: [Vala] Register object in SYSTEM bus

2012-11-07 Thread rastersoft
running that stuff as root? > Cheers, > Matthias > > 2012/11/7 rastersoft : >> Hi all: >> >> I'm trying to register an object in dbus'SYSTEM bus, but I'm unable to >> do so. I try with: >> >> >> [DBus (name = "com.rastersoft.g

Re: [Vala] Register object in SYSTEM bus

2012-11-07 Thread rastersoft
> Hi! > Have you created a DBus interface file? Are you running that stuff as root? > Cheers, > Matthias > > 2012/11/7 rastersoft : >> Hi all: >> >> I'm trying to register an object in dbus'SYSTEM bus, but I'm unable to >> do so. I try with

Re: [Vala] Register object in SYSTEM bus

2012-11-07 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi: Ok, finally I found it. They are at /etc/dbus-1/system.d Thanks! El 08/11/12 00:06, rastersoft escribió: > > Hi again: > > I'm unable to find documentation about how to create a DBus interface > file. Is it the XM

[Vala] monodevelop-vala

2012-11-11 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I tried to compile the last version of monodevelop-vala under Ubuntu 12.10, but was unable, even after modifying the configure file to use version 0.14 of vala. Does somebody know if this project is still alive? Thanks. - -- Nos leemos

[Vala] GSettings and not-available schemas

2012-12-16 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm working with GSettings. I want to read org.gnome.desktop.background and want to ensure that my code works even when the schema is not installed (let's say, if the user is using KDE). When I try to access an inexistent schema, I receive t

Re: [Vala] ANNOUNCE: Val(a)IDE 0.7.2

2012-12-28 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Oh, yeah! Thanks El 28/12/12 13:12, tarn...@tarnyko.net escribió: > Hi folks, > I'm very happy to announce today's release of Val(a)IDE 0.7.2. > Val(a)IDE is a small but fast IDE for the Vala language. It provides syntax highlighting, autocom

Re: [Vala] ANNOUNCE: Val(a)IDE 0.7.2

2012-12-28 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi: Just a little question: have you added this patch I sent a year ago? https://bugs.launchpad.net/valide/+bug/817136 Thanks El 28/12/12 18:13, tarn...@tarnyko.net escribió: > Luca, > Yes, it's the same codebase. I branched it without pushing bac

Re: [Vala] ANNOUNCE: Val(a)IDE 0.7.2

2012-12-28 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 And another question: are you going to fix the code to allow it to compile with vala 0.18? I downloaded the trunk from your repo, and still asks for vala 0.12 :( El 28/12/12 21:02, rastersoft escribió: > > Hi: > > Just a little questi

Re: [Vala] ANNOUNCE: Val(a)IDE 0.7.2

2012-12-29 Thread rastersoft
n, but of inner plumbing, too. I preferred not to touch that part for my first update... > BTW, on Debian/Ubuntu at least, I'm pretty sure you can install several compiler versions concurrently. Have you considered using 0.12 for the compilation and execution of the IDE only ? > Regard

[Vala] vala 0.12 and vala 0.16

2012-12-31 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I want to work with the new valide (which needs vala 0.12), but at the same time I need vala 0.16. But packages in ubuntu/elementary have a conflict, I can't have both at the same time. Why does this happen? Why version 0.12 is incompatible

[Vala] realpath compiles incorrectly

2013-03-12 Thread rastersoft
Hi all: I'm trying to use Posix.realpath, but I'm unable, because Vala seems to compile it incorrectly. I receive this message: .vala.c:920:2: error: too many argument for function ‘realpath’ I put in my code: string tmp; tmp=Posix.realpath(this.config_path); And it is compiled to _tmp35_ = r

Re: [Vala] realpath compiles incorrectly

2013-03-13 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi Jonas: Your prototype works fine. I'll fill a bug report in bugzilla. Thanks! El 13/03/13 17:44, Jonas Kulla escribió: > 2013/3/13 rastersoft > >> Hi all: >> >> I'm trying to use Posix.realpath, but I'm u

[Vala] gir filename convention

2013-03-16 Thread rastersoft
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all: I'm starting to work with GIR and have a doubt: what is the file name convention? It seems to be libraryname-X.Y.gir, but my question is: is allowed the format libraryname-X.Y.Z.gir, or it must be always libraryname-X.Y.gir? Thanks. - -- N

[Vala] Autovala: new program for developers

2013-03-29 Thread rastersoft
. It also creates automatically the .gir and .vapi files for libraries. You have a longer and more precise description in the README file, in the github repository: https://github.com/rastersoft/autovala It is still an alpha version, but fully usable. It still lacks some minor things, like

[Vala] Valadoc and FileAttribute

2013-04-01 Thread rastersoft
Hi all: I'm trying to use Valadoc, but it returns this error: |configuration.vala:305.47-305.59: error: The name `FileAttribute' does not exist in the context of `AutoVala.configuration.find_configuration' generate.vala:169.51-169.63: error: The name `FileAttribute' does not exist in the contex

Re: [Vala] Autovala: new program for developers

2013-04-03 Thread rastersoft
fast-vapi and adding a C file to complication. > > Hope the best for your tool. > Tal > >> From: tarn...@tarnyko.net >> To: vala-list@gnome.org >> Date: Sat, 30 Mar 2013 16:14:00 +0100 >> Subject: Re: [Vala] Autovala: new program for developers >> >&g

Re: [Vala] Autovala: new program for developers

2013-04-05 Thread rastersoft
or developers >> >> Nice ! Thanks for your work, will check that when I have time. >> >> Regards, >> Tarnyko >> >> rastersoft writes: >> >>> Hi all: >>> >>> Several days ago, another user commented in Elementary Dev list that

Re: [Vala] Autovala: new program for developers

2013-04-14 Thread rastersoft
Yes, I was, precisely, the one with the problem :D El 14/04/13 04:18, Jonas Kulla escribió: > 2013/4/14 Francis Giraldeau >> I have some problem to compile configuration.vala, seems related to Posix: >> >> >> /home/francis/workspace-vala/autovala/src/autovala_lib/configuration.c:2264:2: >> error:

Re: [Vala] Autovala: new program for developers

2013-04-14 Thread rastersoft
I'm fully open to suggestions... El 14/04/13 18:48, Alexander Krivács Schrøder escribió: > On 30.03.2013 02:34, rastersoft wrote: >> Hi all: >> >> Several days ago, another user commented in Elementary Dev list that >> using CMake with Vala was quite hard and diffi

[Vala] libraries and gettext

2013-04-20 Thread rastersoft
Hi all: I'm creating a library with Vala, and want to use gettext with it. In normal programs it works the syntax _("text to translate"), but in a library, dgettext() must be used. Is there a replacement for dgettext() like the underscore for gettext? Thanks. -- Nos leemos

[Vala] gettext, gtk and libraries

2013-04-30 Thread rastersoft
Hi all: I'm creating a plugin for Gedit in Vala, and this plugin creates a window dialog, defined from Glade. This plugin also has messages that must be translated with gettext. Currently I've been able to create the window fine, and to get all the translated texts in the source code to be s

[Vala] memory management with structs

2013-05-18 Thread rastersoft
Hi all: How is the memory management in vala when using structs instead of classes? I presume they are not ref-counted... The real questions are: * is it possible to use structs as elements in a Gee list without running into memory management problems? * How to avoid them, in case there

[Vala] Dynamic load in execution time

2013-08-24 Thread rastersoft
Hi all: I was wondering if Vala allows (or will allow in a near future) to load a .so during execution time (not in load time, like currently does) and access its methods and classes as usual, instead of having to work with function pointers and so on. I ask this because I want to adapt a pr

Re: [Vala] Dynamic load in execution time

2013-08-24 Thread rastersoft
I think it will be enough. Thanks! El 24/08/13 19:17, Evan Nemerson escribió: On Sat, 2013-08-24 at 13:22 +0200, rastersoft wrote: Hi all: I was wondering if Vala allows (or will allow in a near future) to load a .so during execution time (not in load time, like currently does) and access

[Vala] XKB and KeySyms

2013-09-05 Thread rastersoft
Hello: I'm creating an on-screen keyboard, and I need to send synthetic keypresses to the XWindow server. I can use XTest (which is available in Vala), but in order to find the correspondence between a character and a keycode I need XKB support, which seems to be not available in Vala (xkeyco

[Vala] XCB api seems incomplete

2013-12-05 Thread rastersoft
Hi all: I'm porting a little window manager wrote in C to vala, and it uses XCB. But it seems that the XCB Vapi is pretty incomplete. Is someone working on it, or should I try to complete it and send it upwards? Thanks. -- Nos leemos RASTER(Linux user #228804) ra

[Vala] passing string length in VAPI file

2013-12-06 Thread rastersoft
Hi all: I'm completing the XCB api for Vala, but I have a problem: there are several functions that receive a string and its length, like: xcb_intern_atom (xcb_connection_t *_conn_, uint8_t _only_if_exists_, uint16_t _name_len_, const char *_name_); Currently I'm doing it this way, by d

[Vala] Problem creating VAPI file for XcbIcccm

2013-12-12 Thread rastersoft
Hi all: I'm creating a VAPI file for xcb_icccm and I have a problem: I defined the function xcb_icccm_get_wm_class_from_reply as: [CCode (cname = "xcb_icccm_get_wm_class_from_reply")] public void get_wm_class_from_reply(out WmClassFromReply reply, GetPropertyReply input); Unfortunate

[Vala] Problem creating VAPI file for XcbIcccm (extra data)

2013-12-12 Thread rastersoft
class_from_reply")] public void get_wm_class_from_reply(out WmClassFromReply reply, GetPropertyReply input); } El 12/12/13 23:20, rastersoft escribió: Hi all: I'm creating a VAPI file for xcb_icccm and I have a problem: I defined the function xcb_icccm_get_wm_class_from_reply as: [CCod

Re: [Vala] Problem creating VAPI file for XcbIcccm (extra data)

2013-12-13 Thread rastersoft
That was the solution: mark the fields as unowned. Thanks!!! El 13/12/13 09:18, Luca Bruno escribió: On 12/12/2013 23:52, rastersoft wrote: BTW: The whole VAPI file is this: using Xcb; [CCode (lower_case_cprefix = "xcb_icccm_", cheader_filename = "xcb/xcb_icccm.h")]

[Vala] add methods to a compact class from outside the main definition in a VAPI file

2013-12-17 Thread rastersoft
Hi all: I'm working on the XCB VAPI files, and I have a problem. XCB is subdivided in several parts: the core X protocol, utility functions and extensions. The core protocol creates a compact class, Connection, which represents a xcb_connection_t structure, and all the functions for the XCB

Re: [Vala] add methods to a compact class from outside the main definition in a VAPI file

2013-12-17 Thread rastersoft
of either class). The other option is to use static methods. Remember, you can nest namespaces, so you can do something like namespace Icccm { public static void foo (Xcb.Icccm self); } -Evan On Tue, 2013-12-17 at 23:50 +0100, rastersoft wrote: Hi all: I'm w

[Vala] VAPI tutorial

2013-12-27 Thread rastersoft
Hi all: I wrote a little VAPI writing tutorial to help people to start writing VAPI files for libraries. I put it at https://wiki.gnome.org/Projects/Vala/WrittingVAPIs Of course it is incomplete, and is possible that it has mistakes, so I accept all kind of suggestions and fixes. -- Nos le

Re: [Vala] VAPI tutorial

2013-12-28 Thread rastersoft
Why isn't that document linked in the Vala's page? (at least, I didn't found it). It looks very useful. El 28/12/13 04:59, Andre Masella escribió: Probably best to link to the legacy VAPI guide: https://wiki.gnome.org/Projects/Vala/LegacyBindings On 27 December 2013 15:43, ra

[Vala] var + unowned

2013-12-31 Thread rastersoft
Hi all: I'm creating a VAPI, and one of the constructors is defined as: public static unowned Icccm new(Xcb.Connection conn) { unowned Xcb.Icccm.Icccm retval = (Xcb.Icccm.Icccm)conn; return retval; } The idea is to create an Icccm object that is, in fact, a Xcb.Connectio

[Vala] rank modifier

2014-01-05 Thread rastersoft
Hi all: What is the utility of the RANK modifier in the IntegerType and FloatingType VAPI attributes? Thanks. -- Nos leemos RASTER(Linux user #228804) ras...@rastersoft.com http://www.rastersoft.com ___ val

[Vala] difference between using IntegerType and inheriting

2014-01-05 Thread rastersoft
Hi again: Another doubt I have is: what is the difference between doing: [SimpleType] [IntegerType (rank = 9)] [CCode (cname = "c_name", has_type_id = false)] public struct StructName { } and [SimpleType] [CCode (cname = "c_name", has_type_id = false)] public st

Re: [Vala] difference between using IntegerType and inheriting

2014-01-06 Thread rastersoft
truct Atom { } or as: [SimpleType] [CCode (cname = "xcb_atom_t", has_type_id = false)] public struct Atom : uint32 { } ? Thanks. El 05/01/14 22:39, Luca Bruno escribió: You inherit all the methods from uint32? ;) On Sun, Jan 5, 2014 at 9:51 PM, rastersof

[Vala] several pkg-config libraries for a single VAPI file

2014-01-14 Thread rastersoft
Hi all: I'm working on a vapi file for xcb_render, and I need to put into it one function from xcb_renderutils. The problem is that each one needs a different library (xcb-render and xcb-renderutils). Is it possible to make valac to pass both to pkg-config from a single VAPI file? Thanks. -

[Vala] bug in IOChannel.read_line and add_watch

2014-02-02 Thread rastersoft
Hi all: I found a bug in IOChannel.read_line: when the line to read ends in \r and there are no more characters after it, the iochannel can't read more chars, nor send more IN DATA AVAILABLE events from an add_watch. In fact, it seems to lock the gtk main loop. I attach a code that triggers

Re: [Vala] bug in IOChannel.read_line and add_watch

2014-02-02 Thread rastersoft
Hi! Yes, after checking the c code generated, I found it, so I filled a bug at bugzilla. Thanks anyway for the tip! El 02/02/14 15:53, Maciej Piechotka escribió: On Sun, 2014-02-02 at 14:10 +0100, rastersoft wrote: Hi all: Hi, I found a bug in IOChannel.read_line: when the line to read

[Vala] Errors when compiling code generated by dbus-binding-tool

2014-02-21 Thread rastersoft
Hi all: I'm trying to compile some interfaces created with dbus-binding-tool but I'm unable to do so. I receive mainly these errors: error: The type name `DBus.Error' could not be found error: The type name `DBus.ObjectPath' could not be found error: The type name `DBus.Connection' could not b

[Vala] More problems with vala-dbus-binding-tool

2014-02-23 Thread rastersoft
Hi again: I fixed the problem in the last message: I forgot to add --gdbus. Now I have a problem with the C code: when I extract the interfaces with for "org.freedesktop.ConsoleKit /org/freedesktop/ConsoleKit/Manager" (using org.freedesktop.DBus.Introspectable.Introspect), I compile it with Va

Re: [Vala] More problems with vala-dbus-binding-tool

2014-02-23 Thread rastersoft
Here it is. El 23/02/14 14:10, Luca Bruno escribió: Paste the generated vapi. On Sun, Feb 23, 2014 at 1:16 PM, rastersoft wrote: Hi again: I fixed the problem in the last message: I forgot to add --gdbus. Now I have a problem with the C code: when I extract the interfaces with for

  1   2   >