Hi simargl,

the problem is your "var text_buffer = ..." initialization overlaps with
global variable "text_buffer". To fix this just remove "var" keyword.
(valac should warn about that though.)

Regards
Dominique

On 07/09/13 08:38, simargl wrote:
> Hi,
> 
> To learn more about Vala programming language, I wanted to make a very
> simple text editor something like leafpad in Vala and Gtk+3.
> 
> Source code added here http://pastebin.com/q3x4rfmL
> 
> Problem is when I try to make or open new file, that new text_buffer fails
> to show in text_view with this error.
> 
> (editor:4282): Gtk-CRITICAL **: gtk_text_buffer_set_text: assertion
> `GTK_IS_TEXT_BUFFER (buffer)' failed
> 
> Any ideas how to fix that problem?
> 
> Kind regards
> _______________________________________________
> vala-list mailing list
> vala-list@gnome.org
> https://mail.gnome.org/mailman/listinfo/vala-list
> 

Attachment: signature.asc
Description: OpenPGP digital signature

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

Reply via email to