Find the answer to your Linux question:
Results 1 to 4 of 4
Anyone had this problem: Code: Gtk-WARNING **: invalid cast from `GtkFileSelection' to `GtkText' Gtk-CRITICAL **: file gtktext.c: line 945 (gtk_text_insert): assertion `GTK_IS_TEXT (text)' failed. Can anyone help this is killing ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Linux User
    Join Date
    Oct 2004
    Location
    Serbia&Montenegro
    Posts
    281

    Problem


    Anyone had this problem:
    Code:
    Gtk-WARNING **: invalid cast from `GtkFileSelection' to `GtkText'
    
    Gtk-CRITICAL **: file gtktext.c: line 945 (gtk_text_insert): assertion `GTK_IS_TEXT (text)' failed.
    Can anyone help this is killing me!
    Linux registered user #358842
    Human knowledge belongs to the world.

  2. #2
    Linux Guru lakerdonald's Avatar
    Join Date
    Jun 2004
    Location
    St. Petersburg, FL
    Posts
    5,035
    I assume you're making some sort of gtk app?

  3. #3
    scm
    scm is offline
    Linux Engineer
    Join Date
    Feb 2005
    Posts
    1,044
    Not had this problem myself, but the warning is telling you that (presumably) an argument is of the wrong type and is being cast to the correct type. That cast is then failing the assertion that it's text. If we could see the offending code snippet around line 945 we may be able to pin it down for you.

    Steve

  4. $spacer_open
    $spacer_close
  5. #4
    Linux User
    Join Date
    Oct 2004
    Location
    Serbia&Montenegro
    Posts
    281
    Yes, I'm making a gtk app actually it's a first version of my own text editor. I have this problem when I try to open a file, because function for openning is separate from main() . And when I set gtk_text_insert after I declare text widget it works but not if it's in a different function. And gtktext.c is not my file. I can only solve this by openning another window and placing the text in it.
    Linux registered user #358842
    Human knowledge belongs to the world.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •