Re: [Vala] Assignment from incompatible pointer type while using delegate/lambda

2011-02-04 Thread Jiří Zárevúcky
On Sat, Feb 5, 2011 at 12:08 AM, Sylvain Leroux sylv...@chicoree.fr wrote: I don't understand what's wrong here. But I tried it with Vala 0.8.1, 0.10.3 and 0.15.1, having each time the exact same result. Apart from the warning, the code worked as expected. The valac translation does not

Re: [Vala] benchmarks on Vala?

2011-01-17 Thread Jiří Zárevúcky
On Mon, Jan 17, 2011 at 1:24 AM, Didip Kerabat did...@gmail.com wrote: Hi all, I'm new to the language and the community. Welcome. If you haven't done so already, you can also join our IRC channel. It's a good place to discuss simpler questions about the basics of the language. I'm

Re: [Vala] GObject allocation / referencing... Why is so slow?

2011-01-15 Thread Jiří Zárevúcky
Yes, it's not the same, but it's a similar implementation, using reference counting (it's not atomic, but if you use an sig_atomic_t ref variable, instead of the volatile int, you would get atomicity with no performance loss at all), Not true I believe. sig_atomic_t ensures atomicity on an

Re: [Vala] GObject allocation / referencing... Why is so slow?

2011-01-15 Thread Jiří Zárevúcky
On Fri, Jan 14, 2011 at 5:28 PM, Marco Trevisan (Treviño) m...@3v1n0.net wrote: [...] I guess that a gobject structure is really more complex compared to the ones defined by Dova (or by simple C), but if Vala has these performances, due to GObject mamangement, even the (evil) Mono C# seems to

Re: [Vala] vala code generation too constrained?

2011-01-10 Thread Jiří Zárevúcky
- Původní zpráva - Sorry if I'm misunderstanding, but I think you're talking about something already done: dova. Right? Not entirely. While Dova does bring a new runtime support library, it's still designed to be C compatible API-wise.

Re: [Vala] using aliases?

2011-01-08 Thread Jiří Zárevúcky
- Původní zpráva - Hi. Are there plans to incorporate using aliases in Vala? Yes, I think it's planned to support this. Now if only someone implemented it.. :) ___ vala-list mailing list vala-list@gnome.org

Re: [Vala] Adding defer in vala?

2010-12-18 Thread Jiří Zárevúcky
pancake píše v So 18. 12. 2010 v 11:46 +0100: Go adds a new keywordnamed 'defer' that schedules the execution of a statement until a return is perfiormed. Something like.. I have to do x,y,z before leaving.. In vala we have a bit of automagic reference counting which can close

Re: [Vala] [Genie] Problem with derived compact classes

2010-12-04 Thread Jiří Zárevúcky
Nicolas píše v So 04. 12. 2010 v 12:56 +0100: Someone knows what can i do to avoid this ? Unfortunately, there is nothing you can do except trying a different design. Derived compact classes are not supported (and can't be for technical reasons). signature.asc Description: This is a digitally

Re: [Vala] Ternary operator and nullable values in return statements

2010-11-28 Thread Jiří Zárevúcky
Dru Moore píše v Ne 28. 11. 2010 v 18:22 +: Hi all, Was surprised to see the following fail to compile with an error: Incompatible expressions in Vala 0.10.0 (simplified test case to illustrate): public static int main (string[] args) { int? x = test (12); return 0; } public

Re: [Vala] this = Object

2010-09-28 Thread Jiří Zárevúcky
Cyrille Colin píše v Út 28. 09. 2010 v 14:10 +0200: [...] and this is my callback in Vala code: public uint32 cb (ValaObj obj, int value) { this = obj; ... } it works fine with 0.8.1 and throw exception with 0.10 : error: unsupported lvalue in assignment May someone could

Re: [Vala] this = Object

2010-09-28 Thread Jiří Zárevúcky
Cyrille Colin píše v Út 28. 09. 2010 v 16:24 +0200: thanks for interest, I have a singleton. It have a callback called by the lib_conntrack. so when the conntrack receive something it call the callback function : public uint32 cb (ValaObj obj-the singleton, int value) { } To keep the

Re: [Vala] Vala Tutorial Issue

2010-09-28 Thread Jiří Zárevúcky
Matt Harrison píše v Út 28. 09. 2010 v 16:56 -0400: I get this Error when trying to compile: warning: passing argument 4 of 'g_source_set_callback' from incompatible pointer type /usr/include/glib-2.0/glib/gmain.h:199: note: expected 'GDestroyNotify' but argument is of type 'void (*)(struct

Re: [Vala] [Genie] is this a bug ?

2010-09-23 Thread Jiří Zárevúcky
Nicolas píše v Čt 23. 09. 2010 v 12:03 +0200: Hi, I'm developping a program and i made a mistake in my code, i think i found a bug. If i call my gtk window class test and in this class i create a gtk button named test, vala does not report an error, only gcc. That is a really unusual

Re: [Vala] Proposed Vala Logo

2010-09-01 Thread Jiří Zárevúcky
Dov Grobgeld píše v St 01. 09. 2010 v 09:43 +0300: Regarding the logo, here are my wild ideas when I hear the name Vala and when I let my imagination run wild: - Vala sounds like me similar to Valhalla from Scandinavian Mythology ( http://en.wikipedia.org/wiki/Valhalla) - Valhalla

Re: [Vala] bug: async method containing try-catch clause

2010-08-05 Thread Jiří Zárevúcky
Nor Jaidi Tuah píše v Čt 05. 08. 2010 v 15:15 +0800: Is this a known bug? https://bugzilla.gnome.org/show_bug.cgi?id=596861 signature.asc Description: Toto je digitálně podepsaná část zprávy ___ vala-list mailing list vala-list@gnome.org

Re: [Vala] libxml2 bindings question Node.child_element_count()

2010-07-20 Thread Jiří Zárevúcky
Dru Moore píše v Út 20. 07. 2010 v 16:08 +0100: Hi all, Hello, Is this just a fact of life (I know it's an awkward library generally), is there an issue with the Fremantle distro for vala (should the vapi files be brought into line for the platform), or am I missing something obvious?

Re: [Vala] Manual VAPI writing

2010-07-19 Thread Jiří Zárevúcky
Harry Van Haaren píše v Po 19. 07. 2010 v 21:45 +0100: Hey All, I had this working before, but due to Hard disk issues I lost the .vapi. Currently I have a vapi that will create the right types, initialize the object (and destroy it), but I cant figure the read function out anymore:

Re: [Vala] non-null broken in vala 0.9.3

2010-07-16 Thread Jiří Zárevúcky
tecywiz121 píše v Čt 15. 07. 2010 v 23:06 -0400: Bringing static code analysis would be amazing, but I have a feeling that detecting when a variable is considered safe is an undecidable problem (http://en.wikipedia.org/wiki/Undecidable_problem ). Not sure though. I wouldn't go into

Re: [Vala] non-null broken in vala 0.9.3

2010-07-16 Thread Jiří Zárevúcky
Sam Wilson píše v Pá 16. 07. 2010 v 12:42 +: Jiří Zárevúcky zarevucky.j...@... writes: tecywiz121 píše v Čt 15. 07. 2010 v 23:06 -0400: Bringing static code analysis would be amazing, but I have a feeling that detecting when a variable is considered safe is an undecidable

Re: [Vala] [ANNOUNCEMENT] Chipmunk Bindings

2010-07-14 Thread Jiří Zárevúcky
tecywiz121 píše v Út 13. 07. 2010 v 22:35 -0400: On Wed, 2010-07-14 at 03:31 +0200, Jiří Zárevúcky wrote: tecywiz121 píše v Út 13. 07. 2010 v 20:32 -0400: Hello vala people, I am rather proud to announce my first slightly useful project: Chipmunk Bindings! [0] Hello

Re: [Vala] [ANNOUNCEMENT] Chipmunk Bindings

2010-07-13 Thread Jiří Zárevúcky
tecywiz121 píše v Út 13. 07. 2010 v 20:32 -0400: Hello vala people, I am rather proud to announce my first slightly useful project: Chipmunk Bindings! [0] Hello. From the quick look at the bindings, I can't say I like them too much. Using vapigen for non-GObject library isn't a very good

Re: [Vala] Delegate on struct

2010-07-12 Thread Jiří Zárevúcky
Nicolas HENRY píše v Čt 08. 07. 2010 v 01:14 +0200: Hello, I don't understand why this code produce a warning (vala 0.9.2) : public delegate void myDelegateFunc(); struct MyStruct { public myDelegateFunc my_struct_func; } void main(){ string a = test; var t =

Re: [Vala] Singleton and reference count

2010-04-28 Thread Jiří Zárevúcky
Sam Wilson píše v Út 27. 04. 2010 v 18:39 -0400: On Tue, 2010-04-27 at 19:42 +0200, Jiří Zárevúcky wrote: Jonh Wendell píše v Út 27. 04. 2010 v 10:46 -0300: Hi, folks. I wrote a simple singleton: And in the other file, I do: var prefs = Prefs.default (); use prefs var

Re: [Vala] Singleton and reference count

2010-04-27 Thread Jiří Zárevúcky
Jonh Wendell píše v Út 27. 04. 2010 v 10:46 -0300: Hi, folks. I wrote a simple singleton: And in the other file, I do: var prefs = Prefs.default (); use prefs var... The prefs var doesn't get destroyed, thus my destructor is never called. [...] It refs the result variable

Re: [Vala] Singleton and reference count

2010-04-27 Thread Jiří Zárevúcky
Mike Massonnet píše v Út 27. 04. 2010 v 18:11 +0200: 2010/4/27 Sam Wilson tecywiz...@hotmail.com: On Tue, 2010-04-27 at 10:46 -0300, Jonh Wendell wrote: Hi, folks. I wrote a simple singleton: public class Prefs { private static Prefs instance; public static Prefs default() {

Re: [Vala] Prepare XML data

2010-03-10 Thread Jiří Zárevúcky
Denis Kuzmenok píše v St 10. 03. 2010 v 18:04 +0200: Hello, people. I wonder is there any functionality to write xml files and prepare data for xml? = lt; = quot; etc, Thank you in advance Unless you want to use some sophisticated library (none of which is easy to use in Vala),

Re: [Vala] Converting nullable to non-nullable types

2010-02-26 Thread Jiří Zárevúcky
Sam Wilson píše v Čt 25. 02. 2010 v 21:43 -0500: On Fri, 2010-02-26 at 00:43 +0100, Jiří Zárevúcky wrote: Here's a little trick you might like: [code] errordomain MyError { FAILED; } T throwerrorT (string str) throws Error { throw new MyError.FAILED (str

Re: [Vala] Converting nullable to non-nullable types

2010-02-26 Thread Jiří Zárevúcky
Sam Wilson píše v Čt 25. 02. 2010 v 21:58 -0500: Here's a little trick you might like: [code] errordomain MyError { FAILED; } T throwerrorT (string str) throws Error { throw new MyError.FAILED (str); } int func () { int? i = null; int j = i ??

Re: [Vala] Converting nullable to non-nullable types

2010-02-25 Thread Jiří Zárevúcky
Sam Wilson píše v Čt 25. 02. 2010 v 18:07 -0500: Hey! I am just wondering if there is any syntactic sugar for shortening the following code segment [code] Element? nsource = ElementFactory.make(filesrc, file-source); if (nsource == null) { printError(); return; } Element source =

Re: [Vala] Vala Coding Style

2010-02-23 Thread Jiří Zárevúcky
Maria Rodriguez píše v Út 23. 02. 2010 v 15:44 -0600: Hi, I was looking for some advices of vala coding style. Specifically on the following issues *Indentation (reading preview posts, it is still not clear for me, if it is 8 or 4 spaces) In Vala itself tabs are used for indentation,

Re: [Vala] abstract method with random return value or parameters

2010-02-11 Thread Jiří Zárevúcky
Martin Kalbfuß píše v Čt 11. 02. 2010 v 02:11 +0100: Hi, I'm new to Vala, and not very experienced using objects. [...] The problem is the data member. Every data member of all the sub classes has its own type(double, string ...). If I add it as a member of the sub class, I need to

Re: [Vala] [RFC] Extension methods (Re: maemo5 hildon input mode)

2010-02-10 Thread Jiří Zárevúcky
Jan-Jaap van der Geer píše v St 10. 02. 2010 v 02:34 -0800: Jan Hudec b...@ucw.cz wrote: This looks like another use-case for extension methods in a day. I'd like to see them as well. It might be useful, in some cases. It should be noted that extension methods can only access class'

Re: [Vala] [Soup] How to convert uint8[] to string?

2010-02-10 Thread Jiří Zárevúcky
Бака Гайдзин píše v St 10. 02. 2010 v 18:03 +0200: Hi! In the new version of Vala (0.7.10) Soup.Message.response_body.data returns uint8[] instead string, like in older versions. Is there any standart way to convert this value to string? I wrote this piece of code, but it is very ugly and

Re: [Vala] Is it possible to do a reading buffer offset in vala?

2010-02-09 Thread Jiří Zárevúcky
JM píše v Út 09. 02. 2010 v 10:36 +0100: Hi all I have a little problem on working with buffer offsets in vala. In C doing an offset for a char buf[SOME_SIZE]; is easy, but I have difficulties doing it in vala. You can simply use the same way you would in C. Cast your buffer to a pointer

Re: [Vala] maemo5 hildon input mode

2010-02-09 Thread Jiří Zárevúcky
pHilipp Zabel píše v Út 09. 02. 2010 v 16:37 +0100: On Tue, Feb 9, 2010 at 3:53 PM, Levi Bard taktaktaktaktaktaktaktaktak...@gmail.com wrote: While this is indeed correct workaround, the Hildon binding should probably be updated (so you get type-checking from the compiler). In that case,

Re: [Vala] Is it possible to do a reading buffer offset in vala?

2010-02-09 Thread Jiří Zárevúcky
JM píše v Út 09. 02. 2010 v 18:52 +0100: Hello Jiří Thanks! It works fine with pointers. just like in C. I just there was a possibility to avoid them in vala because I have to manage them manually. But it's also fine this way. The only manual thing you are doing is moving the pointer. I

Re: [Vala] Is it possible to do a reading buffer offset in vala?

2010-02-09 Thread Jiří Zárevúcky
JM píše v Út 09. 02. 2010 v 19:43 +0100: Thanks for reply! Hmm... I thought all vala strings are handled as utf-8. So I casted the buffer just like this: print(%s\n,(string)buffer); What would you do ? Regards Jörn From what you're saying it looks like a problem in your terminal

Re: [Vala] maemo5 hildon input mode

2010-02-09 Thread Jiří Zárevúcky
pHilipp Zabel píše v Út 09. 02. 2010 v 22:05 +0100: 2010/2/9 Jiří Zárevúcky zarevucky.j...@gmail.com: pHilipp Zabel píše v Út 09. 02. 2010 v 16:37 +0100: On Tue, Feb 9, 2010 at 3:53 PM, Levi Bard taktaktaktaktaktaktaktaktak...@gmail.com wrote: While this is indeed correct workaround

Re: [Vala] maemo5 hildon input mode

2010-02-08 Thread Jiří Zárevúcky
Martin DeMello píše v Po 08. 02. 2010 v 22:26 +0530: I'm trying to disable Maemo's autocapitalisation in a Gtk.Entry field. Maemo 5 adds a hildon-input-mode property to Gtk.Entry [ http://maemo.org/api_refs/5.0/5.0-final/gtk/GtkEntry.html], but I can't find any way to access it from Vala,

Re: [Vala] Problems using ComboBox with model

2010-02-08 Thread Jiří Zárevúcky
Lars-Erik Helander píše v Út 09. 02. 2010 v 01:41 +0100: Do anyone have a working example of using a ComboBox with model (not the simple text API)? Kind Regards Lars I don't do much Gtk, so I can't help you with this specifically, but I recommend looking for examples in C if you have at

[Vala] Vala Journal, the second issue

2010-02-07 Thread Jiří Zárevúcky
This time straight to the web. Comments welcome. http://valajournal.blogspot.com/2010/02/issue-2-week-after.html signature.asc Description: Toto je digitálně podepsaná část zprávy ___ Vala-list mailing list Vala-list@gnome.org

Re: [Vala] for loop and closure (bug or big gotcha?)

2010-02-05 Thread Jiří Zárevúcky
Jiří Zárevúcky píše v Pá 05. 02. 2010 v 16:08 +0100: Fredderic Unpenstein píše v Pá 05. 02. 2010 v 23:57 +1100: 2010/1/23 Sam Liddicott s...@liddicott.com: I used a language called charamel for controlling 3d figurs. It's closures supported variables in 2 ways. Like valàa

Re: [Vala] Questions on async functions

2010-02-03 Thread Jiří Zárevúcky
Nor Jaidi Tuah píše v St 03. 02. 2010 v 09:36 +0800: Q1. What is the recommended way of aborting an async function so that another invocation can be made only after the previous one has stopped, thus ensuring that there is at most one invocation at any time? I think I don't fully

Re: [Vala] Questions on async functions

2010-02-03 Thread Jiří Zárevúcky
Sam Wilson píše v St 03. 02. 2010 v 10:01 -0500: Q2. Any hope of getting the following replaced with a better syntax? :-) Idle.add(async_function.callback); yield; Why not simply: yield; ? Because 'yield' just stops the method until the

Re: [Vala] Vala Journal, Issue #1

2010-02-03 Thread Jiří Zárevúcky
Nor Jaidi Tuah píše v Po 01. 02. 2010 v 14:44 +0800: Coalesce operator (??) is now implemented in master. ;) https://bugzilla.gnome.org/show_bug.cgi?id=580816 May I suggest adding ??=, as in x ??= y; That would be quite logical I think. I've opened an enhancement request on the

Re: [Vala] Vala Journal, Issue #1

2010-02-03 Thread Jiří Zárevúcky
Xavier Bestel píše v Po 01. 02. 2010 v 12:24 +0100: On Mon, 2010-02-01 at 14:44 +0800, Nor Jaidi Tuah wrote: Coalesce operator (??) is now implemented in master. ;) https://bugzilla.gnome.org/show_bug.cgi?id=580816 May I suggest adding ??=, as in x ??= y; Too bad C# choose ?? as

Re: [Vala] Vala Journal, Issue #1

2010-02-03 Thread Jiří Zárevúcky
Alessandro Pellizzari píše v St 03. 02. 2010 v 18:23 +0100: Il giorno mer, 03/02/2010 alle 17.52 +0100, Jiří Zárevúcky ha scritto: Based on a few requests, I've created a blog for this. Hope you'll like it :) http://valajournal.blogspot.com/ Thank you. I subscribed to the feed

Re: [Vala] Commit that breaks MarkupParseContext

2010-01-26 Thread Jiří Zárevúcky
Michael 'Mickey' Lauer píše v Út 26. 01. 2010 v 23:24 +0100: Am Dienstag, den 26.01.2010, 15:48 -0600 schrieb Sandino Flores Moreno: The next URL has the testcase: https://bugzilla.gnome.org/attachment.cgi?id=152347 It demonstrates that using methods as callbacks with MarkupParser is

Re: [Vala] Commit that breaks MarkupParseContext

2010-01-26 Thread Jiří Zárevúcky
Evan Nemerson píše v Út 26. 01. 2010 v 14:53 -0800: Sorry, wrong patch. Of course I'll want to actually revert the other one ;) On Tue, 2010-01-26 at 14:48 -0800, Evan Nemerson wrote: I just talked to Jürg in IRC, and he prefers the old version too, so it's going to get reverted.

Re: [Vala] Gtk.Dialog.show crashes app

2010-01-25 Thread Jiří Zárevúcky
Nor Jaidi Tuah píše v Po 25. 01. 2010 v 07:58 +0800: dialog.delete_event.connect (() = {dialog.hide_on_delete ();}); Perhaps you wanted return dialog.hide_on_delete (); there? I didn't do this in a long time, bug if I recall correctly, you need to stop delete_event by returning

Re: [Vala] Gtk.Dialog.show crashes app

2010-01-23 Thread Jiří Zárevúcky
Nor Jaidi Tuah píše v So 23. 01. 2010 v 10:39 +0800: I don't know if this is a vala bug or I have missed something. In the following code I'm creating a Gtk.Dialog and keeping it handy to be shown non-modal using show(). The trouble is, after the dialog is closed, reopening it will crash the

Re: [Vala] Proper Syntax for Array of Nullable Strings

2010-01-20 Thread Jiří Zárevúcky
tecywiz121 píše v St 20. 01. 2010 v 16:49 -0500: I am just wondering if it is possible to have an array of nullable strings, and if so, what is the proper syntax? Sam I believe array of class type can always contain nulls. Or am I mistaken? signature.asc Description: Toto je digitálně

Re: [Vala] Proper Syntax for Array of Nullable Strings

2010-01-20 Thread Jiří Zárevúcky
Frederik píše v St 20. 01. 2010 v 23:34 +0100: Sam Wilson wrote: Subject: Re: [Vala] Proper Syntax for Array of Nullable Strings From: zarevucky.j...@gmail.com To: tecywiz...@hotmail.com CC: vala-list@gnome.org Date: Wed, 20 Jan 2010 23:08:19 +0100 tecywiz121 píše v St 20. 01. 2010

Re: [Vala] Proper Syntax for Array of Nullable Strings

2010-01-20 Thread Jiří Zárevúcky
Sam Wilson píše v St 20. 01. 2010 v 17:42 -0500: Date: Wed, 20 Jan 2010 23:23:11 +0100 From: scumm_fr...@gmx.net To: vala-list@gnome.org Subject: Re: [Vala] Proper Syntax for Array of Nullable Strings Jiří Zárevúcky wrote: tecywiz121 píše v St 20. 01. 2010 v 16:49 -0500: I

Re: [Vala] Proper Syntax for Array of Nullable Strings

2010-01-20 Thread Jiří Zárevúcky
Frederik píše v St 20. 01. 2010 v 23:58 +0100: Jiří Zárevúcky wrote: What is the point of having Vala check it everywhere? I expect programmer to know what is going on inside a method/class he wrote. Input and output values are being checked and that's IMO perfectly enough. Imagine

Re: [Vala] 'weak' keyword context?

2010-01-20 Thread Jiří Zárevúcky
Andrés G. Aragoneses píše v Čt 21. 01. 2010 v 02:57 +0100: Hi there, My question is simple: can the weak keyword be used for local variables instead of fields? (Sorry I cannot check it right now with the last version.) If yes (or if it will in some future version), does it really have any

Re: [Vala] 'weak' keyword context?

2010-01-20 Thread Jiří Zárevúcky
Andrés G. Aragoneses píše v Čt 21. 01. 2010 v 03:17 +0100: El 21/01/10 03:05, Jiří Zárevúcky escribió: Andrés G. Aragoneses píše v Čt 21. 01. 2010 v 02:57 +0100: Hi there, My question is simple: can the weak keyword be used for local variables instead of fields? (Sorry I cannot check

Re: [Vala] New Member / Democamp at CUSEC

2010-01-19 Thread Jiří Zárevúcky
Sam Wilson píše v Út 19. 01. 2010 v 10:46 -0500: Hello! My name is Sam Wilson, though I usually go by tecywiz121 online. First I'd just like to say hi to everyone who works or is interested in vala, and thanks for making a very cool new programming language! Some random background about

Re: [Vala] Unboxing Value Types

2010-01-19 Thread Jiří Zárevúcky
Sam Wilson píše v Út 19. 01. 2010 v 11:02 -0500: Hello again! random question, how are you supposed to unbox a value type (say float) ? Here is how I am trying to do it, but it won't compile: [code] public void main(string[] args) { float? a = 6; printfloat((float)a); }

Re: [Vala] Another Question

2010-01-19 Thread Jiří Zárevúcky
Sam Wilson píše v Út 19. 01. 2010 v 18:49 -0500: Hello once again friendly mailing list! I have another question, probably my own fault this time: why does the following not produce what I expect it to? [code]public int main(){ string[] test_array, test2; TestClass tc; ulong len1,

Re: [Vala] Immutable variables

2010-01-15 Thread Jiří Zárevúcky
pancake píše v Pá 15. 01. 2010 v 08:42 +0100: Is there a way to define them? I need it to solve some warnings for the vapis describing some C functions accepting const char* as argument. As I see in the compiler source is that it is not supported. Only for struct or class definitions

Re: [Vala] Threads and async (was: Threads and closures problem)

2010-01-13 Thread Jiří Zárevúcky
Michael 'Mickey' Lauer píše v Čt 14. 01. 2010 v 00:48 +0100: Jörn's mail about threads and closures reminded me about a problem I wanted to highlight here. The addition of async functions in Vala is a very great feature, however I wonder how this could work with multiple threads? As far as I

Re: [Vala] Support for method overloading.

2010-01-12 Thread Jiří Zárevúcky
Sam Liddicott píše v Út 12. 01. 2010 v 07:25 +: Overloading could easily be supported with mandatory cname or csuffix attributes; that an explicit name needs to be given for C is no reason that it needs to be given for vala which could do regular overloading. I think it ought to be

Re: [Vala] Support for method overloading.

2010-01-12 Thread Jiří Zárevúcky
Sam Liddicott píše v Út 12. 01. 2010 v 16:04 +: * Jiří Zárevúcky wrote, On 12/01/10 14:43: Sam Liddicott píše v Út 12. 01. 2010 v 07:25 +: Overloading could easily be supported with mandatory cname or csuffix attributes; that an explicit name needs to be given for C

Re: [Vala] Question about namespaces..

2010-01-08 Thread Jiří Zárevúcky
Shawn Ferris píše v St 06. 01. 2010 v 12:22 -0700: On Wed, 2010-01-06 at 07:51 +0100, Jan Hudec wrote: It already exists. It's called a class! Of course I know what a class is, and I understand (mostly) what they're capable of. The problem with a separate class to manage the plugins is

Re: [Vala] Support for method overloading.

2010-01-08 Thread Jiří Zárevúcky
Fabzter píše v Čt 07. 01. 2010 v 16:01 -0600: Hi. I have been playing with Vala for some months. I find it to be a really cool language, thus, I'm thinking in porting an medium sized personal project from C# to Vala, but it relies heavyly on method and constructor overloading, and having this

Re: [Vala] How to chain up to parent constructor

2010-01-02 Thread Jiří Zárevúcky
Jan Hudec píše v So 02. 01. 2010 v 11:29 +0100: On Fri, Jan 01, 2010 at 12:02:31 +0100, Jiří Zárevúcky wrote: [...] Unfortunately this isn't going to work, because Gtk.RadioToolButton.from_stock, like all Gtk allocators (*_new functions), lacks class-method form (*_construct function

Re: [Vala] How to chain up to parent constructor

2010-01-01 Thread Jiří Zárevúcky
Dov Grobgeld píše v Pá 01. 01. 2010 v 12:13 +0200: How do you create a transparent inheritance? E.g. I would like to inherit from Gtk.RadioToolButton and support all its methods and constructors. But when creating the proxy class FooRadioToolButton below I get the error The name `from_stock'

Re: [Vala] Libgee problem

2009-12-09 Thread Jiří Zárevúcky
Nicolas píše v St 09. 12. 2009 v 13:49 +0100: Hi Abderrahim, Yes i tried with a ?, it build but i got a segmentation fault ! I'll try to find another solution. Could you post the code that segfaults? That's probably a bug in Vala. signature.asc Description: Toto je digitálně podepsaná

Re: [Vala] Libgee problem

2009-12-09 Thread Jiří Zárevúcky
Nicolas píše v St 09. 12. 2009 v 18:24 +0100: [...] Could you post the code that segfaults? That's probably a bug in Vala. Thank you. That's not a Vala bug. There is a problem that you don't supply Map's constructor with custom hash and equality methods. In that case, Map will only compare

Re: [Vala] Libgee problem

2009-12-09 Thread Jiří Zárevúcky
Nicolas píše v St 09. 12. 2009 v 20:10 +0100: Jiří, Thank you, i'm learning programming, so sorry for the crap ! ;-) Nicolas. In case you are just learning programming (generally speaking), you should probably consider starting with some more mature language. There is still a lot of

Re: [Vala] Libgee problem

2009-12-09 Thread Jiří Zárevúcky
Xavier Bestel píše v St 09. 12. 2009 v 22:42 +0100: [...] Excuse me, but I'm a bit lost: I thought the question mark was for nullable types. What's the link with boxed types ? Thanks, Xav In order to make a value type nullable, you need to convert it to a reference type. That's

Re: [Vala] How to connect a delegate to a signal?

2009-12-07 Thread Jiří Zárevúcky
G.S.Alex píše v Po 07. 12. 2009 v 20:47 +0800: I used to think the delegate could be used just like method it self . But when I try to connect a delegate to a signal , i got the error: t.vala:24.29-24.29: error: Argument 1: Cannot convert from

Re: [Vala] Gtk menus

2009-12-03 Thread Jiří Zárevúcky
Mark Dewey píše v Čt 03. 12. 2009 v 06:17 -0700: Jiří Zárevúcky wrote: Just read the GTK manual, please. This is a Vala (not GTK) mailing list. If you are wondering, you can use any tutorial for C, since binding into Vala is very straightforward and you shouldn't have problems

Re: [Vala] Gtk menus

2009-12-03 Thread Jiří Zárevúcky
Mark Dewey píše v Čt 03. 12. 2009 v 10:05 -0700: Jiří Zárevúcky wrote: It's OK to discuss bindings. For example when … you don't know how to use them. However, when you ask about how to do something in Gtk, it isn't really related to bindings. You just don't know how to use the library

Re: [Vala] Printing Unicode Characters

2009-11-30 Thread Jiří Zárevúcky
Emad Al-Bloushi píše v Po 30. 11. 2009 v 19:44 +0300: I have tried this one it works but I do now know if there is alternative solution unichar unicode_character = 'ع'; stderr.printf(Unicode Character : %s\n,new StringBuilder().append_unichar(unicode_character).str); What about

Re: [Vala] GtkBuilder example ... bug?

2009-11-28 Thread Jiří Zárevúcky
Jakub Klawiter píše v Ne 29. 11. 2009 v 01:31 +0100: Hello! Ok understand how it's working, thank you! I don't understand why (compiler forces me to use different names i like), but it's not a problem now. I'll understand it later (hope :D). (I assume you are still talking about method

Re: [Vala] GtkBuilder example ... bug?

2009-11-28 Thread Jiří Zárevúcky
I just realized I didn't send this mail to the mailing list. Sorry about that. Jakub Klawiter píše v So 28. 11. 2009 v 23:00 +0100: Hello! On Sat, Nov 28, 2009 at 21:53, Jakub Klawiter jklawi...@gmail.com wrote: so probably there is, a bug in example code. Can I ask where? ;-) Maybe

Re: [Vala] Fonts problem.

2009-10-10 Thread Jiří Zárevúcky
On Sat, Oct 10, 2009 at 4:57 PM, Arkadi Viner arkash...@gmail.com wrote: Hello, I want to ask you for an advice. I have build my gui with glade and it looks pretty well on my laptop but on some systems it doesn't look well. Well, you have to make it so it looks good everywhere. The

Re: [Vala] Impossible to subclass from gio stream classes?

2009-10-01 Thread Jiří Zárevúcky
On Wed, Sep 30, 2009 at 7:46 PM, Jan Hudec b...@ucw.cz wrote: On Wed, Sep 30, 2009 at 18:58:54 +0200, Philipp Zabel wrote: I'd like to subclass GLib.BufferedInputStream. Vala doesn't like the following construct: class MyStream : GLib.BufferedInputStream {     MyStream (GLib.InputStream

Re: [Vala] Hi, Is Vala what I am looking for?

2009-09-23 Thread Jiří Zárevúcky
On 09/23/2009 05:24 PM, Andrés G. Aragoneses wrote: Jiří Zárevúcky wrote: On 09/21/2009 10:52 PM, Andrés G. Aragoneses wrote: [...] Of course, what I'm talking about is about adding one more user choice, not removal of Mono like the subject of the original thread is named (especially

Re: [Vala] Hi, Is Vala what I am looking for?

2009-09-21 Thread Jiří Zárevúcky
On 09/21/2009 10:52 PM, Andrés G. Aragoneses wrote: [...] Of course, what I'm talking about is about adding one more user choice, not removal of Mono like the subject of the original thread is named (especially if you consider that I work for Novell on some Mono class libraries ;) ). At last,

[Vala] Thoughts on asynchronous methods

2009-09-11 Thread Jiří Zárevúcky
I did some thinking on the subject of asynchronous (aka yielding) methods. I'd like to share and discuss some of my ideas here. -- 1. yields keyword is far from intuitive --

Re: [Vala] GtkActionEntry Vapi Issue

2009-09-09 Thread Jiří Zárevúcky
On 09/09/2009 04:11 AM, Lucas Beeler wrote: Since Gtk.ActionEntry structures are a major feature in Gtk/GNOME user interfaces, I'm sure that others have encountered this problem before. Any suggested workarounds, pointers to vapi fixes in the pipeline, or assistance of any other kind would be

Re: [Vala] Showing animated gif files.

2009-09-04 Thread Jiří Zárevúcky
On 09/04/2009 02:33 PM, Arkadi Viner wrote: Hi. I want to show some animation to the user while my program is busy getting some information from the internet. I have an animated file which is - *.gif type and I want to use it. Is there any library to handle animated gif files that I can use?

Re: [Vala] removing an element from a list

2009-09-01 Thread Jiří Zárevúcky
On 09/01/2009 08:51 AM, Didier Ptitjes wrote: Jiří Zárevúcky wrote: If the dependency concerns you, you can simply copy the class you use into your application. :) Vala compiler itself includes a copy of the whole library. Jiří, please, remember that Valac includes that code

Re: [Vala] removing an element from a list

2009-08-31 Thread Jiří Zárevúcky
On 08/31/2009 10:59 PM, jezra lickter wrote: On Mon, 31 Aug 2009 03:07:57 +0200 Jiří Zárevúckyzarevucky.j...@gmail.com wrote: On 08/31/2009 03:05 AM, Jiří Zárevúcky wrote: On 08/31/2009 02:10 AM, jezra lickter wrote: The word test is not removed from the list. Am I doing

Re: [Vala] Why do regular reference types leak null?

2009-08-16 Thread Jiří Zárevúcky
On 08/16/2009 09:28 PM, Magentus wrote: Out of interest, has there been any discussion about actually making Vala a GCC front-end? GCC already has the mechanism to do most of this... I suppose it's useful being able to convert it to C, and then distribute that so it can be compiled on

Re: [Vala] Why do regular reference types leak null?

2009-08-14 Thread Jiří Zárevúcky
On 08/14/2009 02:48 AM, Sam Danielson wrote: The following code compiles with no warnings with the 0.7.3 compiler and segfaults at runtime. I understand that nullable types can be null but why are regular reference types allowed to be null? I noticed that if the return type of make_foo is

Re: [Vala] Why do regular reference types leak null?

2009-08-14 Thread Jiří Zárevúcky
On 08/14/2009 10:57 PM, Sam Danielson wrote: Why shouldn't they be null? IMO, it would just add much more trouble. Checking nulls is responsibility of the programmer. That is consistent with every other language I know, including dynamic ones, C#, Java, etc. Perhaps I am misunderstanding

Re: [Vala] gstreamer and libxml patches

2009-08-10 Thread Jiří Zárevúcky
On 08/10/2009 10:39 AM, Éric ALBER wrote: Hello, I wrote two patchs, one for the gstreamer binding and one for the libxml binding. I have sent them by mail ([1] [2])... The most reliable way to post patches is to open a bug in bugzilla and then continually prod devs on IRC. :)

Re: [Vala] wish for Type Inference working for weak local variables

2009-08-03 Thread Jiří Zárevúcky
On 08/03/2009 12:34 AM, Jürg Billeter wrote: On Sun, 2009-08-02 at 16:20 +0200, Jiří Zárevúcky wrote: Yet, I'm kinda wondering about one thing. It seems to me some people were, are and will be wanting inference for weak variables, regardless the real benefits may be negligible. Even

Re: [Vala] wish for Type Inference working for weak local variables

2009-08-02 Thread Jiří Zárevúcky
On 08/01/2009 08:14 PM, Hans Vercammen wrote: Hi, On Sat, 2009-08-01 at 16:53 +0200, Jiří Zárevúcky wrote: On 08/01/2009 04:36 PM, Łukasz Pankowski wrote: Finally Vala has a mechanism called Type Inference, whereby a local variable may be defined using var instead of giving a type

Re: [Vala] wish for Type Inference working for weak local variables

2009-08-01 Thread Jiří Zárevúcky
On 08/01/2009 04:36 PM, Łukasz Pankowski wrote: Hello According to the Vala tutorial Finally Vala has a mechanism called Type Inference, whereby a local variable may be defined using var instead of giving a type, so long as it is unambiguous what type is meant. Type Interface works great for

Re: [Vala] [Libgee][RFC] Making MapK, V a CollectionMap.EntryK, V - Was: Libgee's Roadmap proposal

2009-07-24 Thread Jiří Zárevúcky
2009/7/24 Fredderic magen...@gmail.com: On Fri, 24 Jul 2009 02:21:14 +0200, Jiří Zárevúcky zarevucky.j...@gmail.com wrote: 2009/7/24 Ali Sabil ali.sa...@gmail.com: On Thu, Jul 23, 2009 at 10:32 AM, Didier Ptitjesptit...@free.fr Please comment and argue ;) Could you please explain

Re: [Vala] [Libgee][RFC] Making MapK, V a CollectionMap.EntryK, V - Was: Libgee's Roadmap proposal

2009-07-23 Thread Jiří Zárevúcky
2009/7/23 Didier Ptitjes ptit...@free.fr: So here is the proposal: - Renaming Map.remove(K key) in Map.unset(K key) I don't know about that.. it would be kinda unobvious. People coming from C# and Java will be confused. I'm not sure whether Vala supports it, but in C#, you could do something

Re: [Vala] Libgee's Roadmap proposal

2009-07-23 Thread Jiří Zárevúcky
2009/7/20 Didier Ptitjes ptit...@free.fr: - Are there some things missing ? I have another proposal. Currently, number of elements in a collection is reflected in the size property. In many cases, that's a nonsense. For example, in HashMap, number of set keys can hardly be considered a size

Re: [Vala] [Libgee][RFC] Making MapK, V a CollectionMap.EntryK, V - Was: Libgee's Roadmap proposal

2009-07-23 Thread Jiří Zárevúcky
2009/7/24 Didier Ptitjes ptit...@free.fr: Levi Bard wrote: - Renaming Map.remove(K key) in Map.unset(K key) - Renaming Map.contains(K key) in Map.has(K key) - Make MapK, V inherit from CollectionMap.EntryK, V I like unset. has is not different enough from contains for my liking - I can see

Re: [Vala] [Libgee][RFC] Making MapK, V a CollectionMap.EntryK, V - Was: Libgee's Roadmap proposal

2009-07-23 Thread Jiří Zárevúcky
2009/7/24 Ali Sabil ali.sa...@gmail.com: On Thu, Jul 23, 2009 at 10:32 AM, Didier Ptitjesptit...@free.fr wrote: Please comment and argue ;) Could you please explain the rationale behind this change ? What would be the benefit from  turning a Map into a collection of Pair ? Efficient

Re: [Vala] How can I use the function g_main_context_get_thread_default in my vala Project?

2009-07-22 Thread Jiří Zárevúcky
2009/7/22 Sascha Dewald sascha.dew...@googlemail.com: Hello Friends, i want to use g_main_context_get_thread_default in my vala-project. The Class MainContext is missing this function. What is the preferred way to do this? Hello Sascha, the best thing you can do (AFAIK) is to fix the

  1   2   >